/// entered this scope.
unsigned getNumErrorsAtStart() const { return NumErrorsAtStart; }
+ void setNumErrorsAtStart(unsigned NumErrors) {
+ NumErrorsAtStart = NumErrors;
+ }
+
/// isClassScope - Return true if this scope is a class/struct/union scope.
bool isClassScope() const {
return (getFlags() & Scope::ClassScope);
} else {
CurScope = new Scope(CurScope, ScopeFlags);
}
- CurScope->NumErrorsAtStart = Diags.getNumErrors();
+ CurScope->setNumErrorsAtStart(Diags.getNumErrors());
}
/// ExitScope - Pop a scope off the scope stack.