This revision was automatically updated to reflect the committed changes.
Closed by commit rL259898: [ASTMatchers] Allow hasName() to look through inline
namespaces (authored by sbenza).
Changed prior to commit:
http://reviews.llvm.org/D15506?vs=45438&id=47029#toc
Repository:
rL LLVM
http:/
bkramer accepted this revision.
bkramer added a comment.
This revision is now accepted and ready to land.
lg
http://reviews.llvm.org/D15506
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-co
Prazek added a subscriber: Prazek.
Prazek added a comment.
What is the status of it?
http://reviews.llvm.org/D15506
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
sbenza added inline comments.
Comment at: lib/ASTMatchers/ASTMatchersInternal.cpp:351
@@ +350,3 @@
+
+ // First, match the name.
+ if (!MatchNodeName(Pattern, Node))
klimek wrote:
> Perhaps comment that Pattern will be changed to the prefix, so it's clear
> aft
sbenza updated this revision to Diff 45438.
sbenza added a comment.
Rename functions.
http://reviews.llvm.org/D15506
Files:
include/clang/ASTMatchers/ASTMatchersInternal.h
lib/ASTMatchers/ASTMatchersInternal.cpp
unittests/ASTMatchers/ASTMatchersTest.cpp
Index: unittests/ASTMatchers/ASTMa
klimek added a reviewer: bkramer.
klimek added a comment.
Adding Benjamin for an additional pair of eyes.
Generally looks good.
Comment at: lib/ASTMatchers/ASTMatchersInternal.cpp:351
@@ +350,3 @@
+
+ // First, match the name.
+ if (!MatchNodeName(Pattern, Node))
-
alexfh added a subscriber: alexfh.
alexfh added a comment.
Manuel, can you take a look at this?
http://reviews.llvm.org/D15506
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
Eugene.Zelenko added a subscriber: Eugene.Zelenko.
Eugene.Zelenko added a comment.
It'll be great to finalize fix before 3.8 branching (planned at January 13).
http://reviews.llvm.org/D15506
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
ht
sbenza added inline comments.
Comment at: lib/ASTMatchers/ASTMatchersInternal.cpp:322
@@ +321,3 @@
+ for (bool SkipUnwritten : SkipUnwrittenCases) {
+llvm::SmallString<128> NodeName = StringRef("::");
+llvm::raw_svector_ostream OS(NodeName);
yaron.keren w
sbenza updated this revision to Diff 42884.
sbenza added a comment.
Add a faster version of the qualified name matcher.
It falls back to the previous version if it can't handle the name.
http://reviews.llvm.org/D15506
Files:
include/clang/ASTMatchers/ASTMatchersInternal.h
lib/ASTMatchers/AS
yaron.keren added inline comments.
Comment at: lib/ASTMatchers/ASTMatchersInternal.cpp:322
@@ +321,3 @@
+ for (bool SkipUnwritten : SkipUnwrittenCases) {
+llvm::SmallString<128> NodeName = StringRef("::");
+llvm::raw_svector_ostream OS(NodeName);
StringRe
aaron.ballman added inline comments.
Comment at: lib/ASTMatchers/ASTMatchersInternal.cpp:320-331
@@ -323,4 +319,14 @@
- if (Pattern.startswith("::"))
-return FullName == Pattern;
+ const bool SkipUnwrittenCases[] = {false, true};
+ for (bool SkipUnwritten : SkipUnwrittenC
sbenza added a comment.
I am thinking on doing this some other way.
Copying the PrintingPolicy object is very expensive, as it contains quite a few
strings and vectors of strings.
In the past I changed this matcher to make no allocations in the common path
(ie using SmallString<>, etc) to reduce
That's odd. I'm using the same update 5 exactly, added " for (bool
SkipUnwritten : {false, true});" inside a LLVM source file and re-compiled.
MSVC complained about the unused SkipUnwritten but was therwise OK with the
code.
2015-12-14 23:43 GMT+02:00 Aaron Ballman :
> On Mon, Dec 14, 2015 at 4
sbenza updated this revision to Diff 42767.
sbenza added a comment.
Minor fixes
http://reviews.llvm.org/D15506
Files:
lib/ASTMatchers/ASTMatchersInternal.cpp
unittests/ASTMatchers/ASTMatchersTest.cpp
Index: unittests/ASTMatchers/ASTMatchersTest.cpp
=
On Mon, Dec 14, 2015 at 4:39 PM, Yaron Keren wrote:
> MSVC 2013 Update 5 accepts for (bool SkipUnwritten : {false, true}).
> Possibly changed in one of the Updates?
I tested using MSVC 2013 Update 5.
Microsoft Visual Studio Ultimate 2013
Version 12.0.40629.00 Update 5
Microsoft .NET Framework
Ve
MSVC 2013 Update 5 accepts for (bool SkipUnwritten : {false, true}).
Possibly changed in one of the Updates?
2015-12-14 23:35 GMT+02:00 Aaron Ballman via cfe-commits <
cfe-commits@lists.llvm.org>:
> aaron.ballman added a subscriber: aaron.ballman.
>
>
> Comment at: lib/ASTMatcher
aaron.ballman added a subscriber: aaron.ballman.
Comment at: lib/ASTMatchers/ASTMatchersInternal.cpp:320
@@ -323,3 +319,3 @@
- if (Pattern.startswith("::"))
-return FullName == Pattern;
+ for (bool SkipUnwritten : {false, true}) {
+llvm::SmallString<128> NodeName = Str
sbenza created this revision.
sbenza added a reviewer: klimek.
sbenza added a subscriber: cfe-commits.
Herald added a subscriber: klimek.
Allow hasName() to look through inline namespaces.
This will fix the interaction between some clang-tidy checks and libc++.
libc++ defines names in an inline n
19 matches
Mail list logo