Index: lib/AST/StmtPrinter.cpp =================================================================== --- lib/AST/StmtPrinter.cpp +++ lib/AST/StmtPrinter.cpp @@ -1480,6 +1480,7 @@ OS << '('; PrintingPolicy SubPolicy(Policy); SubPolicy.SuppressSpecifiers = false; + SubPolicy.SuppressTag = false; Node->getTypeAsWritten().print(OS, SubPolicy); OS << ')'; PrintExpr(Node->getSubExpr()); Index: test/Sema/ast-print.c =================================================================== --- test/Sema/ast-print.c +++ test/Sema/ast-print.c @@ -57,6 +57,12 @@ void cast() { // CHECK: int *x = ((void *)0), *y = ((void *)0); int *x = ((void *)0), *y = ((void *)0); + + enum Foo { FOO = 0 }; + struct { + enum Foo foo; +// CHECK: } anon = {(enum Foo)0}; + } anon = {(enum Foo)0}; } void stmtExpr() {