+2018-09-18 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/85065
+ * cp-tree.h (NON_ERROR): New.
+ * pt.c (auto_hash::hash): Use it.
+ (do_auto_deduction): Likewise.
+
2018-09-18 Nathan Sidwell <nathan@acm.org>
PR c++/86881
/* In parser.c. */
extern tree cp_literal_operator_id (const char *);
+#define NON_ERROR(NODE) ((NODE) == error_mark_node ? NULL_TREE : (NODE))
+
/* TRUE if a tree code represents a statement. */
extern bool statement_code_p[MAX_TREE_CODES];
inline hashval_t
auto_hash::hash (tree t)
{
- if (tree c = PLACEHOLDER_TYPE_CONSTRAINTS (t))
+ if (tree c = NON_ERROR (PLACEHOLDER_TYPE_CONSTRAINTS (t)))
/* Matching constrained-type-specifiers denote the same template
parameter, so hash the constraint. */
return hash_placeholder_constraint (c);
/* Check any placeholder constraints against the deduced type. */
if (flag_concepts && !processing_template_decl)
- if (tree constr = PLACEHOLDER_TYPE_CONSTRAINTS (auto_node))
+ if (tree constr = NON_ERROR (PLACEHOLDER_TYPE_CONSTRAINTS (auto_node)))
{
/* Use the deduced type to check the associated constraints. If we
have a partial-concept-id, rebuild the argument list so that
+2018-09-18 Paolo Carlini <paolo.carlini@oracle.com>
+
+ PR c++/85065
+ * g++.dg/concepts/pr85065.C: New.
+
2018-09-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
PR testsuite/87339
2018-09-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
- * gcc.target/aarch64/spellcheck_1.c:
- Make architecture suggestion optional.
- * gcc.target/aarch64/spellcheck_4.c:
- Likewise.
+ * gcc.target/aarch64/spellcheck_1.c:
+ Make architecture suggestion optional.
+ * gcc.target/aarch64/spellcheck_4.c:
+ Likewise.
2018-09-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
--- /dev/null
+// { dg-do compile { target c++14 } }
+// { dg-additional-options "-fconcepts" }
+
+template<int> concept bool C = true;
+
+C c = 0; // { dg-error "invalid reference to concept" }