CoreForth-0

cortex/common/threading-dtc.ft.md


: ,bl           4 - here -
                1 #23 lshift 1- and
                dup #12 rshift %0000011111111111 and $F000 or h,
                     #1 rshift %0000011111111111 and $F800 or h, ;

: ,call         1+ , ;
: ,enter        ['] docol ,bl ;
: ,next         $cf20 h, $4728 h, ;
: ,exit         ['] exit ,call ;

code dodoes     $b480 $4677 $3f01 $683f $CF20 $4728 end-code

: ,dodoes       ['] dodoes ,bl ;
: ,dodata       $3e04 h, $6030 h, $4678 h, $3008 h, $cf20 h, $4728 h, 4 allot ;
: ,docon        $3e04 h, $6030 h, $4801 h, $cf20 h, $4728 h, 2 allot ;
: (does>)       here latest @ link> #8 + org ,dodoes r> , org ;
: does>         postpone (does>) ; immediate