summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/cp/ChangeLog6
-rw-r--r--gcc/cp/pt.c3
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/g++.dg/cpp0x/decltype32.C4
4 files changed, 15 insertions, 3 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 0427a197503..0a5292f2729 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,9 @@
+2012-09-20 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/52432
+ * pt.c (tsubst_copy_and_build): If tf_error is not set in the complain
+ argument don't call unqualified_name_lookup_error.
+
2012-09-19 Marc Glisse <marc.glisse@inria.fr>
PR c++/54581
diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c
index 16952bffa0c..d00470eec18 100644
--- a/gcc/cp/pt.c
+++ b/gcc/cp/pt.c
@@ -13771,7 +13771,8 @@ tsubst_copy_and_build (tree t,
}
if (TREE_CODE (function) == IDENTIFIER_NODE)
{
- unqualified_name_lookup_error (function);
+ if (complain & tf_error)
+ unqualified_name_lookup_error (function);
release_tree_vector (call_args);
RETURN (error_mark_node);
}
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 8283c8eccbe..e419eb121ac 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2012-09-20 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/52432
+ * g++.dg/cpp0x/decltype32.C: Tweak.
+
2012-09-20 Marc Glisse <marc.glisse@inria.fr>
* gcc.dg/tree-ssa/forwprop-19.c: Check in forwprop1.
diff --git a/gcc/testsuite/g++.dg/cpp0x/decltype32.C b/gcc/testsuite/g++.dg/cpp0x/decltype32.C
index 6cb637bb2dd..ac1f5d14b9c 100644
--- a/gcc/testsuite/g++.dg/cpp0x/decltype32.C
+++ b/gcc/testsuite/g++.dg/cpp0x/decltype32.C
@@ -3,10 +3,10 @@
template <typename T>
auto make_array(const T& il) ->
-decltype(make_array(il)) // { dg-error "not declared" }
+decltype(make_array(il)) // { dg-error "not declared|no matching|exceeds" }
{ }
int main()
{
- int z = make_array(1); // { dg-error "no match" }
+ int z = make_array(1); // { dg-error "no matching" }
}