lundi 8 mai 2017

Debugging Forth using a Test Harness

I would like to use a simple test harness to test my code during debugging using the same methodology as the Forth test harness developed by John Hayes.

The concept is to define a function, say my+ and then to define simple code snippets that will test the code when Tdebug is on.

Tdebug if T{ 1 1 my+ -> 2 }T else

Is it really as simple as including tester.f and changing {> to T{ and } to }T?

I plan to omit tester.f in the production release if size is an issue.

Aucun commentaire:

Enregistrer un commentaire