,---------------. | Contributions | `---------------ยด ,------------------------------------------ | 2021-08-18 13:39:23 MatteoVitturi wrote: | testcase - More general Testcase | see: https://forth-standard.org/standard/core/DEPTH#contribution-207 `------------------------------------------ Hello all, I was testing with [Annex F Test Suite](https://forth-standard.org/standard/testsuite) and got some unexpected error messages on the [DEPTH](https://forth-standard.org/standard/core/DEPTH) testcases. ``` T{ 0 1 DEPTH -> 0 1 2 }T T{ 0 DEPTH -> 0 1 }T T{ DEPTH -> 0 }T ``` After some investigation, I realized that this is due to how the [Test Harness](https://forth-standard.org/standard/testsuite) is built, since current [DEPTH](https://forth-standard.org/standard/core/DEPTH) testcases relies on an empty-stack, but that may not be always true. To get around this ambiguity, I used the very same Test Suite's ```START-DEPTH``` variable to adjust the value [DEPTH](https://forth-standard.org/standard/core/DEPTH) returns. ``` T{ 0 1 DEPTH START-DEPTH @ - -> 0 1 2 }T T{ 0 DEPTH START-DEPTH @ - -> 0 1 }T T{ DEPTH START-DEPTH @ - -> 0 }T \ or / and T{ 0 1 DEPTH -> 0 1 2 START-DEPTH @ + }T T{ 0 DEPTH -> 0 1 START-DEPTH @ + }T T{ DEPTH -> 0 START-DEPTH @ + }T ``` I think the power of the test isn't decreased by this amendment. _Matteo