typeck.c (cp_build_addr_expr_1): Use cp_expr_loc_or_input_loc in three places.
authorPaolo Carlini <paolo.carlini@oracle.com>
Mon, 18 Nov 2019 23:02:22 +0000 (23:02 +0000)
committerPaolo Carlini <paolo@gcc.gnu.org>
Mon, 18 Nov 2019 23:02:22 +0000 (23:02 +0000)
commitf5a191efecf71581a163d85da65bd53be1e58cc0
treeb60f68126acfc30078c2c7623fd52268a52ee599
parentde83907ada394e5be1343fac4fca5d9b5de3db4f
typeck.c (cp_build_addr_expr_1): Use cp_expr_loc_or_input_loc in three places.

/cp
2019-11-18  Paolo Carlini  <paolo.carlini@oracle.com>

* typeck.c (cp_build_addr_expr_1): Use cp_expr_loc_or_input_loc
in three places.
(cxx_sizeof_expr): Use it in one additional place.
(cxx_alignof_expr): Likewise.
(lvalue_or_else): Likewise.

/testsuite
2019-11-18  Paolo Carlini  <paolo.carlini@oracle.com>

* g++.dg/cpp0x/addressof2.C: Test locations too.
* g++.dg/cpp0x/rv-lvalue-req.C: Likewise.
* g++.dg/expr/crash2.C: Likewise.
* g++.dg/expr/lval1.C: Likewise.
* g++.dg/expr/unary2.C: Likewise.
* g++.dg/ext/lvaddr.C: Likewise.
* g++.dg/ext/lvalue1.C: Likewise.
* g++.dg/tree-ssa/pr20280.C: Likewise.
* g++.dg/warn/Wplacement-new-size.C: Likewise.
* g++.old-deja/g++.brendan/alignof.C: Likewise.
* g++.old-deja/g++.brendan/sizeof2.C: Likewise.
* g++.old-deja/g++.law/temps1.C: Likewise.

From-SVN: r278424
15 files changed:
gcc/cp/ChangeLog
gcc/cp/typeck.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/cpp0x/addressof2.C
gcc/testsuite/g++.dg/cpp0x/rv-lvalue-req.C
gcc/testsuite/g++.dg/expr/crash2.C
gcc/testsuite/g++.dg/expr/lval1.C
gcc/testsuite/g++.dg/expr/unary2.C
gcc/testsuite/g++.dg/ext/lvaddr.C
gcc/testsuite/g++.dg/ext/lvalue1.C
gcc/testsuite/g++.dg/tree-ssa/pr20280.C
gcc/testsuite/g++.dg/warn/Wplacement-new-size.C
gcc/testsuite/g++.old-deja/g++.brendan/alignof.C
gcc/testsuite/g++.old-deja/g++.brendan/sizeof2.C
gcc/testsuite/g++.old-deja/g++.law/temps1.C