[Lldb-commits] [PATCH] D42939: More correct handling of error cases C++ name parser
Eugene Zemtsov via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Tue Feb 6 11:06:10 PST 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rL324380: More correct handling of error cases C++ name parser (authored by eugene, committed by ).
Herald added a subscriber: llvm-commits.
Changed prior to commit:
https://reviews.llvm.org/D42939?vs=132916&id=133052#toc
Repository:
rL LLVM
https://reviews.llvm.org/D42939
Files:
lldb/trunk/source/Plugins/Language/CPlusPlus/CPlusPlusNameParser.cpp
lldb/trunk/unittests/Language/CPlusPlus/CPlusPlusLanguageTest.cpp
Index: lldb/trunk/unittests/Language/CPlusPlus/CPlusPlusLanguageTest.cpp
===================================================================
--- lldb/trunk/unittests/Language/CPlusPlus/CPlusPlusLanguageTest.cpp
+++ lldb/trunk/unittests/Language/CPlusPlus/CPlusPlusLanguageTest.cpp
@@ -160,4 +160,6 @@
"selector:otherField:", context, basename));
EXPECT_FALSE(CPlusPlusLanguage::ExtractContextAndIdentifier(
"abc::", context, basename));
+ EXPECT_FALSE(CPlusPlusLanguage::ExtractContextAndIdentifier(
+ "f<A<B><C>>", context, basename));
}
Index: lldb/trunk/source/Plugins/Language/CPlusPlus/CPlusPlusNameParser.cpp
===================================================================
--- lldb/trunk/source/Plugins/Language/CPlusPlus/CPlusPlusNameParser.cpp
+++ lldb/trunk/source/Plugins/Language/CPlusPlus/CPlusPlusNameParser.cpp
@@ -242,8 +242,7 @@
}
}
- assert(template_counter >= 0);
- if (template_counter > 0) {
+ if (template_counter != 0) {
return false;
}
start_position.Remove();
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D42939.133052.patch
Type: text/x-patch
Size: 1036 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20180206/c5a6d27c/attachment.bin>
More information about the lldb-commits
mailing list