--- gforth/Attic/gforth.ds 1995/01/12 18:37:51 1.5 +++ gforth/Attic/gforth.ds 1995/02/22 18:40:15 1.11 @@ -428,9 +428,9 @@ unwary (e.g., floating point addition is for the wary. You should not use them unless you know what you are doing or you don't care that the results you get are totally bogus. If you want to learn about the problems of floating point numbers (and how to -avoid them), you might start with @cite{Goldberg, What every computer -scientist should know about floating-point numbers, Computing Surveys -?}. +avoid them), you might start with @cite{David Goldberg, What Every +Computer Scientist Should Know About Floating-Point Arithmetic, ACM +Computing Surveys 23(1):5@minus{}48, March 1991}. doc-f+ doc-f- @@ -449,6 +449,7 @@ doc-fexpm1 doc-fln doc-flnp1 doc-flog +doc-falog doc-fsin doc-fcos doc-fsincos @@ -606,6 +607,9 @@ The standard guarantees that addresses r are cell-aligned; in addition, gforth guarantees that these addresses are aligned for all purposes. +Note that the standard defines a word @code{char}, which has nothing to +do with address arithmetic. + doc-chars doc-char+ doc-cells @@ -624,6 +628,10 @@ doc-dfloats doc-dfloat+ doc-dfalign doc-dfaligned +doc-maxalign +doc-maxaligned +doc-cfalign +doc-cfaligned doc-address-unit-bits @node Memory block access, , Address arithmetic, Memory access @@ -800,11 +808,11 @@ Therefore we recommend avoiding using @c @var{n}. One alternative is @code{@var{n} S+LOOP}, where the negative case behaves symmetrical to the positive case: -@code{-2 0 ?DO i . -1 +LOOP} prints @code{0 -1} +@code{-2 0 ?DO i . -1 S+LOOP} prints @code{0 -1} -@code{-1 0 ?DO i . -1 +LOOP} prints @code{0} +@code{-1 0 ?DO i . -1 S+LOOP} prints @code{0} -@code{ 0 0 ?DO i . -1 +LOOP} prints nothing +@code{ 0 0 ?DO i . -1 S+LOOP} prints nothing The loop is terminated when the border between @var{limit@minus{}sgn(n)} and @var{limit} is crossed. However, @code{S+LOOP} is not part of the ANS @@ -877,14 +885,14 @@ doc-next doc-leave doc-?leave doc-unloop -doc-undo +doc-done The standard does not allow using @code{cs-pick} and @code{cs-roll} on @i{do-sys}. Our system allows it, but it's your job to ensure that for every @code{?DO} etc. there is exactly one @code{UNLOOP} on any path through the definition (@code{LOOP} etc. compile an @code{UNLOOP} on the fall-through path). Also, you have to ensure that all @code{LEAVE}s are -resolved (by using one of the loop-ending words or @code{UNDO}). +resolved (by using one of the loop-ending words or @code{DONE}). Another group of control structure words are @@ -1037,7 +1045,8 @@ locals are initialized with values from Currently there is no way to define locals with user-defined data structures, but we are working on it. -GNU Forth allows defining locals everywhere in a colon definition. This poses the following questions: +GNU Forth allows defining locals everywhere in a colon definition. This +poses the following questions: @menu * Where are locals visible by name?:: @@ -1623,10 +1632,11 @@ GForth comes with @file{gforth.el}, an i @file{forth.el} by Goran Rydqvist (icluded in the TILE package). The improvements are a better (but still not perfect) handling of indentation. I have also added comment paragraph filling (@kbd{M-q}), -commenting (@kbd{C-x \}) and uncommenting (@kbd{C-x |}) regions and -removing debugging tracers (@kbd{C-x ~}). I left the stuff I do not use -alone, even though some of it only makes sense for TILE. To get a -description of these features, enter Forth mode and type @kbd{C-h m}. +commenting (@kbd{C-x \}) and uncommenting (@kbd{C-u C-x \}) regions and +removing debugging tracers (@kbd{C-x ~}, @pxref{Debugging}). I left the +stuff I do not use alone, even though some of it only makes sense for +TILE. To get a description of these features, enter Forth mode and type +@kbd{C-h m}. In addition, GForth supports Emacs quite well: The source code locations given in error messages, debugging output (from @code{~~}) and failed