haskell-ja > Archives > 2012/10/26

2012/10/26 06:46:32 UTCcutsea110
#
お、最新環境うまくいった。
2012/10/26 07:09:42 UTCcutsea110
#
import Data.Time.Calendar.WeekDate
#
fromWeekDate 2012 52 1 -- 52週目の月曜
#
2012-12-24
#
fromWeekDate 2012 52 7
#
2012-12-30
#
fromWeekDate 2012 53 1
#
2012-12-24
#
おーい…
2012/10/26 08:24:49 UTCmaoe
#
Invalid week and day values will be clipped to the correct range らしいので fromWeekDateValid :: Integer -> Int -> Int -> Maybe Day の方がいいかもしれません
2012/10/26 10:24:25 UTCnobsun
#
修正ユリウス日でまじめにおいかけるとか...