void setBody(Stmt *B) { Body = B; }
+ /// Whether this function is virtual, either by explicit marking, or by
+ /// overriding a virtual function. Only valid on C++ member functions.
bool isVirtual() { return IsVirtual; }
void setVirtual() { IsVirtual = true; }
+ /// Whether this virtual function is pure, i.e. makes the containing class
+ /// abstract.
bool isPure() { return IsPure; }
void setPure() { IsPure = true; }
} else {
// not static member. perhaps virtual function?
if (CXXMethodDecl *MD = dyn_cast<CXXMethodDecl>(Member)) {
+ // With declarators parsed the way they are, the parser cannot
+ // distinguish between a normal initializer and a pure-specifier.
+ // Thus this grotesque test.
IntegerLiteral *IL;
if ((IL = dyn_cast<IntegerLiteral>(Init)) && IL->getValue() == 0 &&
Context.getCanonicalType(IL->getType()) == Context.IntTy) {