Diff for /gforth/prims2x.fs between versions 1.85 and 1.89

version 1.85, 2001/02/27 10:30:02 version 1.89, 2001/03/04 13:39:34
Line 60  warnings off Line 60  warnings off
                         \ different directory with the wordlibraries)                          \ different directory with the wordlibraries)
 include ./search.fs                       include ./search.fs                     
 include ./extend.fs  include ./extend.fs
 [THEN]  
 include ./stuff.fs  include ./stuff.fs
   [THEN]
   
 [IFUNDEF] environment?  [IFUNDEF] environment?
 include ./environ.fs  include ./environ.fs
Line 585  s" IP" save-mem w s" error don't use # o Line 585  s" IP" save-mem w s" error don't use # o
 : stores ( -- )  : stores ( -- )
     prim prim-effect-out prim prim-effect-out-end @ ['] store map-items ;      prim prim-effect-out prim prim-effect-out-end @ ['] store map-items ;
   
   : output-super-end ( -- )
       prim prim-c-code 2@ s" SET_IP" search if
           ." SUPER_END;" cr
       endif
       2drop ;
   
 : output-c-tail ( -- )  : output-c-tail ( -- )
     \ the final part of the generated C code      \ the final part of the generated C code
       output-super-end
     ." NEXT_P1;" cr      ." NEXT_P1;" cr
     stores      stores
     fill-tos      fill-tos
Line 661  s" IP" save-mem w s" error don't use # o Line 668  s" IP" save-mem w s" error don't use # o
     ."   ip += " inst-stream stack-in @ 1+ 0 .r ." ;" cr      ."   ip += " inst-stream stack-in @ 1+ 0 .r ." ;" cr
     ." } else " ;      ." } else " ;
   
   : output-profile ( -- )
       \ generate code for postprocessing the VM block profile stuff
       ." if (VM_IS_INST(*ip, " function-number @ 0 .r ." )) {" cr
       ."   add_inst(b, " quote  prim prim-name 2@ type quote ." );" cr
       ."   ip += " inst-stream stack-in @ 1+ 0 .r ." ;" cr
       prim prim-c-code 2@  s" SET_IP"    search nip nip
       prim prim-c-code 2@  s" SUPER_END" search nip nip or if
           ."   return;" cr
       endif
       ." } else " cr ;
   
 : gen-arg-parm { item -- }  : gen-arg-parm { item -- }
     item item-stack @ inst-stream = if      item item-stack @ inst-stream = if
         ." , " item item-type @ type-c-name 2@ type space          ." , " item item-type @ type-c-name 2@ type space
Line 901  s" IP" save-mem w s" error don't use # o Line 919  s" IP" save-mem w s" error don't use # o
 : process-combined ( -- )  : process-combined ( -- )
     combined combined-prims num-combined @ cells      combined combined-prims num-combined @ cells
     combinations ['] constant insert-wordlist      combinations ['] constant insert-wordlist
       combined-prims num-combined @ 1- th ( last-part )
       @ prim-c-code 2@ prim prim-c-code 2! \ used by output-super-end
     prim compute-effects      prim compute-effects
     prim init-effects      prim init-effects
     output-combined perform ;      output-combined perform ;
Line 1147  Variable c-flag Line 1167  Variable c-flag
 )) <- simple-primitive ( -- )  )) <- simple-primitive ( -- )
   
 (( {{ init-combined }}  (( {{ init-combined }}
    ` = (( white ++ {{ start }} forth-ident {{ end add-prim }} )) ++     ` = white ** (( {{ start }} forth-ident {{ end add-prim }} white ** )) ++
    nleof {{ process-combined }}     nleof {{ process-combined }}
 )) <- combined-primitive  )) <- combined-primitive
   

Removed from v.1.85  
changed lines
  Added in v.1.89


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>