8sa1-gcc/gcc/testsuite/g++.old-deja
Jason Merrill 07f56824fd c++: reinterpret_cast from prvalue to rvalue ref [PR98440]
In r260622 I allowed this under the general principle that [basic.lval]
"Whenever a prvalue appears as an operand of an operator that expects a
glvalue for that operand, the temporary materialization conversion (7.3.4)
is applied to convert the expression to an xvalue."  But
[expr.reinterpret.cast] specifically excludes creating a temporary in this
case.

gcc/cp/ChangeLog:

	PR c++/98440
	* typeck.c (build_reinterpret_cast_1): Don't perform
	temporary materialization.

gcc/testsuite/ChangeLog:

	* g++.dg/cpp0x/rv-cast6.C: Expect reinterpret_cast error.
	* g++.dg/cpp0x/reinterpret_cast2.C: Adjust message.
	* g++.old-deja/g++.jason/rvalue3.C: Likewise.
2021-04-05 17:27:00 -04:00
..
g++.abi
g++.benjamin
g++.bob
g++.brendan
g++.bugs
g++.eh
g++.ext
g++.gb
g++.jason
g++.law
g++.martin
g++.mike
g++.niklas
g++.ns
g++.oliva
g++.other
g++.pt
g++.rfg
g++.robertl
g++.warn
old-deja.exp