This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/49171] [C++0x][constexpr] Constant expressions support reinterpret_cast


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49171

--- Comment #4 from Daniel KrÃgler <daniel.kruegler at googlemail dot com> 2012-10-03 16:22:24 UTC ---
(In reply to comment #3)
> Daniel, what's the status of this issue? Is there some consensus that GCC is
> actually Ok, we don't really want to reject reinterpret_casts?

My opinion is that gcc should start to implement the new core rules in regard
to reinterpret_cast *except* for cases that are well-defined.

> Because I would find very useful a constexpr std::addressof. For the time being
> we could certainly have it constexpr anyway and change the implementation
> details when/if the C++ front-end starts rejecting reintepret_casts, but I
> would rather not.

Exactly this usage of reinterpret_cast seems IMO to be well granted by the
standard - at least by the way I read it.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]