diff options
Diffstat (limited to 'apps/factorial3.subx')
-rw-r--r-- | apps/factorial3.subx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/factorial3.subx b/apps/factorial3.subx index 6cfd38c3..7a8cee8c 100644 --- a/apps/factorial3.subx +++ b/apps/factorial3.subx @@ -32,8 +32,8 @@ Entry: # run tests if necessary, compute `factorial(5)` if not 7e/jump-if-lesser-or-equal $run-main/disp8 # if (!kernel-string-equal?(argv[1], "test")) goto run-main (kernel-string-equal? *(ebp+8) "test") # => eax - # . if (eax == 0) goto run-main - 3d/compare-eax-and 0/imm32 + # . if (eax == false) goto run-main + 3d/compare-eax-and 0/imm32/false 74/jump-if-equal $run-main/disp8 # (run-tests) @@ -59,7 +59,7 @@ factorial: # n : int -> int/eax b8/copy-to-eax 1/imm32 81 7/subop/compare *(ebp+8) 1/imm32 7e/jump-if-<= $factorial:end/disp8 - # ebx = n-1 + # var ebx : int = n-1 8b/-> *(ebp+8) 3/r32/ebx 4b/decrement-ebx # |