Commit 12d0e3aa by Jason Merrill

constexpr.c, pt.c: Adjust comments.

	* constexpr.c, pt.c: Adjust comments.

	* g++.dg/cpp1y/lambda-generic-69078-1.C: Remove #include.

From-SVN: r254272
parent f26881e3
...@@ -1269,8 +1269,7 @@ cxx_bind_parameters_in_call (const constexpr_ctx *ctx, tree t, ...@@ -1269,8 +1269,7 @@ cxx_bind_parameters_in_call (const constexpr_ctx *ctx, tree t,
{ {
x = ctx->object; x = ctx->object;
/* We don't use cp_build_addr_expr here because we don't want to /* We don't use cp_build_addr_expr here because we don't want to
capture the object argument until we've chosen a non-static member capture the object argument during constexpr evaluation. */
function. */
x = build_address (x); x = build_address (x);
} }
bool lval = false; bool lval = false;
......
...@@ -5564,7 +5564,7 @@ push_template_decl_real (tree decl, bool is_friend) ...@@ -5564,7 +5564,7 @@ push_template_decl_real (tree decl, bool is_friend)
(TI_ARGS (tinfo), (TI_ARGS (tinfo),
TI_ARGS (get_template_info (DECL_TEMPLATE_RESULT (tmpl))))) TI_ARGS (get_template_info (DECL_TEMPLATE_RESULT (tmpl)))))
{ {
error ("template arguments to %qD do not match original" error ("template arguments to %qD do not match original "
"template %qD", decl, DECL_TEMPLATE_RESULT (tmpl)); "template %qD", decl, DECL_TEMPLATE_RESULT (tmpl));
if (!uses_template_parms (TI_ARGS (tinfo))) if (!uses_template_parms (TI_ARGS (tinfo)))
inform (input_location, "use %<template<>%> for" inform (input_location, "use %<template<>%> for"
...@@ -12195,7 +12195,7 @@ tsubst_function_decl (tree t, tree args, tsubst_flags_t complain, ...@@ -12195,7 +12195,7 @@ tsubst_function_decl (tree t, tree args, tsubst_flags_t complain,
We also deal with the peculiar case: We also deal with the peculiar case:
template <class T> struct S { template <class T> struct S {
template <class U> friend void f(); template <class U> friend void f();
}; };
template <class U> void f() {} template <class U> void f() {}
template S<int>; template S<int>;
......
...@@ -2,8 +2,6 @@ ...@@ -2,8 +2,6 @@
// { dg-do run { target c++14 } } // { dg-do run { target c++14 } }
// { dg-options "-Wall" } // { dg-options "-Wall" }
#include <cassert>
struct Class { struct Class {
Class(void (*_param)()) : data(_param) {} Class(void (*_param)()) : data(_param) {}
void (*data)(); void (*data)();
...@@ -15,7 +13,7 @@ void funUser(void (*test)(int)) { ...@@ -15,7 +13,7 @@ void funUser(void (*test)(int)) {
void user(Class& c, int i) { void user(Class& c, int i) {
(void)i; (void)i;
assert (c.data); if (!c.data) __builtin_abort();
} }
void probe() {} void probe() {}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment