Ticket #1267 (closed bug: duplicate)

Opened 6 years ago

Last modified 4 years ago

Strictness of Integer's enumFrom

Reported by: sjanssen@… Owned by:
Priority: low Milestone:
Component: libraries/base Version: 6.6
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: Difficulty: Easy (less than 1 hour)
Test Case: Blocked By:
Blocking: Related Tickets:

Description

According to the Haskell report "For all four of these Prelude numeric types, all of the enumFrom family of functions are strict in all their arguments." (referring to Int, Integer, Float, Double). However, Integer's enumFrom and enumFromThen are lazy in their parameters.

To reproduce:

main = print $ null [undefined :: Integer ..]

This yields "False", where it should yield _|_.

Change History

Changed 6 years ago by guest

  • status changed from new to closed
  • resolution set to duplicate

Changed 5 years ago by simonmar

  • architecture changed from Unknown to Unknown/Multiple

Changed 5 years ago by simonmar

  • os changed from Unknown to Unknown/Multiple

Changed 4 years ago by simonmar

  • difficulty changed from Easy (1 hr) to Easy (less than 1 hour)
Note: See TracTickets for help on using tickets.