Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Fredrik Wieczerkowski
curry-libs
Commits
8b1464f0
Commit
8b1464f0
authored
Jan 07, 2018
by
Michael Hanus
Browse files
deriving Read added to Time datatypes
parent
3a92b667
Changes
1
Hide whitespace changes
Inline
Side-by-side
Time.curry
View file @
8b1464f0
...
...
@@ -2,7 +2,7 @@
--- Library for handling date and time information.
---
--- @author Michael Hanus
--- @version
April
20
07
--- @version
January
20
18
--- @category general
------------------------------------------------------------------------------
...
...
@@ -17,14 +17,14 @@ module Time(ClockTime,
--- ClockTime represents a clock time in some internal representation.
data ClockTime = CTime Int
deriving (Eq, Ord, Show)
deriving (Eq, Ord, Show
, Read
)
--- A calendar time is presented in the following form:
--- (CalendarTime year month day hour minute second timezone)
--- where timezone is an integer representing the timezone as a difference
--- to UTC time in seconds.
data CalendarTime = CalendarTime Int Int Int Int Int Int Int
deriving (Eq, Ord, Show)
deriving (Eq, Ord, Show
, Read
)
--- The year of a calendar time.
ctYear :: CalendarTime -> Int
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment