File:  [gforth] / gforth / other.fs
Revision 1.1: download - view: text, annotated - select for diffs
Fri Feb 11 16:30:46 1994 UTC (30 years, 2 months ago) by anton
Branches: MAIN
CVS tags: HEAD
Initial revision

    1: \ OTHER.FS     Ansforth extentions for CROSS           9may93jaw
    2: 
    3: \ make ansforth compatible                              9may93jaw
    4: \ the cross compiler should run
    5: \ with any ansforth environment
    6: 
    7: : ?EXIT    s" IF EXIT THEN" evaluate ; immediate
    8: : bounds   over + swap ;
    9: : capitalize ( addr -- addr )
   10:   dup count chars bounds
   11:   ?DO  I c@ [char] a [char] { within
   12:        IF  I c@ bl - I c!  THEN  1 chars +LOOP ;
   13: : name bl word capitalize ;
   14: : on true swap ! ;
   15: : off false swap ! ;
   16: : place ( adr len adr )
   17:         2dup c! char+ swap move ;
   18: : +place ( adr len adr )
   19:         2dup c@ + over c!
   20:         dup c@ char+ + swap move ;
   21: : -rot  rot rot ;
   22: 
   23: include toolsext.fs
   24: 

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