summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/ast-print.cpp
diff options
context:
space:
mode:
authorVassil Vassilev <v.g.vassilev@gmail.com>2016-07-08 16:04:22 +0000
committerVassil Vassilev <v.g.vassilev@gmail.com>2016-07-08 16:04:22 +0000
commitcdaa31fe84f1c6ee7cefd06763e1c85ddeccb76f (patch)
tree3762274bc23cb70006767955e1d472e366e22267 /clang/test/SemaCXX/ast-print.cpp
parentc813c8113db77b11a32edbdb23c6cc9f441f7ea6 (diff)
downloadbcm5719-llvm-cdaa31fe84f1c6ee7cefd06763e1c85ddeccb76f.tar.gz
bcm5719-llvm-cdaa31fe84f1c6ee7cefd06763e1c85ddeccb76f.zip
Don't crash when printing auto variables.
Patch by Axel Naumann! llvm-svn: 274859
Diffstat (limited to 'clang/test/SemaCXX/ast-print.cpp')
-rw-r--r--clang/test/SemaCXX/ast-print.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/ast-print.cpp b/clang/test/SemaCXX/ast-print.cpp
index 39a52ab8d7e..733931803b4 100644
--- a/clang/test/SemaCXX/ast-print.cpp
+++ b/clang/test/SemaCXX/ast-print.cpp
@@ -227,3 +227,12 @@ template <typename T> struct Foo : T {
using T::operator-;
};
}
+
+namespace dont_crash {
+struct T { enum E {X = 12ll }; };
+struct S {
+ struct { int I; } ADecl;
+ static const auto Y = T::X;
+};
+//CHECK: static const auto Y = T::X;
+}
OpenPOWER on IntegriCloud