[cfe-commits] r150318 - in /cfe/trunk: include/clang/AST/ include/clang/Sema/ lib/AST/ lib/CodeGen/ lib/Parse/ lib/Sema/ lib/Serialization/ test/CXX/temp/temp.decls/temp.variadic/ test/Sema/ test/SemaTemplate/

Richard Smith richard at metafoo.co.uk
Tue Feb 14 12:44:47 PST 2012

On Sat, Feb 11, 2012 at 3:51 PM, Sebastian Redl <
sebastian.redl at getdesigned.at> wrote:

> Author: cornedbee
> Date: Sat Feb 11 17:51:47 2012
> New Revision: 150318
> URL: http://llvm.org/viewvc/llvm-project?rev=150318&view=rev
> Log:
> Represent C++ direct initializers as ParenListExprs before semantic
> analysis
> instead of having a special-purpose function.
> - ActOnCXXDirectInitializer, which was mostly duplication of
>  AddInitializerToDecl (leading e.g. to PR10620, which Eli fixed a few days
>  ago), is dropped completely.
> - MultiInitializer, which was an ugly hack I added, is dropped again.
> - We now have the infrastructure in place to distinguish between
>  int x = {1};
>  int x({1});
>  int x{1};

g++4.6 has a bug where it silently accepts "t({...})" as if it were a
brace-or-init-list initializer in a constructor's member initializer list.
By the law of nature that for every g++ "extension" there is an equal and
opposite libstdc++ bug, libstdc++ 4.6's <bitset> uses this syntax to
initialize its member array in C++11 mode. Is it feasible to downgrade the
error in this particular case to an ExtWarn?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120214/2c5daf73/attachment.html>

More information about the cfe-commits mailing list