Forgot to add cfe-commits.

On Wed, Jul 10, 2013 at 7:07 PM, Eli Friedman <[email protected]> wrote:
> On Wed, Jul 10, 2013 at 5:40 PM, Richard Smith <[email protected]> wrote:
>> The attached patch adds a __builtin_addressof, that performs the same
>> functionality as the built-in & operator (ignoring any overloaded
>> operator& for the type). The purpose of this builtin is for use in
>> std::addressof, to allow it to be made constexpr; the existing
>> implementation technique (reinterpret_cast to some reference type,
>> take address, reinterpert_cast back) does not permit this because
>> reinterpret_cast between reference types is not permitted in a
>> constant expression in C++11 onwards.
>
> Not really an objection, but why do we disallow reinterpret_casts in
> constant expressions in the first place?  It seems like it would be
> convenient functionality to have.
>
> Minor review comment: please commit moving CheckAddressOfOperand onto
> Sema in a separate patch.
>
> -Eli
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to