<|

Richard A. O'Keefe ok at cs.otago.ac.nz
Wed Feb 5 01:02:55 UTC 2003


Bill Spight <bspight at pacbell.net> wrote:
	The token type of | is #verticalBar, which does not begin with x, and it
	does not combine with other symbols to form a token. I am sure that
	there are good reasons for this. You would like |[, |(, )|, ]|, and ||
	(and maybe others) to remain unambiguous. 
	
	I could fiddle with it to have it recognize |> and <| as tokens (best to
	do without ||, I think), but I do not really know what is best.
	
Following the ANSI standard might be a good idea.  It rules that | is just
like +; you may have |, ||, |+, |>, and a whole bunch of things, but
|[ |( )| ]| are no more problematic than +[ +( )+ or ]+.

|| _is_ a single token according to ANSI rules, so when you would have
accepted "| |" you just have to tweak the parser to accept "||" as well.



More information about the Squeak-dev mailing list