diff options
Diffstat (limited to 'gcc/cp/decl.c')
-rw-r--r-- | gcc/cp/decl.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index caa04af..86e38f4 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -13202,6 +13202,11 @@ grokdeclarator (const cp_declarator *declarator, ; /* We already issued a permerror. */ else if (decl && DECL_NAME (decl)) { + if (initialized) + /* Kludge: We need funcdef_flag to be true in do_friend for + in-class defaulted functions, but that breaks grokfndecl. + So set it here. */ + funcdef_flag = true; if (template_class_depth (current_class_type) == 0) { decl = check_explicit_specialization |