Edward Withers
Oct 22 2019: Learning Forth
https://www.forth.com/starting-forth/
then I googled a bunch - different implementations.
found this one https://www.gnu.org/software/gforth/
which took me to the 0.73 gforth implementation
then I had to read the docs carefully for the installation instructions
./configure
make
make install
loads of warnings, one permissions based fuck up error thing, never
also You need to configure with a gforth in $PATH to build this part
googled
came here https://github.com/forthy42/gforth
./configure CC='gcc-4.2 -arch x8664' --build=x8664-apple-darwin9.4.0
./configure CC='gcc -arch x8664' --build=x8664-apple-darwin9.4.0
some exploration needed.
FUCK IT. brew install forth. it's fucking magic.
tutorial - then fizzbuzz.
http://home.claranet.nl/users/mhx/
i love this shit
http://home.claranet.nl/users/mhx/sf1/sf1.html
https://www.complang.tuwien.ac.at/forth/gforth/Docs-html/Tutorial.html#Tutorial
Now press the key labeled:
RETURNFor People At Terminals: RETURN may have a different name on your terminal. Other possible names are NEW LINE and ENTER.
The computer will respond by saying
ok
edwardwithers@eds-work-mac ~ % gforth
Gforth 0.7.3, Copyright (C) 1995-2008 Free Software Foundation, Inc.
Gforth comes with ABSOLUTELY NO WARRANTY; for details type license'
Type
bye' to exit
hello
:1: Undefined word
hello<<< Backtrace: $10220AA20 throw $102220CC0 no.extensions $10220ACE0 interpreter-notfound1 ok ok ok ok ok ok ok ok ok ok ok ok ok ok ok ok 15 spaces ok 42 emit * ok 23 emit ok 55 emit 7 ok 56 emit 8 ok 22 emit ok 50 emit 2 ok 48 emit 0 ok 47 emit / ok 47 emit / ok ok ok ok ok ok ok ok ok ok ok ok ok ok 15 spaces ok
at this point nikesh comes over and asks what i was doing
200000 spaces ok ok 15 spaces 42 emit 42 emit ** ok : star 42 emit compiled star :46: Undefined word
star<<< Backtrace: $10220AA20 throw $102220C48 no.extensions $10220E358 compiler-notfound1 : star 42 emit; :47: Undefined word : star 42 >>>emit;<<< Backtrace: $10220AA20 throw $102220C48 no.extensions $10220E358 compiler-notfound1 : star 42 emit ; ok star * ok star * ok star * ok : two-stars 42 emit 42 emit 42 emit compiled : two-stars 42 emit 42 emit 42 emit ; :53: Undefined word : >>>two-stars<<< 42 emit 42 emit 42 emit ; Backtrace: $10220AA20 throw $102220C48 no.extensions $10220E358 compiler-notfound1 : two-stars 42 emit 42 emit 42 emit ; ok star * ok
two-stars *** ok
-----