[gobject-introspection] Fix malformed GTK-Doc comment blocks:



commit 2cfa44faa192ae9cc0d7bb36f1c7dd6f3b929fb3
Author: Dieter Verfaillie <dieterv optionexplicit be>
Date:   Tue Apr 3 07:47:48 2012 +0200

    Fix malformed GTK-Doc comment blocks:
    
    - add missing colons
    - invalid annotations
    - invalid parameters and tags
    - correct parameter name
    - preserve description indentation
    - no description parts
    - comment end marker
    - invalid empty lines
    - line numbers
    
    AnnotationParser now emits warnings which are considered as
    errors by "make check" so fix those warnings...
    
    https://bugzilla.gnome.org/show_bug.cgi?id=672254

 girepository/girepository.c               |    6 ++--
 girepository/girepository.h               |    2 +-
 girepository/gitypes.h                    |    2 +-
 tests/gimarshallingtests.c                |   38 ++++++++++++++++++++++
 tests/scanner/Annotation-1.0-expected.gir |    2 +-
 tests/scanner/Foo-1.0-expected.gir        |    6 ++--
 tests/scanner/Regress-1.0-expected.gir    |   50 ++++++++++++++--------------
 tests/scanner/annotation.c                |   19 +++++------
 tests/scanner/foo.c                       |    2 +-
 tests/scanner/foo.h                       |    4 +-
 tests/scanner/regress.c                   |    9 +++++-
 tests/scanner/regress.h                   |    2 +-
 tests/warn/callback-invalid-scope.h       |    4 +-
 tests/warn/invalid-element-type.h         |    4 +-
 tests/warn/invalid-method.h               |    4 +-
 tests/warn/return-gobject.h               |    2 +-
 16 files changed, 100 insertions(+), 56 deletions(-)
---
diff --git a/girepository/girepository.c b/girepository/girepository.c
index 1384c0e..bcc4a1b 100644
--- a/girepository/girepository.c
+++ b/girepository/girepository.c
@@ -809,7 +809,7 @@ collect_namespaces (gpointer key,
  *
  * Return the list of currently loaded namespaces.
  *
- * Returns: (utf8) (transfer full): List of namespaces
+ * Returns: (element-type utf8) (transfer full): List of namespaces
  */
 gchar **
 g_irepository_get_loaded_namespaces (GIRepository *repository)
@@ -902,7 +902,7 @@ g_irepository_get_shared_library (GIRepository *repository,
 }
 
 /**
- * g_irepository_get_c_prefix
+ * g_irepository_get_c_prefix:
  * @repository: (allow-none): A #GIRepository, may be %NULL for the default
  * @namespace_: Namespace to inspect
  *
@@ -938,7 +938,7 @@ g_irepository_get_c_prefix (GIRepository *repository,
 }
 
 /**
- * g_irepository_get_typelib_path
+ * g_irepository_get_typelib_path:
  * @repository: (allow-none): Repository, may be %NULL for the default
  * @namespace_: GI namespace to use, e.g. "Gtk"
  *
diff --git a/girepository/girepository.h b/girepository/girepository.h
index 02bd4a1..eb990a2 100644
--- a/girepository/girepository.h
+++ b/girepository/girepository.h
@@ -74,7 +74,7 @@ struct _GIRepositoryClass
 };
 
 /**
- * GIRepositoryLoadFlags
+ * GIRepositoryLoadFlags:
  * @G_IREPOSITORY_LOAD_FLAG_LAZY: Load the types lazily.
  *
  * Flags that controlls how a typelib is loaded by
diff --git a/girepository/gitypes.h b/girepository/gitypes.h
index 486f20a..88181b2 100644
--- a/girepository/gitypes.h
+++ b/girepository/gitypes.h
@@ -117,7 +117,7 @@ typedef GIBaseInfo GIValueInfo;
 typedef GIBaseInfo GISignalInfo;
 
 /**
- * GIVFuncInfo
+ * GIVFuncInfo:
  *
  * Represents a virtual function.
  */
diff --git a/tests/gimarshallingtests.c b/tests/gimarshallingtests.c
index e42233f..991e286 100644
--- a/tests/gimarshallingtests.c
+++ b/tests/gimarshallingtests.c
@@ -1145,6 +1145,7 @@ gi_marshalling_tests_init_function (gint *n_args, char ***argv)
 
 /**
  * gi_marshalling_tests_array_fixed_int_return:
+ *
  * Returns: (array fixed-size=4):
  */
 const gint *
@@ -1156,6 +1157,7 @@ gi_marshalling_tests_array_fixed_int_return (void)
 
 /**
  * gi_marshalling_tests_array_fixed_short_return:
+ *
  * Returns: (array fixed-size=4):
  */
 const gshort *
@@ -1244,6 +1246,7 @@ gi_marshalling_tests_array_fixed_inout (gint **ints)
 
 /**
  * gi_marshalling_tests_array_return:
+ *
  * Returns: (array length=length):
  */
 const gint *
@@ -1261,6 +1264,7 @@ gi_marshalling_tests_array_return (gint *length)
  * @length: (out):
  * @last:
  * @sum: (out):
+ *
  * Returns: (array length=length):
  */
 const gint *
@@ -1527,6 +1531,7 @@ gi_marshalling_tests_array_inout_etc (gint first, gint **ints, gint *length, gin
 
 /**
  * gi_marshalling_tests_array_zero_terminated_return:
+ *
  * Returns: (array zero-terminated=1) (transfer none):
  */
 gchar **
@@ -1538,6 +1543,7 @@ gi_marshalling_tests_array_zero_terminated_return (void)
 
 /**
  * gi_marshalling_tests_array_zero_terminated_return_null:
+ *
  * Returns: (array zero-terminated=1) (transfer none):
  */
 gchar **
@@ -1548,6 +1554,7 @@ gi_marshalling_tests_array_zero_terminated_return_null (void)
 
 /**
  * gi_marshalling_tests_array_zero_terminated_return_struct:
+ *
  * Returns: (array zero-terminated=1) (transfer full):
  */
 GIMarshallingTestsBoxedStruct **
@@ -1613,6 +1620,7 @@ gi_marshalling_tests_array_zero_terminated_inout (gchar ***utf8s)
 /**
  * gi_marshalling_tests_array_gvariant_none_in:
  * @variants: (array zero-terminated=1) (transfer none):
+ *
  * Returns: (array zero-terminated=1) (transfer none):
  */
 GVariant **
@@ -1637,6 +1645,7 @@ gi_marshalling_tests_array_gvariant_none_in (GVariant **variants)
 /**
  * gi_marshalling_tests_array_gvariant_container_in:
  * @variants: (array zero-terminated=1) (transfer container):
+ *
  * Returns: (array zero-terminated=1) (transfer container):
  */
 GVariant **
@@ -1660,6 +1669,7 @@ gi_marshalling_tests_array_gvariant_container_in (GVariant **variants)
 /**
  * gi_marshalling_tests_array_gvariant_full_in:
  * @variants: (array zero-terminated=1) (transfer full):
+ *
  * Returns: (array zero-terminated=1) (transfer full):
  */
 GVariant **
@@ -1686,6 +1696,7 @@ gi_marshalling_tests_array_gvariant_full_in (GVariant **variants)
 
 /**
  * gi_marshalling_tests_garray_int_none_return:
+ *
  * Returns: (element-type gint) (transfer none):
  */
 GArray *
@@ -1705,6 +1716,7 @@ gi_marshalling_tests_garray_int_none_return (void)
 
 /**
  * gi_marshalling_tests_garray_utf8_none_return:
+ *
  * Returns: (element-type utf8) (transfer none):
  */
 GArray *
@@ -1725,6 +1737,7 @@ gi_marshalling_tests_garray_utf8_none_return (void)
 
 /**
  * gi_marshalling_tests_garray_utf8_container_return:
+ *
  * Returns: (element-type utf8) (transfer container):
  */
 GArray *
@@ -1743,6 +1756,7 @@ gi_marshalling_tests_garray_utf8_container_return (void)
 
 /**
  * gi_marshalling_tests_garray_utf8_full_return:
+ *
  * Returns: (element-type utf8) (transfer full):
  */
 GArray *
@@ -1928,6 +1942,7 @@ gi_marshalling_tests_garray_utf8_full_inout (GArray **array_)
 
 /**
  * gi_marshalling_tests_gptrarray_utf8_none_return:
+ *
  * Returns: (element-type utf8) (transfer none):
  */
 GPtrArray *
@@ -1948,6 +1963,7 @@ gi_marshalling_tests_gptrarray_utf8_none_return (void)
 
 /**
  * gi_marshalling_tests_gptrarray_utf8_container_return:
+ *
  * Returns: (element-type utf8) (transfer container):
  */
 GPtrArray *
@@ -1966,6 +1982,7 @@ gi_marshalling_tests_gptrarray_utf8_container_return (void)
 
 /**
  * gi_marshalling_tests_gptrarray_utf8_full_return:
+ *
  * Returns: (element-type utf8) (transfer full):
  */
 GPtrArray *
@@ -2137,6 +2154,7 @@ gi_marshalling_tests_gptrarray_utf8_full_inout (GPtrArray **parray_)
 
 /**
  * gi_marshalling_tests_bytearray_full_return:
+ *
  * Returns: (transfer full):
  */
 GByteArray *
@@ -2225,6 +2243,7 @@ gi_marshalling_tests_gstrv_inout (GStrv *g_strv)
 
 /**
  * gi_marshalling_tests_glist_int_none_return:
+ *
  * Returns: (element-type gint) (transfer none):
  */
 GList *
@@ -2244,6 +2263,7 @@ gi_marshalling_tests_glist_int_none_return (void)
 
 /**
  * gi_marshalling_tests_glist_utf8_none_return:
+ *
  * Returns: (element-type utf8) (transfer none):
  */
 GList *
@@ -2262,6 +2282,7 @@ gi_marshalling_tests_glist_utf8_none_return (void)
 
 /**
  * gi_marshalling_tests_glist_utf8_container_return:
+ *
  * Returns: (element-type utf8) (transfer container):
  */
 GList *
@@ -2278,6 +2299,7 @@ gi_marshalling_tests_glist_utf8_container_return (void)
 
 /**
  * gi_marshalling_tests_glist_utf8_full_return:
+ *
  * Returns: (element-type utf8) (transfer full):
  */
 GList *
@@ -2436,6 +2458,7 @@ gi_marshalling_tests_glist_utf8_full_inout (GList **list)
 
 /**
  * gi_marshalling_tests_gslist_int_none_return:
+ *
  * Returns: (element-type gint) (transfer none):
  */
 GSList *
@@ -2456,6 +2479,7 @@ gi_marshalling_tests_gslist_int_none_return (void)
 
 /**
  * gi_marshalling_tests_gslist_utf8_none_return:
+ *
  * Returns: (element-type utf8) (transfer none):
  */
 GSList *
@@ -2475,6 +2499,7 @@ gi_marshalling_tests_gslist_utf8_none_return (void)
 
 /**
  * gi_marshalling_tests_gslist_utf8_container_return:
+ *
  * Returns: (element-type utf8) (transfer container):
  */
 GSList *
@@ -2492,6 +2517,7 @@ gi_marshalling_tests_gslist_utf8_container_return (void)
 
 /**
  * gi_marshalling_tests_gslist_utf8_full_return:
+ *
  * Returns: (element-type utf8) (transfer full):
  */
 GSList *
@@ -2655,6 +2681,7 @@ gi_marshalling_tests_gslist_utf8_full_inout (GSList **list)
 
 /**
  * gi_marshalling_tests_ghashtable_int_none_return:
+ *
  * Returns: (element-type gint gint) (transfer none):
  */
 GHashTable *
@@ -2675,6 +2702,7 @@ gi_marshalling_tests_ghashtable_int_none_return (void)
 
 /**
  * gi_marshalling_tests_ghashtable_utf8_none_return:
+ *
  * Returns: (element-type utf8 utf8) (transfer none):
  */
 GHashTable *
@@ -2695,6 +2723,7 @@ gi_marshalling_tests_ghashtable_utf8_none_return (void)
 
 /**
  * gi_marshalling_tests_ghashtable_utf8_container_return:
+ *
  * Returns: (element-type utf8 utf8) (transfer container):
  */
 GHashTable *
@@ -2713,6 +2742,7 @@ gi_marshalling_tests_ghashtable_utf8_container_return (void)
 
 /**
  * gi_marshalling_tests_ghashtable_utf8_full_return:
+ *
  * Returns: (element-type utf8 utf8) (transfer full):
  */
 GHashTable *
@@ -2873,6 +2903,7 @@ gi_marshalling_tests_ghashtable_utf8_full_inout (GHashTable **hash_table)
 
 /**
  * gi_marshalling_tests_gvalue_return:
+ *
  * Returns: (transfer none):
  */
 GValue *
@@ -3330,6 +3361,7 @@ gi_marshalling_tests_no_type_flags_inout (GIMarshallingTestsNoTypeFlags *flags_)
 
 /**
  * gi_marshalling_tests_simple_struct_returnv:
+ *
  * Returns: (transfer none):
  */
 GIMarshallingTestsSimpleStruct *
@@ -3380,6 +3412,7 @@ gi_marshalling_tests_pointer_struct_get_type (void)
 
 /**
  * gi_marshalling_tests_pointer_struct_returnv:
+ *
  * Returns: (transfer none):
  */
 GIMarshallingTestsPointerStruct *
@@ -3446,6 +3479,7 @@ gi_marshalling_tests_boxed_struct_new (void)
 
 /**
  * gi_marshalling_tests_boxed_struct_returnv:
+ *
  * Returns: (transfer none):
  */
 GIMarshallingTestsBoxedStruct *
@@ -3542,6 +3576,7 @@ gi_marshalling_tests_union_get_type (void)
 
 /**
  * gi_marshalling_tests_union_returnv:
+ *
  * Returns: (transfer none):
  */
 GIMarshallingTestsUnion *
@@ -3722,6 +3757,7 @@ gi_marshalling_tests_object_method_array_inout (GIMarshallingTestsObject *object
 
 /**
  * gi_marshalling_tests_object_method_array_return:
+ *
  * Returns: (array length=length):
  */
 const gint *
@@ -3804,6 +3840,7 @@ gi_marshalling_tests_object_call_vfunc_with_callback (GIMarshallingTestsObject *
 
 /**
  * gi_marshalling_tests_object_none_return:
+ *
  * Returns: (transfer none):
  */
 GIMarshallingTestsObject *
@@ -3820,6 +3857,7 @@ gi_marshalling_tests_object_none_return (void)
 
 /**
  * gi_marshalling_tests_object_full_return:
+ *
  * Returns: (transfer full):
  */
 GIMarshallingTestsObject *
diff --git a/tests/scanner/Annotation-1.0-expected.gir b/tests/scanner/Annotation-1.0-expected.gir
index 88b9ea4..ce43b36 100644
--- a/tests/scanner/Annotation-1.0-expected.gir
+++ b/tests/scanner/Annotation-1.0-expected.gir
@@ -590,7 +590,7 @@ of tabs and strings to test the tab handling capabilities of the scanner.</doc>
           <type name="none"/>
         </return-value>
         <parameters>
-          <parameter name="object" transfer-ownership="none">
+          <parameter name="arg1" transfer-ownership="none">
             <type name="gpointer"/>
           </parameter>
         </parameters>
diff --git a/tests/scanner/Foo-1.0-expected.gir b/tests/scanner/Foo-1.0-expected.gir
index 826d676..15be459 100644
--- a/tests/scanner/Foo-1.0-expected.gir
+++ b/tests/scanner/Foo-1.0-expected.gir
@@ -749,7 +749,7 @@ exposed to language bindings.</doc>
                      closure="1">
             <type name="GObject.Callback" c:type="GCallback"/>
           </parameter>
-          <parameter name="data" transfer-ownership="none">
+          <parameter name="user_data" transfer-ownership="none" closure="1">
             <type name="gpointer" c:type="gpointer"/>
           </parameter>
         </parameters>
@@ -783,7 +783,7 @@ exposed to language bindings.</doc>
                      closure="1">
             <type name="GObject.Callback" c:type="GCallback"/>
           </parameter>
-          <parameter name="data" transfer-ownership="none">
+          <parameter name="user_data" transfer-ownership="none">
             <type name="gpointer" c:type="gpointer"/>
           </parameter>
         </parameters>
@@ -870,7 +870,7 @@ exposed to language bindings.</doc>
                        closure="2">
               <type name="GObject.Callback" c:type="GCallback"/>
             </parameter>
-            <parameter name="data" transfer-ownership="none">
+            <parameter name="user_data" transfer-ownership="none" closure="2">
               <type name="gpointer" c:type="gpointer"/>
             </parameter>
           </parameters>
diff --git a/tests/scanner/Regress-1.0-expected.gir b/tests/scanner/Regress-1.0-expected.gir
index 5d806d3..5ca8a57 100644
--- a/tests/scanner/Regress-1.0-expected.gir
+++ b/tests/scanner/Regress-1.0-expected.gir
@@ -1040,7 +1040,7 @@ raise an error.</doc>
       </glib:signal>
       <glib:signal name="sig-with-array-prop" when="last">
         <doc xml:whitespace="preserve">This test signal is like TelepathyGlib's
-TpChannel:: group-members-changed-detailed:</doc>
+ TpChannel:: group-members-changed-detailed:</doc>
         <return-value transfer-ownership="none">
           <type name="none"/>
         </return-value>
@@ -1055,7 +1055,7 @@ TpChannel:: group-members-changed-detailed:</doc>
       </glib:signal>
       <glib:signal name="sig-with-hash-prop" when="last">
         <doc xml:whitespace="preserve">This test signal is like TelepathyGlib's
-TpAccount::status-changed</doc>
+ TpAccount::status-changed</doc>
         <return-value transfer-ownership="none">
           <type name="none"/>
         </return-value>
@@ -2716,30 +2716,30 @@ You will give me your credit card number.</doc>
     <function name="test_nested_parameter"
               c:identifier="regress_test_nested_parameter">
       <doc xml:whitespace="preserve">&lt;informaltable&gt;
-&lt;tgroup cols="3"&gt;
-&lt;thead&gt;
-&lt;row&gt;
-&lt;entry&gt;Syntax&lt;/entry&gt;
-&lt;entry&gt;Explanation&lt;/entry&gt;
-&lt;entry&gt;Examples&lt;/entry&gt;
-&lt;/row&gt;
-&lt;/thead&gt;
-&lt;tbody&gt;
-&lt;row&gt;
-&lt;entry&gt;rgb(@r, @g, @b)&lt;/entry&gt;
-&lt;entry&gt;An opaque color; @r, @g, @b can be either integers between
-0 and 255 or percentages&lt;/entry&gt;
-&lt;entry&gt;&lt;literallayout&gt;rgb(128, 10, 54)
+  &lt;tgroup cols="3"&gt;
+    &lt;thead&gt;
+      &lt;row&gt;
+        &lt;entry&gt;Syntax&lt;/entry&gt;
+        &lt;entry&gt;Explanation&lt;/entry&gt;
+        &lt;entry&gt;Examples&lt;/entry&gt;
+      &lt;/row&gt;
+    &lt;/thead&gt;
+    &lt;tbody&gt;
+      &lt;row&gt;
+        &lt;entry&gt;rgb(@r, @g, @b)&lt;/entry&gt;
+        &lt;entry&gt;An opaque color; @r, @g, @b can be either integers between
+               0 and 255 or percentages&lt;/entry&gt;
+        &lt;entry&gt;&lt;literallayout&gt;rgb(128, 10, 54)
 rgb(20%, 30%, 0%)&lt;/literallayout&gt;&lt;/entry&gt;
-&lt;/row&gt;
-&lt;row&gt;
-&lt;entry&gt;rgba(@r, @g, @b, @a)&lt;/entry&gt;
-&lt;entry&gt;A translucent color; @r, @g, @b are as in the previous row,
- a is a floating point number between 0 and 1&lt;/entry&gt;
-&lt;entry&gt;&lt;literallayout&gt;rgba(255, 255, 0, 0.5)&lt;/literallayout&gt;&lt;/entry&gt;
-&lt;/row&gt;
-&lt;/tbody&gt;
-&lt;/tgroup&gt;
+      &lt;/row&gt;
+      &lt;row&gt;
+        &lt;entry&gt;rgba(@r, @g, @b, @a)&lt;/entry&gt;
+        &lt;entry&gt;A translucent color; @r, @g, @b are as in the previous row,
+               @a is a floating point number between 0 and 1&lt;/entry&gt;
+        &lt;entry&gt;&lt;literallayout&gt;rgba(255, 255, 0, 0.5)&lt;/literallayout&gt;&lt;/entry&gt;
+      &lt;/row&gt;
+   &lt;/tbody&gt;
+ &lt;/tgroup&gt;
 &lt;/informaltable&gt;
 
 What we're testing here is that the scanner ignores the @a nested inside XML.</doc>
diff --git a/tests/scanner/annotation.c b/tests/scanner/annotation.c
index a4e4efc..d23239d 100644
--- a/tests/scanner/annotation.c
+++ b/tests/scanner/annotation.c
@@ -212,10 +212,10 @@ annotation_object_method (AnnotationObject *object)
 /**
  * annotation_object_out:
  * @object: a #GObject
+ * @outarg: (out): This is an argument test
  *
  * This is a test for out arguments
  *
- * @outarg: (out): This is an argument test
  * Return value: an int
  */
 gint
@@ -228,10 +228,10 @@ annotation_object_out (AnnotationObject *object, int *outarg)
 /**
  * annotation_object_in:
  * @object: a #GObject
+ * @inarg: (in) (transfer none): This is an argument test
  *
  * This is a test for in arguments
  *
- * @inarg: (in) (transfer none): This is an argument test
  * Return value: an int
  */
 gint
@@ -244,10 +244,10 @@ annotation_object_in (AnnotationObject *object, int *inarg)
 /**
  * annotation_object_inout:
  * @object: a #GObject
+ * @inoutarg: (inout): This is an argument test
  *
  * This is a test for out arguments
  *
- * @inoutarg: (inout): This is an argument test
  * Return value: an int
  */
 gint
@@ -259,10 +259,10 @@ annotation_object_inout (AnnotationObject *object, int *inoutarg)
 /**
  * annotation_object_inout2:
  * @object: a #GObject
+ * @inoutarg: (inout): This is an argument test
  *
  * This is a second test for out arguments
  *
- * @inoutarg: (inout): This is an argument test
  * Return value: an int
  */
 gint
@@ -275,10 +275,10 @@ annotation_object_inout2 (AnnotationObject *object, int *inoutarg)
 /**
  * annotation_object_inout3:
  * @object: a #GObject
+ * @inoutarg: (inout) (allow-none): This is an argument test
  *
  * This is a 3th test for out arguments
  *
- * @inoutarg: (inout) (allow-none): This is an argument test
  * Return value: an int
  */
 gint
@@ -292,10 +292,10 @@ annotation_object_inout3 (AnnotationObject *object, int *inoutarg)
 /**
  * annotation_object_calleeowns:
  * @object: a #GObject
+ * @toown: (out): a #GObject
  *
  * This is a test for out arguments; GObject defaults to transfer
  *
- * @toown: (out): a #GObject
  * Return value: an int
  */
 gint
@@ -308,11 +308,11 @@ annotation_object_calleeowns (AnnotationObject *object, GObject **toown)
 /**
  * annotation_object_calleesowns:
  * @object: a #GObject
+ * @toown1: (out) (transfer full): a #GObject
+ * @toown2: (out) (transfer none): a #GObject
  *
  * This is a test for out arguments, one transferred, other not
  *
- * @toown1: (out) (transfer full): a #GObject
- * @toown2: (out) (transfer none): a #GObject
  * Return value: an int
  */
 gint
@@ -362,7 +362,7 @@ annotation_object_get_hash (AnnotationObject *object)
 }
 
 /**
- * annotation_object_with_voidp
+ * annotation_object_with_voidp:
  * @data: Opaque pointer handle
  */
 void
@@ -718,7 +718,6 @@ annotation_object_extra_annos (AnnotationObject *object)
 
 /**
  * annotation_custom_destroy:
- *
  * @callback: (destroy destroy) (closure data): Destroy notification
  *
  * Test messing up the heuristic of closure/destroy-notification
diff --git a/tests/scanner/foo.c b/tests/scanner/foo.c
index 3e15444..fb20c7a 100644
--- a/tests/scanner/foo.c
+++ b/tests/scanner/foo.c
@@ -137,7 +137,6 @@ foo_sub_interface_do_moo (FooSubInterface *self, int x, gpointer y)
  * @self:
  * @callback: (scope call):
  * @user_data:
- *
  */
 void
 foo_sub_interface_do_baz (FooSubInterface *self, GCallback callback, gpointer user_data)
@@ -523,6 +522,7 @@ foo_test_string_array_with_g (gchar **array)
 
 /**
  * foo_test_array:
+ *
  * Returns: (element-type utf8) (transfer container):
  */
 GArray *
diff --git a/tests/scanner/foo.h b/tests/scanner/foo.h
index 4b20ed7..270ee21 100644
--- a/tests/scanner/foo.h
+++ b/tests/scanner/foo.h
@@ -79,7 +79,7 @@ struct _FooSubInterfaceIface
   /* explicitly test un-named parameters */
   void (*do_moo) (FooSubInterface *self, int, gpointer);
 
-  void (*do_baz) (FooSubInterface *self, GCallback callback, gpointer data);
+  void (*do_baz) (FooSubInterface *self, GCallback callback, gpointer user_data);
 };
 
 GType                 foo_sub_interface_get_type       (void) G_GNUC_CONST;
@@ -88,7 +88,7 @@ void foo_sub_interface_do_bar (FooSubInterface *self);
 void foo_sub_interface_do_moo (FooSubInterface *self, int, gpointer);
 void foo_sub_interface_do_baz (FooSubInterface *self,
                                GCallback callback,
-                               gpointer data);
+                               gpointer user_data);
 
 struct _FooObject
 {
diff --git a/tests/scanner/regress.c b/tests/scanner/regress.c
index 30029f9..7238ddf 100644
--- a/tests/scanner/regress.c
+++ b/tests/scanner/regress.c
@@ -284,6 +284,7 @@ regress_test_value_return(int i)
 
 /**
  * regress_test_cairo_context_full_return:
+ *
  * Returns: (transfer full):
  */
 cairo_t *
@@ -311,6 +312,7 @@ regress_test_cairo_context_none_in (cairo_t *context)
 
 /**
  * regress_test_cairo_surface_none_return:
+ *
  * Returns: (transfer none):
  */
 cairo_surface_t *
@@ -327,6 +329,7 @@ regress_test_cairo_surface_none_return (void)
 
 /**
  * regress_test_cairo_surface_full_return:
+ *
  * Returns: (transfer full):
  */
 cairo_surface_t *
@@ -429,6 +432,7 @@ static const char utf8_nonconst[] = "nonconst \xe2\x99\xa5 utf8";
 
 /**
  * regress_test_utf8_const_return:
+ *
  * Return value: UTF-8 string
  */
 const char *
@@ -709,7 +713,7 @@ regress_test_strv_in (char **arr)
  * @types: (array length=n_types): List of types
  *
  * Return value: (transfer full): string representation of provided types
- * */
+ */
 char *
 regress_test_array_gtype_in (int n_types, GType *types)
 {
@@ -808,6 +812,7 @@ regress_test_array_fixed_size_int_out (int **ints)
 
 /**
  * regress_test_array_fixed_size_int_return:
+ *
  * Returns: (array fixed-size=5) (transfer full): a list of 5 integers ranging from 0 to 4
  */
 int *
@@ -839,6 +844,7 @@ regress_test_strv_out_c (void)
 /**
  * regress_test_array_int_full_out:
  * @len: length of the returned array.
+ *
  * Returns: (array length=len) (transfer full): a new array of integers.
  */
 int *
@@ -855,6 +861,7 @@ regress_test_array_int_full_out(int *len)
 /**
  * regress_test_array_int_none_out:
  * @len: length of the returned array.
+ *
  * Returns: (array length=len) (transfer none): a static array of integers.
  */
 int *
diff --git a/tests/scanner/regress.h b/tests/scanner/regress.h
index 6ef3b60..4138568 100644
--- a/tests/scanner/regress.h
+++ b/tests/scanner/regress.h
@@ -362,7 +362,7 @@ struct _RegressTestObjClass
   int (*matrix) (RegressTestObj *obj, const char *somestr);
 
   /**
-   * RegressTestObjClass::allow_none_vfunc
+   * RegressTestObjClass::allow_none_vfunc:
    * @two: (allow-none): Another object
    */
   void (*allow_none_vfunc) (RegressTestObj *obj, RegressTestObj *two);
diff --git a/tests/warn/callback-invalid-scope.h b/tests/warn/callback-invalid-scope.h
index be0ef5b..583dc0c 100644
--- a/tests/warn/callback-invalid-scope.h
+++ b/tests/warn/callback-invalid-scope.h
@@ -27,5 +27,5 @@ void test_callback_invalid3(GCallback *callback, gpointer user_data);
 
 // EXPECT:23: Warning: Test: scope annotation needs one value, not 2
 
-// EXPECT:12: Warning: Test: test_callback_invalid2: argument callback: Missing (scope) annotation for callback without GDestroyNotify (valid: call, async)
-// EXPECT:21: Warning: Test: test_callback_invalid3: argument callback: Missing (scope) annotation for callback without GDestroyNotify (valid: call, async)
+// EXPECT:13: Warning: Test: test_callback_invalid2: argument callback: Missing (scope) annotation for callback without GDestroyNotify (valid: call, async)
+// EXPECT:22: Warning: Test: test_callback_invalid3: argument callback: Missing (scope) annotation for callback without GDestroyNotify (valid: call, async)
diff --git a/tests/warn/invalid-element-type.h b/tests/warn/invalid-element-type.h
index a3e71f5..71749d1 100644
--- a/tests/warn/invalid-element-type.h
+++ b/tests/warn/invalid-element-type.h
@@ -78,5 +78,5 @@ GList* test_unresolved_element_type(void);
 // EXPECT:51: Warning: Test: element-type annotation takes at least one option, none given
 // EXPECT:52: Warning: Test: invalid (element-type) for a GPtrArray, must be a pointer
 // EXPECT:63: Warning: Test: test_unresolved_element_type: Unknown type: 'Unresolved'
-// EXPECT:3: Warning: Test: test_invalid_list_element_type: argument l1: Missing (element-type) annotation
-// EXPECT:3: Warning: Test: test_invalid_list_element_type: argument l2: Missing (element-type) annotation
+// EXPECT:4: Warning: Test: test_invalid_list_element_type: argument l1: Missing (element-type) annotation
+// EXPECT:4: Warning: Test: test_invalid_list_element_type: argument l2: Missing (element-type) annotation
diff --git a/tests/warn/invalid-method.h b/tests/warn/invalid-method.h
index f0ee727..487f7a2 100644
--- a/tests/warn/invalid-method.h
+++ b/tests/warn/invalid-method.h
@@ -9,7 +9,7 @@ void test_method_no_parameters();
 // EXPECT:7: Warning: Test: test_method_no_parameters: Methods must have parameters
 
 /**
- * test_method_invalid_first_parameter: (method):
+ * test_method_invalid_first_parameter: (method)
  *
  */
 void test_method_invalid_first_parameter(int param);
@@ -17,7 +17,7 @@ void test_method_invalid_first_parameter(int param);
 // EXPECT:15: Warning: Test: test_method_invalid_first_parameter: Methods must have a pointer as their first parameter
 
 /**
- * test_method_invalid_namespace: (method):
+ * test_method_invalid_namespace: (method)
  *
  */
 void test_method_invalid_namespace(GClosure *param);
diff --git a/tests/warn/return-gobject.h b/tests/warn/return-gobject.h
index 5e621c3..b6c6304 100644
--- a/tests/warn/return-gobject.h
+++ b/tests/warn/return-gobject.h
@@ -10,4 +10,4 @@ GObject * test_get_object(void);
  */
 GObject * test_get_object2(void);
 
-// EXPECT:7: Warning: Test: test_get_object2: return value: Missing (transfer) annotation
+// EXPECT:8: Warning: Test: test_get_object2: return value: Missing (transfer) annotation



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]