nickdesaulniers accepted this revision.
nickdesaulniers added a comment.
This revision is now accepted and ready to land.
Consider adding an AST test; that was something that came up in my patch 
https://reviews.llvm.org/D95408.

> I'm pushing back on the WG14 lists to see if this is a good opportunity to 
> clarify the other direction and be compatible with C++ in the process.

It would really be good to have some clarification from WG14 added to the spec; 
as is, code is being written in the Linux kernel that uses this functionality 
to avoid marking all members of an anonymous aggregate as `const`. This is 
resulting in code being submitted where clang doesn't error on modification of 
such members, while GCC errors, so such patches are rejected.  So developers 
using clang are getting caught off guard for a code base that needs to be 
compiler portable.

Kernel developers were of the opinion that it is nice syntactic sugar. For that 
reason, I agree with them. But I'm also fine leaving this out of clang until 
the spec is amended to clarify.  That said, if WG14 doesn't pursue this (but 
doesn't reject or accept), I'd like to have this in clang sooner for better 
compatibility with GCC.  It is too bad though if WG14 chooses to further 
diverge C from C++ over this...


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D125167/new/

https://reviews.llvm.org/D125167

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to