diff options
author | Jake Leahy <jake@leahy.dev> | 2023-06-26 23:07:42 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-26 15:07:42 +0200 |
commit | 43a3de9077955031e55691ebb84ee958f6aa260e (patch) | |
tree | a83171f9fdea667c36d18c7c7a9bcb15bfae0f61 /lib/pure | |
parent | 3e44d5742fe7fb54d91465320ee19cb613ae0b46 (diff) | |
download | Nim-43a3de9077955031e55691ebb84ee958f6aa260e.tar.gz |
Fix regression in `std/times` (#22155)
* Add simple test case Just so the regression doesn't happen again * Specify initDateTime is gcsafe in the forward declarations
Diffstat (limited to 'lib/pure')
-rw-r--r-- | lib/pure/times.nim | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/pure/times.nim b/lib/pure/times.nim index bea1ac760..4f7af657c 100644 --- a/lib/pure/times.nim +++ b/lib/pure/times.nim @@ -1529,11 +1529,11 @@ proc getClockStr*(dt = now()): string {.rtl, extern: "nt$1", tags: [TimeEffect]. proc initDateTime*(weekday: WeekDay, isoweek: IsoWeekRange, isoyear: IsoYear, hour: HourRange, minute: MinuteRange, second: SecondRange, nanosecond: NanosecondRange, - zone: Timezone = local()): DateTime {.raises: [], tags: [], since: (1, 5).} + zone: Timezone = local()): DateTime {.gcsafe, raises: [], tags: [], since: (1, 5).} proc initDateTime*(weekday: WeekDay, isoweek: IsoWeekRange, isoyear: IsoYear, hour: HourRange, minute: MinuteRange, second: SecondRange, - zone: Timezone = local()): DateTime {.raises: [], tags: [], since: (1, 5).} + zone: Timezone = local()): DateTime {.gcsafe, raises: [], tags: [], since: (1, 5).} # # TimeFormat |