diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2015-01-28 22:06:01 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2015-01-28 22:06:01 +0000 |
commit | 1ae689c2b8759e4cb5bc9ff334b02c58752f2717 (patch) | |
tree | 27052790b91041b39277fa060bb46918de0e98fd /clang/test/SemaCXX/ast-print.cpp | |
parent | 80bd3c9e5fb2b5080435a7288267ab18d21a57ac (diff) | |
download | bcm5719-llvm-1ae689c2b8759e4cb5bc9ff334b02c58752f2717.tar.gz bcm5719-llvm-1ae689c2b8759e4cb5bc9ff334b02c58752f2717.zip |
PR22367: Don't forget to create a CXXFunctionalCastExpr around
list-initialization that gets converted to some form other than an
InitListExpr. CXXTemporaryObjectExpr is a special case here, because it
represents a fused CXXFunctionalCastExpr + CXXConstructExpr. That, in
itself, is probably a design error...
llvm-svn: 227377
Diffstat (limited to 'clang/test/SemaCXX/ast-print.cpp')
-rw-r--r-- | clang/test/SemaCXX/ast-print.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/ast-print.cpp b/clang/test/SemaCXX/ast-print.cpp index baece3c2b32..b0bf245e5cb 100644 --- a/clang/test/SemaCXX/ast-print.cpp +++ b/clang/test/SemaCXX/ast-print.cpp @@ -213,3 +213,9 @@ namespace { // CHECK: struct {{\[\[gnu::visibility\(\"hidden\"\)\]\]}} S; struct [[gnu::visibility("hidden")]] S; } + +// CHECK: struct CXXFunctionalCastExprPrint fce = CXXFunctionalCastExprPrint{ }; +struct CXXFunctionalCastExprPrint {} fce = CXXFunctionalCastExprPrint{}; + +// CHECK: struct CXXTemporaryObjectExprPrint toe = CXXTemporaryObjectExprPrint{}; +struct CXXTemporaryObjectExprPrint { CXXTemporaryObjectExprPrint(); } toe = CXXTemporaryObjectExprPrint{}; |