diff options
-rw-r--r-- | mu.arc | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/mu.arc b/mu.arc index c748722f..7029ede8 100644 --- a/mu.arc +++ b/mu.arc @@ -36,29 +36,6 @@ (each f (as cons initialization-fns*) (f))) -; kludge to prevent reloading functions in .mu files for every test -(def reset2 () - (= memory* (table)) - (= Memory-allocated-until 1000) - (awhen curr-trace-file* - (tofile (+ trace-dir* it) - (each (label trace) (as cons traces*) - (pr label ": " trace)))) - (= curr-trace-file* nil) - (= traces* (queue)) - (wipe dump-trace*) - (wipe function*!main) - (wipe location*!main) - (= running-routines* (queue)) - (= sleeping-routines* (table)) - (wipe completed-routines*) - (wipe routine*) - (= abort-routine* (parameter nil)) - (= curr-cycle* 0) - (= scheduling-interval* 500) - (= scheduler-switch-table* nil) - ) - (mac on-init body `(enq (fn () ,@body) initialization-fns*)) @@ -1754,6 +1731,29 @@ ;? (set dump-trace*) ;? 1 (run-more ',name))) +; kludge to prevent reloading functions in .mu files for every test +(def reset2 () + (= memory* (table)) + (= Memory-allocated-until 1000) + (awhen curr-trace-file* + (tofile (+ trace-dir* it) + (each (label trace) (as cons traces*) + (pr label ": " trace)))) + (= curr-trace-file* nil) + (= traces* (queue)) + (wipe dump-trace*) + (wipe function*!main) + (wipe location*!main) + (= running-routines* (queue)) + (= sleeping-routines* (table)) + (wipe completed-routines*) + (wipe routine*) + (= abort-routine* (parameter nil)) + (= curr-cycle* 0) + (= scheduling-interval* 500) + (= scheduler-switch-table* nil) + ) + (def routine-that-ran (f) (find [some [is f _!fn-name] stack._] completed-routines*)) |