duskos

dusk os fork
git clone git://git.alexwennerberg.com/duskos
Log | Files | Refs | README | LICENSE

commit db82d2ef7f3e6a4c1e04b1aedf7cb003a34e38f3
parent fdf8d105527623d18c9e6a6edc7601c4672464db
Author: Virgil Dupras <hsoft@hardcoded.net>
Date:   Wed,  1 Jun 2022 13:51:41 -0400

Add stype

Diffstat:
Mword_macros.asm | 12++++++++++++
Mwords/cfetch.asm | 3++-
Mwords/fetch.asm | 3++-
Mxcomp2.txt | 4+++-
4 files changed, 19 insertions(+), 3 deletions(-)

diff --git a/word_macros.asm b/word_macros.asm @@ -51,3 +51,15 @@ pop dword [ebp] %endmacro %define rsdrop pop eax + +%macro _begin_ 0 +%push begin +%$begin: +%endmacro + +%macro _next_ 0 +dec dword [esp] +jnz %$begin +%pop +pop eax +%endmacro diff --git a/words/cfetch.asm b/words/cfetch.asm @@ -1,5 +1,6 @@ defword 'c@', 2, word_cfetch, word_dec + mov esi, [ebp] mov eax, 0 - mov al, [ebp] + mov al, [esi] mov [ebp], eax ret diff --git a/words/fetch.asm b/words/fetch.asm @@ -1,5 +1,6 @@ defword '@', 1, word_fetch, word_cstore - mov eax, [ebp] + mov esi, [ebp] + mov eax, [esi] mov [ebp], eax ret diff --git a/xcomp2.txt b/xcomp2.txt @@ -16,5 +16,7 @@ syscell 'curword curword : c@+ dup 1+ swap c@ ; : c!+ tuck c! 1+ ; : allot here + to here ; + +: stype >r begin c@+ emit next drop ; create _ ," foo" -: boot _ >A Ac@+ emit Ac@+ emit Ac@+ emit bye ; +: boot _ 3 stype bye ;