summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaolo Borelli <pborelli@gnome.org>2013-01-10 22:23:36 +0100
committerPaolo Borelli <pborelli@gnome.org>2013-01-11 09:50:09 +0100
commit6ad132c69c74f46f54d770835ea45e8a58fbd612 (patch)
tree6d5be69232d7be2cd1c4e9b51700d25ff141a0d0
parentfbe0966625757266040d1a9831d27f78bd00d753 (diff)
downloadgobject-introspection-6ad132c69c74f46f54d770835ea45e8a58fbd612.tar.gz
gimarshallingtests: Add vfunc with an array output
Add vfunc_array_out_param to GIMarshallingTestsObjectClass. https://bugzilla.gnome.org/show_bug.cgi?id=690851
-rw-r--r--tests/gimarshallingtests.c13
-rw-r--r--tests/gimarshallingtests.h7
2 files changed, 20 insertions, 0 deletions
diff --git a/tests/gimarshallingtests.c b/tests/gimarshallingtests.c
index 95bb196e..d4b6cb30 100644
--- a/tests/gimarshallingtests.c
+++ b/tests/gimarshallingtests.c
@@ -4239,6 +4239,19 @@ gi_marshalling_tests_object_vfunc_caller_allocated_out_parameter (GIMarshallingT
}
/**
+ * gi_marshalling_tests_object_vfunc_array_out_parameter:
+ * @a: (out) (array zero-terminated=1):
+ */
+void
+gi_marshalling_tests_object_vfunc_array_out_parameter (GIMarshallingTestsObject *self, gfloat **a)
+{
+ /* make sure that local variables don't get smashed */
+ gulong local = 0x12345678;
+ GI_MARSHALLING_TESTS_OBJECT_GET_CLASS (self)->vfunc_array_out_parameter (self, a);
+ g_assert_cmpint(local, ==, 0x12345678);
+}
+
+/**
* gi_marshalling_tests_object_vfunc_return_value_and_one_out_parameter:
* @a: (out):
*/
diff --git a/tests/gimarshallingtests.h b/tests/gimarshallingtests.h
index e4875d6e..03d165b9 100644
--- a/tests/gimarshallingtests.h
+++ b/tests/gimarshallingtests.h
@@ -778,6 +778,12 @@ struct _GIMarshallingTestsObjectClass
void (* vfunc_caller_allocated_out_parameter) (GIMarshallingTestsObject *self, GValue *a);
/**
+ * GIMarshallingTestsObjectClass::vfunc_array_out_parameter:
+ * @a: (out) (array zero-terminated=1):
+ */
+ void (* vfunc_array_out_parameter) (GIMarshallingTestsObject *self, gfloat **a);
+
+ /**
* GIMarshallingTestsObjectClass::vfunc_return_value_and_one_out_parameter:
* @a: (out):
*/
@@ -828,6 +834,7 @@ glong gi_marshalling_tests_object_vfunc_return_value_only (GIMarshallingTestsObj
void gi_marshalling_tests_object_vfunc_one_out_parameter (GIMarshallingTestsObject *self, gfloat *a);
void gi_marshalling_tests_object_vfunc_multiple_out_parameters (GIMarshallingTestsObject *self, gfloat *a, gfloat *b);
void gi_marshalling_tests_object_vfunc_caller_allocated_out_parameter (GIMarshallingTestsObject *self, GValue *a);
+void gi_marshalling_tests_object_vfunc_array_out_parameter (GIMarshallingTestsObject *self, gfloat **a);
glong gi_marshalling_tests_object_vfunc_return_value_and_one_out_parameter (GIMarshallingTestsObject *self, glong *a);
glong gi_marshalling_tests_object_vfunc_return_value_and_multiple_out_parameters (GIMarshallingTestsObject *self, glong *a, glong *b);
gboolean gi_marshalling_tests_object_vfunc_meth_with_error (GIMarshallingTestsObject *object, gint x, GError **error);