diff options
author | Ward <khchen@gmail.com> | 2024-07-22 20:23:18 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-22 14:23:18 +0200 |
commit | c83a9c4c5c6ad4e96c47ceb866ea05806889b03f (patch) | |
tree | f5b4d84dd44e9c4c87296b1ab5e53f95e8102fb7 | |
parent | 7b50d05d6be3662431e990b707379bac6f100821 (diff) | |
download | Nim-c83a9c4c5c6ad4e96c47ceb866ea05806889b03f.tar.gz |
fixes #23838: Compilation by MinGW for cpu=i386 with time_t bug (#23876)
Change Time type in std/time_t to `distinct clong` instead of `distinct int32`
-rw-r--r-- | lib/std/time_t.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/std/time_t.nim b/lib/std/time_t.nim index 5fa95fff3..de051b135 100644 --- a/lib/std/time_t.nim +++ b/lib/std/time_t.nim @@ -14,7 +14,7 @@ when defined(nimdoc): ## Wrapper for `time_t`. On posix, this is an alias to `posix.Time`. elif defined(windows): when defined(i386) and defined(gcc): - type Time* {.importc: "time_t", header: "<time.h>".} = distinct int32 + type Time* {.importc: "time_t", header: "<time.h>".} = distinct clong else: # newest version of Visual C++ defines time_t to be of 64 bits type Time* {.importc: "time_t", header: "<time.h>".} = distinct int64 |