[cfe-commits] r161450 - in /cfe/trunk: lib/Sema/SemaExprCXX.cpp test/SemaCXX/constant-expression-cxx11.cpp

Eli Friedman eli.friedman at gmail.com
Tue Aug 7 15:27:58 PDT 2012


On Tue, Aug 7, 2012 at 3:06 PM, Richard Smith
<richard-llvm at metafoo.co.uk> wrote:
> Author: rsmith
> Date: Tue Aug  7 17:06:48 2012
> New Revision: 161450
>
> URL: http://llvm.org/viewvc/llvm-project?rev=161450&view=rev
> Log:
> When building a conditional operator where one operand is a throw-expression
> and the other is a glvalue of class type, don't forget to copy-initialize a
> temporary when performing the lvalue-to-rvalue conversion on the glvalue.
> Strangely, DefaultLvalueConversions misses this part of the lvalue-to-rvalue
> conversions.

DefaultLvalueConversions isn't normally used on expressions of class
type in C++.

-Eli



More information about the cfe-commits mailing list