diff options
Diffstat (limited to 'clang/lib/AST/DeclPrinter.cpp')
| -rw-r--r-- | clang/lib/AST/DeclPrinter.cpp | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/clang/lib/AST/DeclPrinter.cpp b/clang/lib/AST/DeclPrinter.cpp index d3ebc8f508e..fae1e724a17 100644 --- a/clang/lib/AST/DeclPrinter.cpp +++ b/clang/lib/AST/DeclPrinter.cpp @@ -727,19 +727,12 @@ void DeclPrinter::VisitObjCImplementationDecl(ObjCImplementationDecl *OID) { void DeclPrinter::VisitObjCInterfaceDecl(ObjCInterfaceDecl *OID) { std::string I = OID->getNameAsString(); - - if (OID->isForwardDecl()) { - // These shouldn't be directly visited, but in case they are, write them - // as an @class declaration. - Out << "@class " << I; - return; - } - ObjCInterfaceDecl *SID = OID->getSuperClass(); - Out << "@interface " << I; if (SID) - Out << " : " << SID; + Out << "@interface " << I << " : " << SID; + else + Out << "@interface " << I; // Protocols? const ObjCList<ObjCProtocolDecl> &Protocols = OID->getReferencedProtocols(); |

