summary refs log tree commit diff stats
path: root/tests/stdlib/concurrency/tatomic_import.nim
diff options
context:
space:
mode:
authorJames <james@frasca.me>2022-01-20 04:58:59 -0800
committerGitHub <noreply@github.com>2022-01-20 13:58:59 +0100
commit851e515bbae6edf6b28cf6723b2c7a45acce1869 (patch)
tree2334c888012184966b96d1c32b38f78324ba063b /tests/stdlib/concurrency/tatomic_import.nim
parent4a38092ac1f8368cb1ebb0245c99c701963662f8 (diff)
downloadNim-851e515bbae6edf6b28cf6723b2c7a45acce1869.tar.gz
Resolve cross file resolution errors in atomics (#19422) [backport:1.6]
* Resolve call undeclared routine testAndSet

* Fix undeclared field atomicType
Diffstat (limited to 'tests/stdlib/concurrency/tatomic_import.nim')
-rw-r--r--tests/stdlib/concurrency/tatomic_import.nim11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/stdlib/concurrency/tatomic_import.nim b/tests/stdlib/concurrency/tatomic_import.nim
new file mode 100644
index 000000000..e8faaae20
--- /dev/null
+++ b/tests/stdlib/concurrency/tatomic_import.nim
@@ -0,0 +1,11 @@
+import atomicSample
+
+block crossFileObjectContainingAGenericWithAComplexObject:
+  discard initAtomicWithGeneric[string]("foo")
+
+block crossFileObjectContainingAGenericWithAnInteger:
+  discard initAtomicWithGeneric[int](1)
+  discard initAtomicWithGeneric[int8](1)
+  discard initAtomicWithGeneric[int16](1)
+  discard initAtomicWithGeneric[int32](1)
+  discard initAtomicWithGeneric[int64](1)