From: Bernhard Urban Date: Fri, 4 Nov 2011 16:18:05 +0000 (+0100) Subject: fourth lecture X-Git-Url: http://wien.tomnetworks.com/gitweb/?p=sbs.git;a=commitdiff_plain;h=b4e5f474773c22c8e613198f1d4a9ae60cd0e378 fourth lecture --- diff --git a/4vo.fs b/4vo.fs new file mode 100644 index 0000000..dbde186 --- /dev/null +++ b/4vo.fs @@ -0,0 +1,37 @@ +\ 4. lecture + +: rr ( -- ) s" 4vo.fs" included ; +: :r rr ; \ ghci style + +\ :noname \ ano-fkt + +\ oop example: mini-examp.fs ( @ /pub/anton ...) oder bernd paysan webseite + +\ live hax +\ > hex +\ > create foo +\ > 5 , +\ > ' foo . +\ > ' foo >body . +\ > ' foo >body @ . 5 \ dazwischen steht das sogenannte `code field' + +\ gforth schmaes +\ > here hex. \ (diese ausgabe) +\ > : foo 5 + ; +\ > here hex. +\ > : bar foo ; +\ > here hex. +\ > (diese ausgabe) 80 dump +\ > ' foo hex. +\ > ' foo >body hex. +\ > simple-see foo \ zwischencode \ ";s" aka "semis" aka "exit". wird fuer ';' kompiliert +\ > simple-see bar +\ addr von + in `simple-see foo' nehmen und +\ > 16 dump +\ \ und dann addressen dort nochmal dereferenzieren... +\ > @ 80 discode + +\ \ besser: see-code + + +\ oder: > see +