67aeff8934
I wrote a comment about how some code was not covered by tests, and then promptly forgot what it was for. This is why we need tests. Now the hack is gone.
48 lines
852 B
Plaintext
48 lines
852 B
Plaintext
# Some helpers needed only because Mu doesn't support globals at the moment.
|
|
|
|
== code
|
|
|
|
count-test-failure:
|
|
# . prologue
|
|
55/push-ebp
|
|
89/<- %ebp 4/r32/esp
|
|
#
|
|
ff 0/subop/increment *Num-test-failures
|
|
$count-test-failure:end:
|
|
# . epilogue
|
|
89/<- %esp 5/r32/ebp
|
|
5d/pop-to-ebp
|
|
c3/return
|
|
|
|
num-test-failures: # -> _/eax: int
|
|
# . prologue
|
|
55/push-ebp
|
|
89/<- %ebp 4/r32/esp
|
|
#
|
|
8b/-> *Num-test-failures 0/r32/eax
|
|
$num-test-failures:end:
|
|
# . epilogue
|
|
89/<- %esp 5/r32/ebp
|
|
5d/pop-to-ebp
|
|
c3/return
|
|
|
|
running-tests?: # -> _/eax: int
|
|
# . prologue
|
|
55/push-ebp
|
|
89/<- %ebp 4/r32/esp
|
|
#
|
|
8b/-> *Running-tests? 0/r32/eax
|
|
$running-tests?:end:
|
|
# . epilogue
|
|
89/<- %esp 5/r32/ebp
|
|
5d/pop-to-ebp
|
|
c3/return
|
|
|
|
== data
|
|
|
|
Num-test-failures:
|
|
0/imm32
|
|
|
|
Running-tests?:
|
|
1/imm32/true
|