Add test for additional non-constant debugging message.

This commit is contained in:
Dianne Skoll
2025-05-21 12:24:44 -04:00
parent de2d15009f
commit 43d0066780
2 changed files with 18 additions and 8 deletions

View File

@@ -16402,28 +16402,34 @@ wkdaynum("cabbage") => Type mismatch
# Test non-constant debugging
DEBUG +n
DEBUG -x
IF today() > '1990-01-01'
../tests/test.rem(1515): Non-constant builtin function `today' makes expression non-constant
SET a 1
../tests/test.rem(1516): Variable assignment considered non-constant because of context
ELSE
SET a 2
ENDIF
SET a 1
SET a version()
SET a today()
../tests/test.rem(1518): Non-constant builtin function `today' makes expression non-constant
../tests/test.rem(1522): Non-constant builtin function `today' makes expression non-constant
set b a
../tests/test.rem(1519): Global variable `a' makes expression non-constant
../tests/test.rem(1523): Global variable `a' makes expression non-constant
FUNSET f g
fset f(x) today() + x
fset g(x) f(x) + 13
set a g(3)
../tests/test.rem(1523): Non-constant builtin function `today' makes expression non-constant
../tests/test.rem(1527): Non-constant builtin function `today' makes expression non-constant
FSET o(x) iif(x != 0, 0, 0)
REM OMITFUNC o MSG foo
../tests/test.rem(1526): OMITFUNC counts as a non-constant expression
../tests/test.rem(1530): OMITFUNC counts as a non-constant expression
foo
REM SCANFROM -7 MSG foo
../tests/test.rem(1527): Relative SCANFROM counts as a non-constant expression
../tests/test.rem(1531): Relative SCANFROM counts as a non-constant expression
REM MSG [g(3)]
../tests/test.rem(1529): Non-constant builtin function `today' makes expression non-constant
../tests/test.rem(1533): Non-constant builtin function `today' makes expression non-constant
1991-03-04
DEBUG -n

View File

@@ -1512,7 +1512,11 @@ set a wkdaynum("cabbage")
# Test non-constant debugging
DEBUG +n
DEBUG -x
IF today() > '1990-01-01'
SET a 1
ELSE
SET a 2
ENDIF
SET a 1
SET a version()
SET a today()