diff options
Diffstat (limited to 'clang/lib/AST/ASTContext.cpp')
| -rw-r--r-- | clang/lib/AST/ASTContext.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/clang/lib/AST/ASTContext.cpp b/clang/lib/AST/ASTContext.cpp index b9514f35a09..c5b451740a2 100644 --- a/clang/lib/AST/ASTContext.cpp +++ b/clang/lib/AST/ASTContext.cpp @@ -1859,6 +1859,16 @@ void ASTContext::getObjCEncodingForTypeImpl(QualType T, std::string& S, return; } else if (PointeeTy->isObjCInterfaceType()) { + if (dyn_cast<TypedefType>(PointeeTy.getTypePtr())) { + // Another historical/compatibility reason. + // We encode the underlying type which comes out as + // {...}; + S += '^'; + getObjCEncodingForTypeImpl(PointeeTy, S, + false, ExpandPointedToStructures, + NULL); + return; + } S += '@'; if (FD) { ObjCInterfaceDecl *OI = PointeeTy->getAsObjCInterfaceType()->getDecl(); |

