aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/method.c
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@acm.org>2019-04-29 15:22:41 +0000
committerNathan Sidwell <nathan@gcc.gnu.org>2019-04-29 15:22:41 +0000
commit348dd384c8f647ba56be21932d068d180be243e3 (patch)
treed90b262f2e2e18807b5a05fa37174d4ad1ceb35b /gcc/cp/method.c
parent074084767c9d7c4d52d919c343b65bb61c564096 (diff)
downloadgcc-348dd384c8f647ba56be21932d068d180be243e3.zip
gcc-348dd384c8f647ba56be21932d068d180be243e3.tar.gz
gcc-348dd384c8f647ba56be21932d068d180be243e3.tar.bz2
[C++ PATCH] some cleanups
https://gcc.gnu.org/ml/gcc-patches/2019-04/msg01174.html * decl.c (duplicate_decls): Add whitespace, move comments into conditional blocks. * method.c (explain_implicit_non_constexpr): Refactor. * pt.c (check_explicit_specialization): Fix indentation. * semantics.c (process_outer_var_ref): Reformat. (finish_id_expression_1): Use STRIP_TEMPLATE. From-SVN: r270655
Diffstat (limited to 'gcc/cp/method.c')
-rw-r--r--gcc/cp/method.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/gcc/cp/method.c b/gcc/cp/method.c
index 03eea40..d92da09 100644
--- a/gcc/cp/method.c
+++ b/gcc/cp/method.c
@@ -1884,15 +1884,14 @@ maybe_explain_implicit_delete (tree decl)
void
explain_implicit_non_constexpr (tree decl)
{
- tree parm_type = TREE_VALUE (FUNCTION_FIRST_USER_PARMTYPE (decl));
- bool const_p = CP_TYPE_CONST_P (non_reference (parm_type));
+ tree parms = FUNCTION_FIRST_USER_PARMTYPE (decl);
+ bool const_p = CP_TYPE_CONST_P (non_reference (TREE_VALUE (parms)));
tree inh = DECL_INHERITED_CTOR (decl);
bool dummy;
synthesized_method_walk (DECL_CLASS_CONTEXT (decl),
special_function_p (decl), const_p,
NULL, NULL, NULL, &dummy, true,
- &inh,
- FUNCTION_FIRST_USER_PARMTYPE (decl));
+ &inh, parms);
}
/* DECL is an instantiation of an inheriting constructor template. Deduce