cryptol/tests/issues/issue68.cry
Robert Dockins 5d1e1948d8 Add test case to demonstrate tracing, as discussed in issue 68.
The new evaluator allows us to have more direct control over
evaluation order, and makes it straightforward to implement tracing
primitives.  There are two new primitives 'trace' and 'traceVal' in the
Cryptol prelude that produce tracing output when evaluated.
Fixes #68
2016-07-13 15:09:56 -07:00

8 lines
205 B
Plaintext

f : [8] -> [8]
f x = 20 + x
// Note! This test case may be a bit fragile, as it
// tests the output of tracing, which depends on evaluation
// order.
traceTest = [ trace "Hi!" i (f i) | i <- [0 .. 10 ] ]