[PATCH] [libcxx] Use __decltype instead of __typeof__

Michel Morin mimomorin at gmail.com
Mon Jun 15 08:42:57 PDT 2015


Eric Fiselier wrote:
> PS. I don't like that libc++ provides `decltype` to users in C++03

+1

IMO, defining `decltype` in C++03 is a bad idea as reported in PR12488
( https://llvm.org/bugs/show_bug.cgi?id=12488 );
libc++ should define and use `_LIBCPP_DECLTYPE` instead.

> but I think it's way to late to change that.

Ah yes, too late to change...

P.S.
`__has_feature(is_trivial)` is a bit cryptic, but works as a meta version-check
for "clang >= 3.0".

Regards,
Michel



More information about the cfe-commits mailing list