diff options
author | Philip Withnall <philip.withnall@collabora.co.uk> | 2015-11-06 12:42:11 +0100 |
---|---|---|
committer | Philip Withnall <philip.withnall@collabora.co.uk> | 2015-11-06 12:45:04 +0100 |
commit | d8e257464bd93ea502740169887297fa62925a16 (patch) | |
tree | f43cd0266e2413ff5ea85dc1fb9ae523d27f7ab6 /tests/scanner/regress.c | |
parent | 54a5ed77c9c1296c7709c80428dc41d535999798 (diff) | |
download | gobject-introspection-d8e257464bd93ea502740169887297fa62925a16.tar.gz |
tests: Add more regression tests for (not nullable)
On bug #719966, the question arose of whether parameters annotated with
(element-type) but not (not nullable) are regarded as nullable or
non-nullable.
Add some new unit tests to Regress-1.0.gir to check the behaviour is as
expected: annotating a parameter with (element-type) implicitly makes it
non-nullable (unless also annotated with (nullable)).
https://bugzilla.gnome.org/show_bug.cgi?id=757678
Diffstat (limited to 'tests/scanner/regress.c')
-rw-r--r-- | tests/scanner/regress.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/scanner/regress.c b/tests/scanner/regress.c index 9a9ee679..fa481054 100644 --- a/tests/scanner/regress.c +++ b/tests/scanner/regress.c @@ -3042,6 +3042,30 @@ regress_func_obj_nullable_in (RegressTestObj *obj) } /** + * regress_test_obj_not_nullable_typed_gpointer_in: + * @obj: A #RegressTestObj + * @input: (type GObject): some #GObject + */ +void +regress_test_obj_not_nullable_typed_gpointer_in (RegressTestObj *obj, + gpointer input) +{ +} + +/** + * regress_test_obj_not_nullable_element_typed_gpointer_in: + * @obj: A #RegressTestObj + * @input: (element-type guint8) (array length=count): some uint8 array + * @count: length of @input + */ +void +regress_test_obj_not_nullable_element_typed_gpointer_in (RegressTestObj *obj, + gpointer input, + guint count) +{ +} + +/** * regress_test_array_fixed_out_objects: * @objs: (out) (array fixed-size=2) (transfer full): An array of #RegressTestObj */ |