all repos — min @ 3eed102c9f05b217095b3f7fd68d575e73d3e65a

A small but practical concatenative programming language.

Fixed to-timestamp regression.
h3rald h3rald@h3rald.com
Wed, 10 Nov 2021 13:55:37 +0100
commit

3eed102c9f05b217095b3f7fd68d575e73d3e65a

parent

8fb68f168c392593a1626f9f0cbe7f20d1094c76

1 files changed, 2 insertions(+), 2 deletions(-)

jump to
M minpkg/lib/min_time.nimminpkg/lib/min_time.nim

@@ -44,12 +44,12 @@ let dict = vals[0]

try: let year = i.dget(dict, "year").intVal.int let month = Month(i.dget(dict, "month").intVal.int - 1) - let monthday = i.dget(dict, "day").intVal.int + let monthday = MonthdayRange(i.dget(dict, "day").intVal.int) let hour: HourRange = i.dget(dict, "hour").intVal.int let minute: MinuteRange = i.dget(dict, "minute").intVal.int let second: SecondRange = i.dget(dict, "second").intVal.int let timezone = i.dget(dict, "timezone").intVal.int - let tinfo = datetime(monthday, month, year, hour, minute, second, 00, utc()) + let tinfo = dateTime(year, month, monthday, hour, minute, second, 0, utc()) i.push (tinfo + timezone.seconds).toTime.toUnix.int.newVal except: raiseInvalid("An invalid timeinfo dictionary was provided.")