[GHC] #10583: Chaos in Lexeme.hs

GHC ghc-devs at haskell.org
Mon Jun 29 17:41:19 UTC 2015


#10583: Chaos in Lexeme.hs
-------------------------------------+-------------------------------------
        Reporter:  goldfire          |                   Owner:  goldfire
            Type:  bug               |                  Status:  new
        Priority:  normal            |               Milestone:
       Component:  Compiler          |                 Version:  7.10.1
      Resolution:                    |                Keywords:
Operating System:  Unknown/Multiple  |            Architecture:
 Type of failure:  None/Unknown      |  Unknown/Multiple
      Blocked By:                    |               Test Case:
 Related Tickets:                    |                Blocking:  10582
                                     |  Differential Revisions:
-------------------------------------+-------------------------------------

Comment (by goldfire):

 We use `isLexVarSym` to check if a symbol name is valid? That should be
 refactored, because quite clearly the other `isLexXXX` functions do not do
 validity checking.

 And I don't agree about the goofy conversion: I want to combine
 `isVarSymChar` and `okSymChar`, both of type `Char -> Bool`.

 As for `notFollowedBySymbol`: This needs to be spot on -- a mistake in
 either direction would lead to wrong behavior. One place it's used is to
 detect banana brackets for arrow notation; see #10582.

 In the end, I can figure out what these functions are used for by poking
 around, but I just don't quite know what their specification is -- as in,
 what (precisely) they should do.

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10583#comment:4>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list