Commit a06c34b5 authored by simonm's avatar simonm
Browse files

[project @ 1997-12-17 13:14:21 by simonm]

* remove explicit lexing of '::' which didn't take into account tokens
  that begin with '::'.
* remove duplicate ':' case from is_sym.
* add '::' as a builtin identifier, mapped to ITdcolon.
parent 6035c7ce
......@@ -289,9 +289,6 @@ lexIface cont buf =
_ -> cont ITobrack (stepOn buf)
']'# -> cont ITcbrack (stepOn buf)
','# -> cont ITcomma (stepOn buf)
':'# -> case lookAhead# buf 1# of
':'# -> cont ITdcolon (stepOnBy# buf 2#)
_ -> lex_id cont (incLexeme buf)
';'# -> cont ITsemi (stepOn buf)
'\"'# -> case untilEndOfString# (stepOn buf) of
buf' ->
......@@ -572,10 +569,10 @@ is_id_char (C# c#) =
--OLD: is_id_char c@(C# c#) = isAlphanum c || is_sym c#
is_sym c#=
is_sym c# =
case c# of {
':'# -> True; '_'# -> True; '\''# -> True; '!'# -> True;
'#'# -> True; '$'# -> True; ':'# -> True; '%'# -> True;
'#'# -> True; '$'# -> True; '%'# -> True;
'&'# -> True; '*'# -> True; '+'# -> True; '.'# -> True;
'/'# -> True; '<'# -> True; '='# -> True; '>'# -> True;
'?'# -> True; '\\'# -> True; '^'# -> True; '|'# -> True;
......@@ -830,6 +827,7 @@ haskellKeywordsFM = listToUFM $
,("!", ITbang)
,("=>", ITdarrow)
,("=", ITequal)
,("::", ITdcolon)
]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment