diff options
author | Zachary Turner <zturner@google.com> | 2019-01-02 18:33:32 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2019-01-02 18:33:32 +0000 |
commit | d6d29a5812d6231098b20d74bbe11793fe3e7706 (patch) | |
tree | ed38dfe0777e83ce26f2d0d3a80f6911d39e4a8e /lldb/lit/SymbolFile/NativePDB | |
parent | ba797b6daed513b6c5a560976766767d795036c7 (diff) | |
download | bcm5719-llvm-d6d29a5812d6231098b20d74bbe11793fe3e7706.tar.gz bcm5719-llvm-d6d29a5812d6231098b20d74bbe11793fe3e7706.zip |
[NativePDB] Update function-types-classes test to check VarDecls.
A Previous patch added support for creating VarDecls for global
variables. This patch updates this test to be more strict and
actually check these, not just the types.
llvm-svn: 350242
Diffstat (limited to 'lldb/lit/SymbolFile/NativePDB')
-rw-r--r-- | lldb/lit/SymbolFile/NativePDB/function-types-classes.cpp | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/lldb/lit/SymbolFile/NativePDB/function-types-classes.cpp b/lldb/lit/SymbolFile/NativePDB/function-types-classes.cpp index 87cd23d35af..5670f9bd1e1 100644 --- a/lldb/lit/SymbolFile/NativePDB/function-types-classes.cpp +++ b/lldb/lit/SymbolFile/NativePDB/function-types-classes.cpp @@ -96,7 +96,7 @@ auto g = &three<B::A::S*, A::C::S&, A::B::S*>; // parameter types that are themselves template instantiations. auto h = &four<TC<void>, TC<int>, TC<TC<int>>, TC<A::B::S>>; -// CHECK: (TC<void> (*)(TC<int>, TC<struct TC<int>>, TC<struct A::B::S>)) h = {{.*}} +// CHECK: (TC<void> (*)(TC<int>, TC<TC<int>>, TC<A::B::S>)) h = {{.*}} auto i = &nullary<A::B::S>; // CHECK: (A::B::S (*)()) i = {{.*}} @@ -112,6 +112,10 @@ auto incomplete = &three<Incomplete*, Incomplete**, const Incomplete*>; // CHECK: |-CXXRecordDecl {{.*}} union U // CHECK: |-EnumDecl {{.*}} E // CHECK: |-CXXRecordDecl {{.*}} struct S +// CHECK: |-VarDecl {{.*}} a 'S (*)(C *, U &, E &&)'
+// CHECK: |-VarDecl {{.*}} b 'E (*)(const S *, const C &, const U &&)'
+// CHECK: |-VarDecl {{.*}} c 'U (*)(volatile E *, volatile S &, volatile C &&)'
+// CHECK: |-VarDecl {{.*}} d 'C (*)(const volatile U *, const volatile E &, const volatile S &&)' // CHECK: |-CXXRecordDecl {{.*}} struct B // CHECK: | |-CXXRecordDecl {{.*}} struct A // CHECK: | | |-CXXRecordDecl {{.*}} struct S @@ -120,11 +124,17 @@ auto incomplete = &three<Incomplete*, Incomplete**, const Incomplete*>; // CHECK: | | |-CXXRecordDecl {{.*}} struct S // CHECK: | `-NamespaceDecl {{.*}} B // CHECK: | `-CXXRecordDecl {{.*}} struct S +// CHECK: |-VarDecl {{.*}} e 'A::B::S *(*)(B::A::S *, A::C::S &)'
+// CHECK: |-VarDecl {{.*}} f 'A::C::S &(*)(A::B::S *, B::A::S *)'
+// CHECK: |-VarDecl {{.*}} g 'B::A::S *(*)(A::C::S &, A::B::S *)' // CHECK: |-CXXRecordDecl {{.*}} struct TC<int> -// CHECK: |-CXXRecordDecl {{.*}} struct TC<struct TC<int>> -// CHECK: |-CXXRecordDecl {{.*}} struct TC<struct A::B::S> +// CHECK: |-CXXRecordDecl {{.*}} struct TC<TC<int>> +// CHECK: |-CXXRecordDecl {{.*}} struct TC<A::B::S> // CHECK: |-CXXRecordDecl {{.*}} struct TC<void> +// CHECK: |-VarDecl {{.*}} h 'TC<void> (*)(TC<int>, TC<TC<int>>, TC<A::B::S>)'
+// CHECK: |-VarDecl {{.*}} i 'A::B::S (*)()' // CHECK: |-CXXRecordDecl {{.*}} struct Incomplete +// CHECK: |-VarDecl {{.*}} incomplete 'Incomplete *(*)(Incomplete **, const Incomplete *)' int main(int argc, char **argv) { return 0; |