Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2017-10-30 Thread Aaron Ballman via cfe-commits
On Sun, Oct 29, 2017 at 4:42 AM, Hristo Hristov via Phabricator wrote: > roccoor added a comment. > > Microsoft supports: > > [[gsl::suppress(bounds.3)]] > > Clang requires: > > [[gsl::suppress("bounds.3")]] > > Why is this inconsistency? I believe that when we added this attribute, MSVC did

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-28 Thread Matthias Gehre via cfe-commits
mgehre added a comment. My main goal is to be able to suppress any clang-tidy warning through an attribute. Initially, I though we could reuse the C++ Core Guidelines attribute for that, (because I though it was plain [[suppress]]). As a bonus (not more), we would have interoperability with oth

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-28 Thread Matthias Gehre via cfe-commits
mgehre added a comment. In the C++ Core Guidelines issue on namespaceing of the [[suppress]], it was state that Microsoft uses [[gsl::suppress]] and it is the intent to update the C++ Core Guidelines to [[gsl::suppress]]. https://reviews.llvm.org/D24886 _

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-27 Thread Malcolm Parsons via cfe-commits
malcolm.parsons added a subscriber: malcolm.parsons. malcolm.parsons added a comment. In https://reviews.llvm.org/D24886#554130, @mgehre wrote: > 2. Also, I suspect we will want this attribute to also be written on types I > was thinking about a case were that was useful, and didn't find any. Wh

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-27 Thread Aaron Ballman via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D24886#554130, @mgehre wrote: > Thank your very much for your comments! > Let me try to give me reasoning for those points: > > 1. But it's missing some pieces, like test cases I though about how to test > this, having no semantic meani

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-27 Thread Matthias Gehre via cfe-commits
mgehre added a comment. Thank your very much for your comments! Let me try to give me reasoning for those points: 1. But it's missing some pieces, like test cases I though about how to test this, having no semantic meaning itself. I could look at the AST dump, but it does not even show the rules

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-26 Thread Aaron Ballman via cfe-commits
aaron.ballman added a comment. In https://reviews.llvm.org/D24886#552859, @rsmith wrote: > Giving this the name `[[clang::suppress(...)]]` seems unhelpful. This > attribute is specified by the C++ core guidelines, not by clang, and > presumably we want code using this attribute to be portable a

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-26 Thread Richard Smith via cfe-commits
rsmith added a comment. Giving this the name `[[clang::suppress(...)]]` seems unhelpful. This attribute is specified by the C++ core guidelines, not by clang, and presumably we want code using this attribute to be portable across implementations of the C++ code guidelines. I'd suggest asking th

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-26 Thread Aaron Ballman via cfe-commits
aaron.ballman requested changes to this revision. aaron.ballman added a comment. This revision now requires changes to proceed. I'm generally in favor of this patch, but it's missing some pieces, like test cases. Also, I suspect we will want this attribute to also be written on types, but there

Re: [PATCH] D24886: Add [[clang::suppress(rule, ...)]] attribute

2016-09-23 Thread Matthias Gehre via cfe-commits
mgehre updated this revision to Diff 72366. mgehre added a comment. Include link to corresponding clang-tidy patch https://reviews.llvm.org/D24886 Files: include/clang/Basic/Attr.td lib/Sema/SemaDeclAttr.cpp lib/Sema/SemaStmtAttr.cpp Index: lib/Sema/SemaStmtAttr.cpp =