aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorGanesh Viswanathan <dev@genotrance.com>2019-10-16 17:13:27 -0500
committerGanesh Viswanathan <dev@genotrance.com>2019-10-16 17:13:27 -0500
commit48955b3aa140ee7a903e5bf6bb6e36527a0a8359 (patch)
tree52de8fd21e9fbce6dd4cb38cf8d6b3f86ddb4266 /tests
parent531843a82a5efe59c15a675d9c3c8c5f28d4cab0 (diff)
downloadnimterop-48955b3aa140ee7a903e5bf6bb6e36527a0a8359.tar.gz
nimterop-48955b3aa140ee7a903e5bf6bb6e36527a0a8359.zip
Partial fix for #139
Diffstat (limited to 'tests')
-rw-r--r--tests/include/test.c4
-rw-r--r--tests/include/test.h1
-rw-r--r--tests/tnimterop_c.nim5
3 files changed, 10 insertions, 0 deletions
diff --git a/tests/include/test.c b/tests/include/test.c
index 8990df9..18e444f 100644
--- a/tests/include/test.c
+++ b/tests/include/test.c
@@ -64,6 +64,10 @@ void **test_call10(int **param1) {
return NULL;
}
+char *test_array_param(int arr[5]) {
+ return NULL;
+}
+
void multiline1(void) {}
void *multiline2(void) {
diff --git a/tests/include/test.h b/tests/include/test.h
index df48cd0..d062277 100644
--- a/tests/include/test.h
+++ b/tests/include/test.h
@@ -119,6 +119,7 @@ int test_call_param7(union UNION1 param1);
float test_call_param8(int *param1);
void *test_call9();
void **test_call10(int **param1);
+char *test_array_param(int arr[5]);
// Issue #58
void
diff --git a/tests/tnimterop_c.nim b/tests/tnimterop_c.nim
index 1c30387..a289303 100644
--- a/tests/tnimterop_c.nim
+++ b/tests/tnimterop_c.nim
@@ -178,3 +178,8 @@ check TDEFL_OUT_BUF_SIZE == 85196
check TDEFL_BOGUS_1 == 2
check TDEFL_BOGUS_2 == 1024
check TDEFL_BOGUS_3 == (85196 / 2).int
+
+var
+ arr: array[5, cint]
+
+check test_array_param(arr) == nil