diff options
author | Nathaniel Shead <nathanieloshead@gmail.com> | 2023-07-13 17:40:10 -0400 |
---|---|---|
committer | Jason Merrill <jason@redhat.com> | 2023-07-14 18:41:39 -0400 |
commit | 12a1162072eef9b6cdf07a3e3889def18a836221 (patch) | |
tree | ae0b696c370ac7a7f9432f2241392c2c2333631c /gcc/cp/constexpr.cc | |
parent | 8d344146727da02eb5c62fbf6cee97a4e96d63db (diff) | |
download | gcc-12a1162072eef9b6cdf07a3e3889def18a836221.zip gcc-12a1162072eef9b6cdf07a3e3889def18a836221.tar.gz gcc-12a1162072eef9b6cdf07a3e3889def18a836221.tar.bz2 |
c++: style tweak
At this point r == t, but it makes more sense to refer to t like all the
other cases do.
gcc/cp/ChangeLog:
* constexpr.cc (cxx_eval_constant_expression): Pass t to get_value.
Signed-off-by: Nathaniel Shead <nathanieloshead@gmail.com>
Diffstat (limited to 'gcc/cp/constexpr.cc')
-rw-r--r-- | gcc/cp/constexpr.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/cp/constexpr.cc b/gcc/cp/constexpr.cc index 9f96a6c..c6f323e 100644 --- a/gcc/cp/constexpr.cc +++ b/gcc/cp/constexpr.cc @@ -7085,7 +7085,7 @@ cxx_eval_constant_expression (const constexpr_ctx *ctx, tree t, case PARM_DECL: if (lval && !TYPE_REF_P (TREE_TYPE (t))) /* glvalue use. */; - else if (tree v = ctx->global->get_value (r)) + else if (tree v = ctx->global->get_value (t)) r = v; else if (lval) /* Defer in case this is only used for its type. */; |