[PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-12 Thread Alex Lorenz via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL283995: [Sema] Handle transparent_union attributes in C mode only (authored by arphaman). Changed prior to commit: https://reviews.llvm.org/D25308?vs=74127&id=74350#toc Repository: rL LLVM https://r

[PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-11 Thread Alex Lorenz via cfe-commits
arphaman added a comment. Thanks! Comment at: include/clang/Basic/Attr.td:1545 // let Subjects = SubjectList<[Record, TypedefName]>; let Documentation = [Undocumented]; + let LangOpts = [COnly]; aaron.ballman wrote: > If you, or anyone else, is bored, it

[PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-10 Thread Aaron Ballman via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. In https://reviews.llvm.org/D25308#566176, @arphaman wrote: > The updated patch now makes clang warn every time it encounters this > attribute in C++ mode. Would that be the desi

Re: [PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-10 Thread Hal Finkel via cfe-commits
- Original Message - > From: "Richard Smith" > To: reviews+d25308+public+96c9b20dd11b9...@reviews.llvm.org, "Hal > Finkel" > Cc: "Alex L" , "Reid Kleckner" , > "Aaron Ballman" , "cfe-commits" > > Sent:

Re: [PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-10 Thread Richard Smith via cfe-commits
On Mon, Oct 10, 2016 at 10:45 AM, Hal Finkel via cfe-commits < cfe-commits@lists.llvm.org> wrote: > hfinkel added a comment. > > In https://reviews.llvm.org/D25308#566176, @arphaman wrote: > > > The updated patch now makes clang warn every time it encounters this > attribute in C++ mode. Would tha

[PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-10 Thread Hal Finkel via cfe-commits
hfinkel added a comment. In https://reviews.llvm.org/D25308#566176, @arphaman wrote: > The updated patch now makes clang warn every time it encounters this > attribute in C++ mode. Would that be the desired behaviour? As I understand it, transparent_union was designed for use in system headers

[PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-10 Thread Alex Lorenz via cfe-commits
arphaman added a comment. The updated patch now makes clang warn every time it encounters this attribute in C++ mode. Would that be the desired behaviour? Repository: rL LLVM https://reviews.llvm.org/D25308 ___ cfe-commits mailing list cfe-commi

[PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-10 Thread Alex Lorenz via cfe-commits
arphaman updated this revision to Diff 74127. arphaman marked an inline comment as done. arphaman added a comment. The updated patch uses a proper way to mark the attribute as C only. Repository: rL LLVM https://reviews.llvm.org/D25308 Files: include/clang/Basic/Attr.td test/SemaCXX/attr

[PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-10 Thread Aaron Ballman via cfe-commits
aaron.ballman requested changes to this revision. aaron.ballman added inline comments. This revision now requires changes to proceed. Comment at: lib/Sema/SemaDeclAttr.cpp:3011 const AttributeList &Attr) { + if (S.getLangOpts().CPlusPlus)

[PATCH] D25308: [Sema] Ignore transparent_union attributes in C++

2016-10-06 Thread Alex Lorenz via cfe-commits
arphaman created this revision. arphaman added reviewers: rnk, aaron.ballman. arphaman added a subscriber: cfe-commits. arphaman set the repository for this revision to rL LLVM. While working on fixing PR30520 yesterday I noticed that clang also crashes on code like this: template union u {