[GHC] #16036: expDouble## 0.0## doesn't get complied into 1.0##

GHC ghc-devs at haskell.org
Wed Dec 12 13:36:27 UTC 2018


#16036: expDouble## 0.0## doesn't get complied into 1.0##
-------------------------------------+-------------------------------------
        Reporter:  Fuuzetsu          |                Owner:  (none)
            Type:  feature request   |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  8.6.3
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by simonpj):

 > Maybe expDouble## <literal>## should always evaluate at compile time to
 not block further constant folding?

 Yes that'd be easy to do via a rewrite rule.  (See
 `prelude/PrelRules.hs`.)   But whenever floating-point is in the picture I
 always worry about maintaining floating-point semantics.  So someone fp-
 savvy should execute on this.

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


More information about the ghc-tickets mailing list