diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2012-10-18 20:58:58 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2012-10-18 20:58:58 +0000 |
commit | eafa9d4d0d8b97f006dbd19c1e51d14663c8c5c3 (patch) | |
tree | 4454c1b2f731b3898f29fe29a5077c1f4537ccf3 | |
parent | d03ef04ed32e9c9d7c714e8f1b31693c5b907dd2 (diff) |
Remove check which incorrectly suppressed printing an identifier in type printing. Patch by Benoit Perrot.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166227 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/AST/TypePrinter.cpp | 3 | ||||
-rw-r--r-- | test/SemaCXX/ast-print.cpp | 5 |
2 files changed, 5 insertions, 3 deletions
diff --git a/lib/AST/TypePrinter.cpp b/lib/AST/TypePrinter.cpp index 2c00246301..4cf4b1847f 100644 --- a/lib/AST/TypePrinter.cpp +++ b/lib/AST/TypePrinter.cpp @@ -141,9 +141,6 @@ void TypePrinter::print(const Type *T, Qualifiers Quals, raw_ostream &OS, OS << "NULL TYPE"; return; } - - if (Policy.SuppressSpecifiers && T->isSpecifierType()) - return; SaveAndRestore<bool> PHVal(HasEmptyPlaceHolder, PlaceHolder.empty()); diff --git a/test/SemaCXX/ast-print.cpp b/test/SemaCXX/ast-print.cpp index 46b99e0d61..15fdabfe32 100644 --- a/test/SemaCXX/ast-print.cpp +++ b/test/SemaCXX/ast-print.cpp @@ -41,3 +41,8 @@ struct X { void *operator new (typeof(sizeof(1)), int = 2); }; void f2() { new X; } + +// CHECK: for (int i = 2097, j = 42; false;) +void forInit() { + for (int i = 2097, j = 42; false;) {} +} |