Add Type::getAsFunctionNoProto

llvm-svn: 65031
This commit is contained in:
Daniel Dunbar 2009-02-19 07:11:26 +00:00
parent 124bb197a7
commit 5c275a94fb
2 changed files with 6 additions and 0 deletions

View File

@ -63,6 +63,7 @@ namespace clang {
class TypedefType;
class TemplateTypeParmType;
class FunctionType;
class FunctionTypeNoProto;
class FunctionTypeProto;
class ExtVectorType;
class BuiltinType;
@ -396,6 +397,7 @@ public:
// the best type we can.
const BuiltinType *getAsBuiltinType() const;
const FunctionType *getAsFunctionType() const;
const FunctionTypeNoProto *getAsFunctionTypeNoProto() const;
const FunctionTypeProto *getAsFunctionTypeProto() const;
const PointerLikeType *getAsPointerLikeType() const; // Pointer or Reference.
const PointerType *getAsPointerType() const;

View File

@ -216,6 +216,10 @@ const FunctionType *Type::getAsFunctionType() const {
return getDesugaredType()->getAsFunctionType();
}
const FunctionTypeNoProto *Type::getAsFunctionTypeNoProto() const {
return dyn_cast_or_null<FunctionTypeNoProto>(getAsFunctionType());
}
const FunctionTypeProto *Type::getAsFunctionTypeProto() const {
return dyn_cast_or_null<FunctionTypeProto>(getAsFunctionType());
}