Last commit - don't allow error overrides if not lint

This commit is contained in:
Wilson Snyder 2011-11-30 18:07:11 -05:00
parent fce158b8ad
commit 84ba253791

View File

@ -202,7 +202,10 @@ ostream& operator<<(ostream& os, FileLine* fileline) {
bool FileLine::warnOff(const string& msg, bool flag) {
V3ErrorCode code (msg.c_str());
if (code < V3ErrorCode::EC_MIN) {
if (code < V3ErrorCode::EC_FIRST_WARN) {
return false;
} else if (v3Global.opt.lintOnly() // Lint mode is allowed to suppress some errors
&& code < V3ErrorCode::EC_MIN) {
return false;
} else {
warnOff(code, flag);