diff options
author | Jason Merrill <jason@redhat.com> | 2010-04-27 16:08:47 -0400 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2010-04-27 16:08:47 -0400 |
commit | ea8b8aa005a994ce5d3e5437c780a35a2c27ff4e (patch) | |
tree | 38a838d3c4a7c326547de8d51c9ab87cbce9f5f4 /gcc/cp | |
parent | 4a5d353fa8b904fb64df60f68d7c7a542dd20aa6 (diff) | |
download | gcc-ea8b8aa005a994ce5d3e5437c780a35a2c27ff4e.zip gcc-ea8b8aa005a994ce5d3e5437c780a35a2c27ff4e.tar.gz gcc-ea8b8aa005a994ce5d3e5437c780a35a2c27ff4e.tar.bz2 |
re PR c++/43790 ([C++0x] In lambda express, calling member function of non-captured class gives internal compiler error)
PR c++/43790
* tree.c (cv_unqualified): Handle error_mark_node.
From-SVN: r158801
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/ChangeLog | 3 | ||||
-rw-r--r-- | gcc/cp/tree.c | 7 |
2 files changed, 9 insertions, 1 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index f7456bf..68c6b49 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,8 @@ 2010-04-27 Jason Merrill <jason@redhat.com> + PR c++/43790 + * tree.c (cv_unqualified): Handle error_mark_node. + PR c++/41468 * call.c (convert_like_real) [ck_ambig]: Just return error_mark_node if we don't want errors. diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c index 27ced53..0abc12c 100644 --- a/gcc/cp/tree.c +++ b/gcc/cp/tree.c @@ -934,7 +934,12 @@ cp_build_qualified_type_real (tree type, tree cv_unqualified (tree type) { - int quals = TYPE_QUALS (type); + int quals; + + if (type == error_mark_node) + return type; + + quals = TYPE_QUALS (type); quals &= ~(TYPE_QUAL_CONST|TYPE_QUAL_VOLATILE); return cp_build_qualified_type (type, quals); } |