More compat stuff

(currently only used by a not-yet committed plugin, though)

Change-Id: Id62ea41031ad8ba4495ef46877ad7a10bc58fb05
This commit is contained in:
Stephan Bergmann
2014-03-14 11:59:07 +01:00
parent 0085bd2866
commit f6ff4c955a

View File

@@ -51,6 +51,14 @@ inline clang::QualType getReturnType(clang::FunctionDecl const & decl) {
#endif
}
inline clang::QualType getReturnType(clang::FunctionProtoType const & type) {
#if (__clang_major__ == 3 && __clang_minor__ >= 5) || __clang_major__ > 3
return type.getReturnType();
#else
return type.getResultType();
#endif
}
inline unsigned getNumParams(clang::FunctionProtoType const & type) {
#if (__clang_major__ == 3 && __clang_minor__ >= 5) || __clang_major__ > 3
return type.getNumParams();