home .. forth .. colorforth mail list archive ..

Re: [colorforth] an observation


I like your notations. '; then' is very common in colorForth and can
certainly be replaced by 'else' while maintaining the conventional 'then'.
Also I like '...' for spilling definitions into a following defintion.

I think I will try these with new code that I write for my colorForth
port. I don't see any reason for them not to work out fine.

Mark

On Tue, 19 Aug 2003, Samuel Falvo wrote:
>
> I often make use of constructs such as this:
>
>   condition IF optionalAction THEN requiredAction
>
> I was considering re-introducing ELSE into my interpretation of the language,
> like this:
>
>   condition IF action1 ELSE action2
>
> where ELSE is defined more or less like this:
>
>   COMPILER
>   : else   postpone exit postpone then ;
>
> So basically, THEN would permit conditional fall-through, while ELSE provides
> true alternation.  It also makes more sense from an English reading
> stand-point, I think.
>
> > Is this a good idea or a trivial variation? I think it would reduce errors
>
> I think it could potentially be a good idea, personally.  One could use an
> ellipsis ('...') to flag the compiler, "and then, I want you to do this..."
> Example:
>
> : 256* 4* ...
> : 64* 4* ...
> : 16* 4* ...
> : 4* 2* 2* ;
>
> --
> Samuel A. Falvo II
>
>
> __________________________________
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site design software
> http://sitebuilder.yahoo.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: colorforth-unsubscribe@xxxxxxxxxxxxxxxxxx
> For additional commands, e-mail: colorforth-help@xxxxxxxxxxxxxxxxxx
> Main web page - http://www.colorforth.com
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: colorforth-unsubscribe@xxxxxxxxxxxxxxxxxx
For additional commands, e-mail: colorforth-help@xxxxxxxxxxxxxxxxxx
Main web page - http://www.colorforth.com