summaryrefslogtreecommitdiff
path: root/test/Index/comment-to-html-xml-conversion.cpp
diff options
context:
space:
mode:
authorManuel Klimek <klimek@google.com>2013-01-07 18:10:23 +0000
committerManuel Klimek <klimek@google.com>2013-01-07 18:10:23 +0000
commitde7685487c5d628dd9fe64c4f861cd1888f50fc7 (patch)
tree53a21aaf4c9eebde9af749c584608db3410c69d3 /test/Index/comment-to-html-xml-conversion.cpp
parentc3cd2b0d538e4db78f1bcbedd0085e2005ce5c51 (diff)
downloadclang-de7685487c5d628dd9fe64c4f861cd1888f50fc7.tar.gz
clang-de7685487c5d628dd9fe64c4f861cd1888f50fc7.tar.bz2
clang-de7685487c5d628dd9fe64c4f861cd1888f50fc7.tar.xz
Fix parsing of variable declarations directly after a class / struct.
Previous indent: class A { } a; void f() { }; With this patch: class A { } a; void f() { } ; The patch introduces a production for classes and structs, and parses the rest of the line to the semicolon after the class scope. This allowed us to remove a long-standing wart in the parser that would just much the semicolon after any block. Due to this suboptimal formating some tests were broken. Some unrelated formatting tests broke; those hit a bug in the ast printing, and need to be fixed separately. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@171761 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Index/comment-to-html-xml-conversion.cpp')
-rw-r--r--test/Index/comment-to-html-xml-conversion.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/Index/comment-to-html-xml-conversion.cpp b/test/Index/comment-to-html-xml-conversion.cpp
index 1ab49d6fc0..139120ec05 100644
--- a/test/Index/comment-to-html-xml-conversion.cpp
+++ b/test/Index/comment-to-html-xml-conversion.cpp
@@ -670,7 +670,7 @@ void comment_to_xml_conversion_10(int aaa, int bbb);
template<typename T, typename U>
class comment_to_xml_conversion_11 { };
-// CHECK: comment-to-html-xml-conversion.cpp:[[@LINE-2]]:7: ClassTemplate=comment_to_xml_conversion_11:{{.*}} FullCommentAsXML=[<Class templateKind="template" file="{{[^"]+}}comment-to-html-xml-conversion.cpp" line="[[@LINE-2]]" column="7"><Name>comment_to_xml_conversion_11</Name><USR>c:@CT&gt;2#T#T@comment_to_xml_conversion_11</USR><Declaration>template &lt;typename T = int, typename U = int&gt;\nclass comment_to_xml_conversion_11 {\n}\ntemplate &lt;typename T, typename U&gt; class comment_to_xml_conversion_11 {\n}</Declaration><Abstract><Para> Aaa.</Para></Abstract></Class>]
+// CHECK: comment-to-html-xml-conversion.cpp:[[@LINE-2]]:7: ClassTemplate=comment_to_xml_conversion_11:{{.*}} FullCommentAsXML=[<Class templateKind="template" file="{{[^"]+}}comment-to-html-xml-conversion.cpp" line="[[@LINE-2]]" column="7"><Name>comment_to_xml_conversion_11</Name><USR>c:@CT&gt;2#T#T@comment_to_xml_conversion_11</USR><Declaration>template &lt;typename T = int, typename U = int&gt;\nclass comment_to_xml_conversion_11 {\n} template &lt;typename T, typename U&gt; class comment_to_xml_conversion_11 {\n}</Declaration><Abstract><Para> Aaa.</Para></Abstract></Class>]
/// Aaa.
template<typename T>