diff options
| author | kitty <nepeta@canaglie.net> | 2026-02-26 19:13:24 +1100 |
|---|---|---|
| committer | kitty <nepeta@canaglie.net> | 2026-02-26 19:13:24 +1100 |
| commit | 59f9514eb8324926cc73e2ebc28f234afac1d4fd (patch) | |
| tree | 0f8cdf4fd0f689e6d090a40ff0c76effa7a50cf0 | |
| parent | 738d7ffb609ff26b6331a5da62cd1fe565fce71d (diff) | |
don't interpret "
also fixes the Leaving shit on the stack issue. i still dont know what
that's about but i just `drop` it and its fixed
| -rw-r--r-- | jefs.fs | 6 | ||||
| -rw-r--r-- | jefs.s | 3 |
2 files changed, 5 insertions, 4 deletions
@@ -1,6 +1,5 @@ \ i think something is going on with the stack. i dunno \ things TODO: -\ NEXT: ." while it works then leaves PARSE to pick up the end quote. \ EVALUATE \ CASE \ DO LOOP @@ -56,7 +55,7 @@ hex : ret, c3 c, ; decimal \ TODO interpret mode strings? \ : s" [ char " ] literal 1 >in +! ( skip spc ) [compile] litstring ; immediate -: s" 1 >in +! [ char " ] literal cparse branch >mark >r 2dup cmove, r> >resolve swap [compile] lit [compile] lit ; immediate +: s" 1 >in +! [ char " ] literal cparse branch >mark >r 2dup cmove, r> >resolve swap [compile] lit [compile] lit drop ; immediate : ." [compile] s" ' say compile, ; immediate \ lol this word breaks the highlighting, here have another " \ https://wiki.osdev.org/X86-64_Instruction_Encoding @@ -185,9 +184,10 @@ variable hld \ TODO fix/rewrite interpreter to respect #tib \ : (evaluate) ( c-addr u -- ) .s 0 >in ! ( u ) #tib ! ( c-addr ) tib ! interpret ; -: (evaluate) ( c-addr u -- ) .s 2drop ; +: (evaluate) ( c-addr u -- ) 2drop ; : evaluate ( c-addr u -- ) >r >r tib @ #tib @ >in @ r> r> (evaluate) >in ! #tib ! tib ! ; +.s TESTSTR evaluate .free bye @@ -296,7 +296,8 @@ defword "cparse", cparse, 0 jmp .wordloop .wordloop_end: - ; dec r11 + dec r11 + inc r13 sub r13, qword [tib] mov qword [to_in], r13 pop r13 |
