diff options
| author | Richard Smith <richard-llvm@metafoo.co.uk> | 2013-05-21 05:24:00 +0000 |
|---|---|---|
| committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2013-05-21 05:24:00 +0000 |
| commit | b39b9d57350edbb7116715042fe7543dacba5fb4 (patch) | |
| tree | 12657bb188a94d132ea38728e24c2a2816d9a831 /clang/test | |
| parent | db142d4e1e64de6288803741683f97660c4a8981 (diff) | |
| download | bcm5719-llvm-b39b9d57350edbb7116715042fe7543dacba5fb4.tar.gz bcm5719-llvm-b39b9d57350edbb7116715042fe7543dacba5fb4.zip | |
In -ast-dump, only dump comments when dumping the actual Decl to which they
attach, rather than merging all comments on the declaration chain. This gives a
more faithful dump, and has the side benefit of unbreaking uses of dump() from
within AST deserialization (where the redeclaration chain may not be sane).
llvm-svn: 182350
Diffstat (limited to 'clang/test')
| -rw-r--r-- | clang/test/Misc/ast-dump-decl.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/clang/test/Misc/ast-dump-decl.cpp b/clang/test/Misc/ast-dump-decl.cpp index 31715cd15e4..d98bdb56d5b 100644 --- a/clang/test/Misc/ast-dump-decl.cpp +++ b/clang/test/Misc/ast-dump-decl.cpp @@ -458,3 +458,19 @@ namespace TestFriendDecl2 { // CHECK: |-CXXRecordDecl {{.*}} struct S // CHECK: `-FriendDecl // CHECK: `-FunctionDecl {{.*}} parent [[TestFriendDecl2]] prev [[TestFriendDecl2_f]] <{{.*}}> f 'void (void)' + +namespace Comment { + extern int Test; + /// Something here. + extern int Test; + extern int Test; +} + +// CHECK: VarDecl {{.*}} Test 'int' extern +// CHECK-NOT: FullComment +// CHECK: VarDecl {{.*}} Test 'int' extern +// CHECK: `-FullComment +// CHECK: `-ParagraphComment +// CHECK: `-TextComment +// CHECK: VarDecl {{.*}} Test 'int' extern +// CHECK-NOT: FullComment |

