Changeset 15230 for src/Pugs/Lexer.hs
- Timestamp:
- 02/09/07 05:06:31 (22 months ago)
- Files:
-
- 1 modified
-
src/Pugs/Lexer.hs (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
src/Pugs/Lexer.hs
r14439 r15230 207 207 symbol s = try $ do 208 208 rv <- string s 209 let lastCh = last s 210 ahead = if isWordAny lastCh then aheadWord else aheadSym 211 lookAhead (satisfy (ahead lastCh)) <|> (eof >> return ' ') 212 whiteSpace 209 let lastCh = last s 210 ahead f = lookAhead (satisfy (f lastCh)) <|> (eof >> return ' ') 211 if isWordAny lastCh 212 then ahead aheadWord >> whiteSpace >> notFollowedBy (try (char '=' >> char '>')) 213 else ahead aheadSym >> whiteSpace 213 214 return rv 214 215 where
