[GHC] #4430: Better support for resolving infix expressions in template haskell

GHC cvs-ghc at haskell.org
Tue Nov 9 08:04:50 EST 2010


#4430: Better support for resolving infix expressions in template haskell
---------------------------------+------------------------------------------
    Reporter:  reinerp           |        Owner:  reinerp     
        Type:  feature request   |       Status:  new         
    Priority:  normal            |    Milestone:              
   Component:  Template Haskell  |      Version:  6.12.3      
    Keywords:                    |     Testcase:              
   Blockedby:                    |   Difficulty:              
          Os:  Unknown/Multiple  |     Blocking:              
Architecture:  Unknown/Multiple  |      Failure:  None/Unknown
---------------------------------+------------------------------------------

Comment(by simonpj):

 It all seems rather complicated to me.  What's wrong with
 {{{
 data Exp = ...
   | UnresolvedInfixE
          Exp       -- Left operand
          Exp       -- Operator
          Exp       -- Right operand
 }}}
 with the understanding that any tree of adjacent `UnresolvedInfixE`
 constructors is re-associated into correctly-associated uses of `InfixE`?
 The data type is simpler.  The specification is simpler. The
 implementation is simpler.

 Simon

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


More information about the Glasgow-haskell-bugs mailing list