diff --git a/examples/ext/lib_test/lib_test/gen/config.json b/examples/ext/lib_test/lib_test/gen/config.json index 23288d5..b1097c4 100644 --- a/examples/ext/lib_test/lib_test/gen/config.json +++ b/examples/ext/lib_test/lib_test/gen/config.json @@ -26,16 +26,15 @@ "func_pppPc_args_V", "func_V_args_ppPc", "func_pppPc_args_pppPc", - - + "func_pppPc_args_pppPc_ppPc", "func__PS_args_V", "func_TTAPS_args_V", "func_pTAPS_args_V", "func_ppTAPS_args_V", "func_pppTAPS_args_V", - - - "func_V_args_pTAPS" + "func_V_args_pTAPS", + "func_ppTAPS_args_ppTAPS", + "func_pppTAPS_args_pppTAPS" ], "debug_ast" : "True", "debug_acid" : "True", diff --git a/examples/ext/lib_test/tests/test_lib_test.py b/examples/ext/lib_test/tests/test_lib_test.py index bed18f1..35b829d 100644 --- a/examples/ext/lib_test/tests/test_lib_test.py +++ b/examples/ext/lib_test/tests/test_lib_test.py @@ -28,13 +28,14 @@ def test_func_Pi_args_Pi(): assert (ret == 23) assert (arg1 == 22) -# @pytest.mark.skip("") +@pytest.mark.skip("") def test_func_V_args_pPi(): (ret,arg1) = func_V_args_pPi(22) print("RESULT:", ret, arg1) assert (ret == None) assert (arg1 == 23) +@pytest.mark.skip("") def test_func_Pi_args_Pi_pPi_pPi(): (ret, arg1, arg2, arg3) = func_Pi_args_Pi_pPi_pPi(23, 22, 22) print("RESULT:", ret, arg1, arg2, arg3) @@ -195,14 +196,6 @@ def test_func_pppTAPS_args_V(): assert(ret.field__P_1 == 23); assert(ret.field__P_2 == 23); - - - - - - - - def test_func_V_args_pTAPS(): ps = PS() print(PS_to_string(ps)) @@ -212,6 +205,24 @@ def test_func_V_args_pTAPS(): assert(psnew.field__P_1 == 23); assert(psnew.field__P_2 == 23); +def test_func_ppTAPS_args_ppTAPS(): + ps = PS() + print(PS_to_string(ps)) + (ret,inout) = func_ppTAPS_args_ppTAPS(ps) + print(PS_to_string(ret)) + assert(ret.field__P_1 == 23); + assert(inout.field__P_1 == 23); + assert(inout.field__P_2 == 23); + +def test_func_pppTAPS_args_pppTAPS(): + ps = PS() + print(PS_to_string(ps)) + (ret,inout) = func_pppTAPS_args_pppTAPS(ps) + print(PS_to_string(ret)) + assert(ret.field__P_1 == 23); + assert(inout.field__P_1 == 23); + assert(inout.field__P_2 == 23); + def PS_to_string(ps): diff --git a/examples/lib/lib_test/functions.h b/examples/lib/lib_test/functions.h index 86a1959..2595e64 100644 --- a/examples/lib/lib_test/functions.h +++ b/examples/lib/lib_test/functions.h @@ -55,7 +55,7 @@ const char* func_pPcc_args_pPcc_pPcc(const char* arg1_pPcc,const char* arg2_pPcc // String-by-ref (char**) char** func_ppPc_args_V(); -char*** func_pppPc_args_V(); //DONE +char*** func_pppPc_args_V(); void func_V_args_ppPc(char** arg1_ppPc); // @@ -66,18 +66,18 @@ char*** func_pppPc_args_pppPc_ppPc(char*** arg1_ppPc,char** arg2_ppPc); // Structs // ======= // By value -struct _PS func__PS_args_V(); //DONE +struct _PS func__PS_args_V(); -TTAPS func_TTAPS_args_V(); //DONE +TTAPS func_TTAPS_args_V(); // By pointer -TAPS* func_pTAPS_args_V(); //DONE +TAPS* func_pTAPS_args_V(); -TAPS** func_ppTAPS_args_V(); //DONE +TAPS** func_ppTAPS_args_V(); -TAPS*** func_pppTAPS_args_V(); //DONE +TAPS*** func_pppTAPS_args_V(); -void func_V_args_pTAPS(TAPS* arg1_pTAPS); //DONE +void func_V_args_pTAPS(TAPS* arg1_pTAPS); TAPS** func_ppTAPS_args_ppTAPS(TAPS** arg1_ppTAPS);