This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[C++ PATCH] tiny code cleanup
- From: Nathan Sidwell <nathan at acm dot org>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 2 Jan 2018 09:50:19 -0500
- Subject: [C++ PATCH] tiny code cleanup
- Authentication-results: sourceware.org; auth=none
In working on c++/83160 I came across this use-once set-to-constant
'variable'. It made me go looking for a non-existent change to it, so
I'm eliding it.
nathan
--
Nathan Sidwell
2018-01-02 Nathan Sidwell <nathan@acm.org>
* constexpr.c (cxx_bind_parameters_in_call): Remove unneeded local
lval var.
Index: constexpr.c
===================================================================
--- constexpr.c (revision 256070)
+++ constexpr.c (working copy)
@@ -1291,8 +1291,7 @@ cxx_bind_parameters_in_call (const const
x = ctx->object;
x = build_address (x);
}
- bool lval = false;
- arg = cxx_eval_constant_expression (ctx, x, lval,
+ arg = cxx_eval_constant_expression (ctx, x, /*lval=*/false,
non_constant_p, overflow_p);
/* Don't VERIFY_CONSTANT here. */
if (*non_constant_p && ctx->quiet)