[GHC] #9742: The default definitions of foldl1 and foldr1 are too strict

GHC ghc-devs at haskell.org
Tue Nov 4 09:07:01 UTC 2014


#9742: The default definitions of foldl1 and foldr1 are too strict
-------------------------------------+-------------------------------------
              Reporter:  dfeuer      |            Owner:  ekmett
                  Type:  bug         |           Status:  patch
              Priority:  normal      |        Milestone:  7.10.1
             Component:  Core        |          Version:  7.9
  Libraries                          |         Keywords:
            Resolution:              |     Architecture:  Unknown/Multiple
      Operating System:              |       Difficulty:  Easy (less than 1
  Unknown/Multiple                   |  hour)
       Type of failure:  Runtime     |       Blocked By:
  crash                              |  Related Tickets:
             Test Case:              |
              Blocking:              |
Differential Revisions:  Phab:D423   |
-------------------------------------+-------------------------------------

Comment (by Herbert Valerio Riedel <hvr@…>):

 In [changeset:"6dd218e5f82f19523f9e7aa5371f5bd7beb19663/ghc"]:
 {{{
 #!CommitTicketReference repository="ghc"
 revision="6dd218e5f82f19523f9e7aa5371f5bd7beb19663"
 Make Foldable's foldr1 and foldl1 defaults lazier

 Fixes #9742. Previously, `foldr1` as applied to a list-like
 structure would be strict in the spine, and `foldl1` would
 be strict in the spine of a snoc-list.

 See also

  https://www.haskell.org/pipermail/libraries/2014-October/024035.html

 Differential Revision: https://phabricator.haskell.org/D423
 }}}

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


More information about the ghc-tickets mailing list