Add test for UNMATCHED PUSH

This commit is contained in:
Dianne Skoll
2024-06-04 16:27:23 -04:00
parent 325814f5e1
commit a6a638e0e6
3 changed files with 19 additions and 1 deletions

View File

@@ -1215,7 +1215,7 @@ int DoBanner(ParsePtr p)
}
}
DBufFree(&Banner);
err = DBufPuts(&Banner, DBufValue(&buf));
DBufFree(&buf);
return err;

View File

@@ -551,6 +551,21 @@ EOF
../src/remind ../tests/expr.rem >> ../tests/test.out 2>&1
../src/remind - <<'EOF' >> ../tests/test.out 2>&1
PUSH
POP
PUSH
PUSH
POP
POP
PUSH
PUSH
POP
PUSH
POP
PUSH
POP
EOF
# Remove references to SysInclude, which is build-specific
grep -F -v '$SysInclude' < ../tests/test.out > ../tests/test.out.1 && mv -f ../tests/test.out.1 ../tests/test.out
cmp -s ../tests/test.out ../tests/test.cmp

View File

@@ -12346,3 +12346,6 @@ No reminders.
Expression nodes high-water: 499
Expression nodes leaked: 0
Parse level high-water: 2001
-stdin-(14): Unmatched PUSH-OMIT-CONTEXT at -(7)
-stdin-(14): Warning: PUSH-OMIT-CONTEXT without matching POP-OMIT-CONTEXT
No reminders.