aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorGanesh Viswanathan <dev@genotrance.com>2018-12-26 20:18:38 -0600
committerGanesh Viswanathan <dev@genotrance.com>2018-12-26 20:18:38 -0600
commite59e34a7be12c7f84099d8b56b038d3c3ab9c15c (patch)
tree5272c84122c6ed4f37cf0947ad4ebd815726c6a6 /tests
parent373e9decf333ec65c14d7c36a0d1d33e9eb2a803 (diff)
downloadnimterop-e59e34a7be12c7f84099d8b56b038d3c3ab9c15c.tar.gz
nimterop-e59e34a7be12c7f84099d8b56b038d3c3ab9c15c.zip
Array ptr, numeric length, tests
Diffstat (limited to 'tests')
-rw-r--r--tests/include/test.h4
-rw-r--r--tests/tnimterop_c.nim2
2 files changed, 6 insertions, 0 deletions
diff --git a/tests/include/test.h b/tests/include/test.h
index bf4f70d..e040d7f 100644
--- a/tests/include/test.h
+++ b/tests/include/test.h
@@ -46,6 +46,10 @@ typedef int * INTPTR;
typedef struct {
int *field;
+ int field2[TEST_INT];
+ enum ENUM field3[TEST_INT];
+ int *field4[TEST_INT];
+ ENUM4 *field5[TEST_INT];
} STRUCT4;
union UNION1 {
diff --git a/tests/tnimterop_c.nim b/tests/tnimterop_c.nim
index 45e94d6..deef7d2 100644
--- a/tests/tnimterop_c.nim
+++ b/tests/tnimterop_c.nim
@@ -39,6 +39,8 @@ ct = 4
s.field1 = 5
s2.field1 = 6
s3.field1 = 7
+s4.field2[2] = 5
+s4.field3[3] = enum1
e = enum1
e2 = enum4