Opened 11 years ago

Closed 11 years ago

Last modified 9 years ago

#882 closed bug (fixed)

Overflow bug in System.Time

Reported by: simonpj Owned by:
Priority: normal Milestone:
Component: libraries/base Version: 6.4.2
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


Frederik Eaton reports: The Glorious Glasgow Haskell Compilation System, version

> now <- getClockTime
> addToClockTime (TimeDiff {tdYear = 0, tdMonth = 0, tdDay = 0, tdHour = 0, tdMin = 0, tdSec = 0, tdPicosec = 999999999999}) now
*** Exception: Time.toClockTime: picoseconds out of range

This is clearly a bug. Simon Marlow comments: System.Time is kind-of deprecated: the new time package is intended to supercede it, but I have been reluctant to really deprecate System.Time because it comes from Haskell98, and also because we don't have much experience with its replacement.

Change History (3)

comment:1 Changed 11 years ago by igloo

Resolution: fixed
Status: newclosed

I've applied the fix from the HEAD to the 6.4 STABLE CVS branch.

Thanks Ian

comment:2 Changed 9 years ago by simonmar

Architecture: UnknownUnknown/Multiple

comment:3 Changed 9 years ago by simonmar

Operating System: UnknownUnknown/Multiple
Note: See TracTickets for help on using tickets.