From d32b9086a63559c3836f6df9fcae8f7d45a894aa Mon Sep 17 00:00:00 2001 From: ringabout <43030857+ringabout@users.noreply.github.com> Date: Sat, 17 Sep 2022 04:35:53 +0800 Subject: [PATCH] fixes Thread initializer for ARC/ORC on Macos (#20368) * fixes Thread initializer for ARC/ORC * another try * fix * use int --- lib/system/threadlocalstorage.nim | 2 +- tests/generics/tthread_generic.nim | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/system/threadlocalstorage.nim b/lib/system/threadlocalstorage.nim index cea9abb420c9b..b62c903c34a8c 100644 --- a/lib/system/threadlocalstorage.nim +++ b/lib/system/threadlocalstorage.nim @@ -141,7 +141,7 @@ else: header: "".} = cint else: type - SysThread* {.importc: "pthread_t", header: "".} = object + SysThread* {.importc: "pthread_t", header: "".} = int Pthread_attr {.importc: "pthread_attr_t", header: "".} = object ThreadVarSlot {.importc: "pthread_key_t", diff --git a/tests/generics/tthread_generic.nim b/tests/generics/tthread_generic.nim index 2af5a761583e4..300da56a68c6c 100644 --- a/tests/generics/tthread_generic.nim +++ b/tests/generics/tthread_generic.nim @@ -1,5 +1,5 @@ discard """ - cmd: "nim $target --hints:on --threads:on $options $file" + matrix: "--mm:refc; --mm:orc" action: compile """