Implement -Wunmatched-directive

This commit is contained in:
Rangi42
2024-11-28 14:06:52 -05:00
committed by Eldred Habert
parent 9216485bca
commit a27f704c25
15 changed files with 51 additions and 0 deletions

View File

@@ -184,3 +184,9 @@ void opt_Pop() {
warningsAreErrors = entry.warningsAreErrors;
warningStates = entry.warningStates;
}
void opt_CheckStack() {
if (!stack.empty()) {
warning(WARNING_UNMATCHED_DIRECTIVE, "`PUSHO` without corresponding `POPO`\n");
}
}