This is an automated email from the git hooks/post-receive script.

intrigeri pushed a commit to annotated tag rel-0-02-9
in repository libglib-object-introspection-perl.

commit dd391d2699deceaf041bf32be6dc8c43ee35f94d
Author: Torsten Schönfeld <kaffeeti...@gmx.de>
Date:   Sun Mar 1 18:31:55 2015 +0100

    Harmonize and improve debug output
---
 GObjectIntrospection.xs        | 24 ++++++++++++------
 gperl-i11n-callback.c          |  4 +--
 gperl-i11n-info.c              |  2 +-
 gperl-i11n-invoke-c.c          | 28 ++++++++++++---------
 gperl-i11n-invoke-perl.c       | 42 +++++++++++++------------------
 gperl-i11n-invoke.c            |  6 ++---
 gperl-i11n-marshal-arg.c       | 14 ++++++-----
 gperl-i11n-marshal-array.c     | 41 ++++++++++++++++++------------
 gperl-i11n-marshal-callback.c  | 30 +++++++++++-----------
 gperl-i11n-marshal-hash.c      | 23 ++++++++---------
 gperl-i11n-marshal-interface.c | 57 +++++++++++++++++++++---------------------
 gperl-i11n-marshal-list.c      | 18 +++++++------
 gperl-i11n-marshal-struct.c    | 10 +++++---
 gperl-i11n-union.c             |  4 +--
 gperl-i11n-vfunc-interface.c   |  4 +--
 gperl-i11n-vfunc-object.c      |  4 +--
 16 files changed, 164 insertions(+), 147 deletions(-)

diff --git a/GObjectIntrospection.xs b/GObjectIntrospection.xs
index 3ed829d..1a2e81d 100644
--- a/GObjectIntrospection.xs
+++ b/GObjectIntrospection.xs
@@ -27,7 +27,10 @@
 
 /* #define NOISY */
 #ifdef NOISY
-# define dwarn(...) warn(__VA_ARGS__)
+# define dwarn(msg...) G_STMT_START { \
+                               g_printerr ("%s: ", G_STRFUNC); \
+                               g_printerr (msg); \
+                       } G_STMT_END
 #else
 # define dwarn(...)
 #endif
@@ -397,17 +400,20 @@ _register_types (class, namespace, package)
                info_type = g_base_info_get_type (info);
                name = g_base_info_get_name (info);
 
-               dwarn ("setting up %s::%s\n", namespace, name);
+               dwarn ("setting up %s.%s\n", namespace, name);
 
                if (info_type == GI_INFO_TYPE_CONSTANT) {
+                       dwarn ("  -> constant\n");
                        av_push (constants, newSVpv (name, 0));
                }
 
                if (info_type == GI_INFO_TYPE_FUNCTION) {
+                       dwarn ("  -> global function\n");
                        av_push (global_functions, newSVpv (name, 0));
                }
 
                if (info_type == GI_INFO_TYPE_INTERFACE) {
+                       dwarn ("  -> interface\n");
                        av_push (interfaces, newSVpv (name, 0));
                }
 
@@ -419,6 +425,7 @@ _register_types (class, namespace, package)
                    info_type == GI_INFO_TYPE_ENUM ||
                    info_type == GI_INFO_TYPE_FLAGS)
                {
+                       dwarn ("  looking for methods\n");
                        store_methods (namespaced_functions, info, info_type);
                }
 
@@ -426,10 +433,12 @@ _register_types (class, namespace, package)
                    info_type == GI_INFO_TYPE_STRUCT ||
                    info_type == GI_INFO_TYPE_UNION)
                {
+                       dwarn ("  looking for fields\n");
                        store_fields (fields, info, info_type);
                }
 
                if (info_type == GI_INFO_TYPE_OBJECT) {
+                       dwarn ("  looking for vfuncs\n");
                        store_objects_with_vfuncs (objects_with_vfuncs, info);
                }
 
@@ -559,7 +568,7 @@ _register_boxed_synonym (class, const gchar *reg_basename, 
const gchar *reg_name
                ccroak ("Could not lookup GType from function %s",
                        syn_gtype_function);
 
-       dwarn ("registering synonym %s => %s",
+       dwarn ("%s => %s",
               g_type_name (reg_type),
               g_type_name (syn_type));
        gperl_register_boxed_synonym (reg_type, syn_type);
@@ -759,7 +768,7 @@ _install_overrides (class, basename, object_name, 
target_package)
        GType gtype;
        gpointer klass;
     CODE:
-       dwarn ("_install_overrides: %s%s for %s\n",
+       dwarn ("%s.%s for %s\n",
               basename, object_name, target_package);
        repository = g_irepository_get_default ();
        info = g_irepository_find_by_name (repository, basename, object_name);
@@ -856,7 +865,7 @@ _invoke_fallback_vfunc (class, vfunc_package, vfunc_name, 
target_package, ...)
        gint field_offset;
        gpointer func_pointer;
     PPCODE:
-       dwarn ("_invoke_fallback_vfunc: %s::%s, target = %s\n",
+       dwarn ("%s::%s, target = %s\n",
               vfunc_package, vfunc_name, target_package);
        gtype = gperl_object_type_from_package (target_package);
        klass = g_type_class_peek (gtype);
@@ -926,8 +935,7 @@ _use_generic_signal_marshaller_for (class, const gchar 
*package, const gchar *si
                                                   signal_info);
        g_base_info_unref (closure_marshal_info);
 
-       dwarn ("_use_generic_signal_marshaller_for: "
-              "package %s, signal %s => closure %p\n",
+       dwarn ("package = %s, signal = %s => closure = %p\n",
               package, signal, closure);
        gperl_signal_set_marshaller_for (gtype, (gchar*) signal, 
(GClosureMarshal) closure);
 
@@ -953,7 +961,7 @@ _use_generic_signal_marshaller_for (class, const gchar 
*package, const gchar *si
         * work correctly for signals prior to commit
         * d8970fbc500a8b20853b564536251315587450d9 in
         * gobject-introspection. */
-       warn ("*** Cannot use generic signal marshallers for signal %s of %s "
+       warn ("*** Cannot use generic signal marshallers for signal '%s' of %s "
              "unless gobject-introspection >= 1.33.10; "
              "any handlers connected to the signal "
              "might thus be invoked incorrectly\n",
diff --git a/gperl-i11n-callback.c b/gperl-i11n-callback.c
index 76ac91f..9bb7155 100644
--- a/gperl-i11n-callback.c
+++ b/gperl-i11n-callback.c
@@ -65,7 +65,7 @@ static void
 release_perl_callback (gpointer data)
 {
        GPerlI11nPerlCallbackInfo *info = data;
-       dwarn ("releasing Perl callback info %p\n", info);
+       dwarn ("info = %p\n", info);
 
        /* g_callable_info_free_closure reaches into info->cif, so it needs to
         * be called before we free it.  See
@@ -119,7 +119,7 @@ static void
 release_c_callback (gpointer data)
 {
        GPerlI11nCCallbackInfo *info = data;
-       dwarn ("releasing C callback info %p\n", info);
+       dwarn ("info = %p\n", info);
 
        /* FIXME: we cannot call the destroy notify here because it might be
         * our own release_perl_callback which would try to free the ffi stuff
diff --git a/gperl-i11n-info.c b/gperl-i11n-info.c
index d8106ce..6eb18ab 100644
--- a/gperl-i11n-info.c
+++ b/gperl-i11n-info.c
@@ -25,7 +25,7 @@ get_function_info (GIRepository *repository,
                    const gchar *namespace,
                    const gchar *method)
 {
-       dwarn ("%s: %s, %s, %s\n", G_STRFUNC, basename, namespace, method);
+       dwarn ("%s, %s, %s\n", basename, namespace, method);
 
        if (namespace) {
                GIFunctionInfo *function_info = NULL;
diff --git a/gperl-i11n-invoke-c.c b/gperl-i11n-invoke-c.c
index 80ac875..a0678f5 100644
--- a/gperl-i11n-invoke-c.c
+++ b/gperl-i11n-invoke-c.c
@@ -86,7 +86,7 @@ invoke_c_code (GICallableInfo *info,
                 * point. */
                iinfo.base.current_pos = i; /* + method_offset; */
 
-               dwarn ("  arg %d, tag: %d (%s), is_pointer: %d, is_automatic: 
%d\n",
+               dwarn ("arg %d: tag = %d (%s), is_pointer = %d, is_automatic = 
%d\n",
                       i,
                       g_type_info_get_tag (arg_type),
                       g_type_tag_to_string (g_type_info_get_tag (arg_type)),
@@ -232,6 +232,7 @@ invoke_c_code (GICallableInfo *info,
           )
        {
                SV *value;
+               dwarn ("return value: type = %p\n", 
iinfo.base.return_type_info);
                value = SAVED_STACK_SV (arg_to_sv (&return_value,
                                                   iinfo.base.return_type_info,
                                                   
iinfo.base.return_type_transfer,
@@ -259,6 +260,7 @@ invoke_c_code (GICallableInfo *info,
                    {
                        GITransfer transfer;
                        SV *sv;
+                       dwarn ("out/inout arg at pos %d\n", i);
                        /* If we allocated the memory ourselves, we always own 
it. */
                        transfer = g_arg_info_is_caller_allocates (arg_info)
                                 ? GI_TRANSFER_CONTAINER
@@ -281,7 +283,7 @@ invoke_c_code (GICallableInfo *info,
 
        _clear_c_invocation_info (&iinfo);
 
-       dwarn ("  number of return values: %d\n", n_return_values);
+       dwarn ("n_return_values = %d\n", n_return_values);
 
        PUTBACK;
 }
@@ -301,11 +303,9 @@ _prepare_c_invocation_info (GPerlI11nCInvocationInfo 
*iinfo,
 
        prepare_invocation_info ((GPerlI11nInvocationInfo *) iinfo, info);
 
-       dwarn ("C invoke: %s::%s::%s => %s\n"
-              "  n_args: %d\n",
+       dwarn ("%s::%s::%s => %s\n",
               package, namespace, function,
-              g_base_info_get_name (info),
-              g_callable_info_get_n_args (info));
+              g_base_info_get_name (info));
 
        iinfo->target_package = package;
        iinfo->target_namespace = namespace;
@@ -347,12 +347,16 @@ _prepare_c_invocation_info (GPerlI11nCInvocationInfo 
*iinfo,
                iinfo->n_invoke_args++;
        }
 
-       dwarn ("C invoke: %s\n"
-              "  n_args: %d, n_invoke_args: %d, n_given_args: %d\n"
-              "  is_constructor: %d, is_method: %d\n",
-              iinfo->base.is_vfunc ? g_base_info_get_name (info) : 
g_function_info_get_symbol (info),
-              iinfo->base.n_args, iinfo->n_invoke_args, iinfo->n_given_args,
-              iinfo->is_constructor, iinfo->is_method);
+       dwarn ("  args = %u, given = %u, invoke = %u\n",
+              iinfo->base.n_args,
+              iinfo->n_given_args,
+              iinfo->n_invoke_args);
+
+       dwarn ("  symbol = %s\n",
+              iinfo->base.is_vfunc ? g_base_info_get_name (info) : 
g_function_info_get_symbol (info));
+
+       dwarn ("  is_constructor = %d, is_method = %d, throws = %d\n",
+              iinfo->is_constructor, iinfo->is_method, iinfo->throws);
 
        /* allocate enough space for all args in both the out and in lists.
         * we'll only use as much as we need.  since function argument lists
diff --git a/gperl-i11n-invoke-perl.c b/gperl-i11n-invoke-perl.c
index c4b612d..a037bec 100644
--- a/gperl-i11n-invoke-perl.c
+++ b/gperl-i11n-invoke-perl.c
@@ -64,9 +64,9 @@ invoke_perl_code (ffi_cif* cif, gpointer resp, gpointer* 
args, gpointer userdata
                data_sv = info->data ? SvREFCNT_inc (info->data) : NULL;
                first_sv = info->swap_data ? data_sv     : instance_sv;
                last_sv  = info->swap_data ? instance_sv : data_sv;
-               dwarn ("  info->data = %p, info->swap_data = %d\n",
+               dwarn ("info->data = %p, info->swap_data = %d\n",
                       info->data, info->swap_data);
-               dwarn ("  instance = %p, data = %p, first = %p, last = %p\n",
+               dwarn ("instance = %p, data = %p, first = %p, last = %p\n",
                       instance_sv, data_sv, first_sv, last_sv);
                if (first_sv)
                        XPUSHs (sv_2mortal (first_sv));
@@ -85,25 +85,19 @@ invoke_perl_code (ffi_cif* cif, gpointer resp, gpointer* 
args, gpointer userdata
 
                iinfo.base.current_pos = i;
 
-               dwarn ("arg info: %s (%p)\n"
-                      "  direction: %d\n"
-                      "  is return value: %d\n"
-                      "  is optional: %d\n"
-                      "  may be null: %d\n"
-                      "  transfer: %d\n",
-                      g_base_info_get_name (arg_info), arg_info,
-                      g_arg_info_get_direction (arg_info),
+               dwarn ("arg %d: info = %p (%s)\n",
+                      i, arg_info, g_base_info_get_name (arg_info));
+               dwarn ("  dir = %d, is retval = %d, is optional = %d, may be 
null = %d, transfer = %d\n",
+                      direction,
                       g_arg_info_is_return_value (arg_info),
                       g_arg_info_is_optional (arg_info),
                       g_arg_info_may_be_null (arg_info),
-                      g_arg_info_get_ownership_transfer (arg_info));
-
-               dwarn ("arg type: %p\n"
-                      "  is pointer: %d\n"
-                      "  tag: %s (%d)\n",
+                      transfer);
+               dwarn ("  arg type = %p, is pointer = %d, tag = %d (%s)\n",
                       arg_type,
                       g_type_info_is_pointer (arg_type),
-                      g_type_tag_to_string (g_type_info_get_tag (arg_type)), 
g_type_info_get_tag (arg_type));
+                      g_type_info_get_tag (arg_type),
+                      g_type_tag_to_string (g_type_info_get_tag (arg_type)));
 
                if (direction == GI_DIRECTION_IN ||
                    direction == GI_DIRECTION_INOUT)
@@ -221,6 +215,8 @@ invoke_perl_code (ffi_cif* cif, gpointer resp, gpointer* 
args, gpointer userdata
                                 * (nor is there an annotation for it). */
                                gboolean may_be_null = TRUE;
                                gboolean is_caller_allocated = 
g_arg_info_is_caller_allocates (arg_info);
+                               dwarn ("out/inout arg, pos = %d, 
is_caller_allocated = %d\n",
+                                      i, is_caller_allocated);
                                if (is_caller_allocated) {
                                        tmp_arg.v_pointer = out_pointer;
                                }
@@ -248,13 +244,11 @@ invoke_perl_code (ffi_cif* cif, gpointer resp, gpointer* 
args, gpointer userdata
                transfer = iinfo.base.return_type_transfer;
                may_be_null = g_callable_info_may_return_null (cb_interface); 
/* FIXME */
 
-               dwarn ("ret type: %p\n"
-                      "  is pointer: %d\n"
-                      "  tag: %d\n"
-                      "  transfer: %d\n",
-                      type_info,
+               dwarn ("return value: type = %p\n", type_info);
+               dwarn ("  is pointer = %d, tag = %d (%s), transfer = %d\n",
                       g_type_info_is_pointer (type_info),
                       g_type_info_get_tag (type_info),
+                      g_type_tag_to_string (g_type_info_get_tag (type_info)),
                       transfer);
 
                sv_to_arg (POPs, &arg, NULL, type_info,
@@ -305,7 +299,8 @@ invoke_perl_signal_handler (ffi_cif* cif, gpointer resp, 
gpointer* args, gpointe
        PERL_UNUSED_VAR (resp);
        PERL_UNUSED_VAR (marshal_data);
 
-       dwarn ("invoke_perl_signal_handler: n args %d\n",
+       dwarn ("%s, n_args = %d\n",
+              g_base_info_get_name (signal_info->interface),
               g_callable_info_get_n_args (signal_info->interface));
 
        cb_info = create_perl_callback_closure (signal_info->interface,
@@ -342,8 +337,7 @@ _prepare_perl_invocation_info (GPerlI11nPerlInvocationInfo 
*iinfo,
 
        prepare_invocation_info ((GPerlI11nInvocationInfo *) iinfo, info);
 
-       dwarn ("Perl invoke: %s\n"
-              "  n_args: %d\n",
+       dwarn ("%s, n_args = %d\n",
               g_base_info_get_name (info),
               g_callable_info_get_n_args (info));
 
diff --git a/gperl-i11n-invoke.c b/gperl-i11n-invoke.c
index ae50804..3023e8b 100644
--- a/gperl-i11n-invoke.c
+++ b/gperl-i11n-invoke.c
@@ -7,10 +7,7 @@ prepare_invocation_info (GPerlI11nInvocationInfo *iinfo,
        gint orig_n_args;
        guint i;
 
-       dwarn ("invoke: %s\n"
-              "  n_args: %d\n",
-              g_base_info_get_name (info),
-              g_callable_info_get_n_args (info));
+       dwarn ("%s\n", g_base_info_get_name (info));
 
        iinfo->interface = info;
 
@@ -24,6 +21,7 @@ prepare_invocation_info (GPerlI11nInvocationInfo *iinfo,
        orig_n_args = g_callable_info_get_n_args (info);
        g_assert (orig_n_args >= 0);
        iinfo->n_args = (guint) orig_n_args;
+       dwarn ("  n_args = %u\n", iinfo->n_args);
 
        if (iinfo->n_args) {
                iinfo->arg_infos = gperl_alloc_temp (sizeof (GITypeInfo*) * 
iinfo->n_args);
diff --git a/gperl-i11n-marshal-arg.c b/gperl-i11n-marshal-arg.c
index ce41ee7..74aa2a9 100644
--- a/gperl-i11n-marshal-arg.c
+++ b/gperl-i11n-marshal-arg.c
@@ -13,7 +13,10 @@ sv_to_arg (SV * sv,
 {
        GITypeTag tag = g_type_info_get_tag (type_info);
 
-       if (!gperl_sv_is_defined (sv))
+       dwarn ("type info = %p, arg info = %p, tag = %d (%s)\n",
+              type_info, arg_info, tag, g_type_tag_to_string (tag));
+
+       if (!gperl_sv_is_defined (sv)) {
                /* Interfaces, booleans and void types need to be able to
                 * handle undef separately.*/
                if (!may_be_null && tag != GI_TYPE_TAG_INTERFACE
@@ -27,13 +30,13 @@ sv_to_arg (SV * sv,
                                ccroak ("undefined value encountered");
                        }
                }
+       }
 
        switch (tag) {
            case GI_TYPE_TAG_VOID:
                /* returns NULL if no match is found */
                arg->v_pointer = sv_to_callback_data (sv, invocation_info);
-               dwarn ("    argument with no type information -> pointer %p\n",
-                      arg->v_pointer);
+               dwarn ("  -> pointer %p\n", arg->v_pointer);
                break;
 
            case GI_TYPE_TAG_BOOLEAN:
@@ -96,7 +99,6 @@ sv_to_arg (SV * sv,
                break;
 
            case GI_TYPE_TAG_INTERFACE:
-               dwarn ("    type %p -> interface\n", type_info);
                sv_to_interface (arg_info, type_info, transfer, may_be_null,
                                 sv, arg, invocation_info);
                break;
@@ -153,7 +155,7 @@ arg_to_sv (GIArgument * arg,
        GITypeTag tag = g_type_info_get_tag (info);
        gboolean own = transfer >= GI_TRANSFER_CONTAINER;
 
-       dwarn ("  arg_to_sv: info %p with type tag %d (%s)\n",
+       dwarn ("info = %p, tag = %d (%s)\n",
               info, tag, g_type_tag_to_string (tag));
 
        switch (tag) {
@@ -164,7 +166,7 @@ arg_to_sv (GIArgument * arg,
                if (sv) {
                        SvREFCNT_inc (sv);
                }
-               dwarn ("    argument with no type information -> SV %p\n", sv);
+               dwarn ("  -> SV %p\n", sv);
                return sv ? sv : &PL_sv_undef;
            }
 
diff --git a/gperl-i11n-marshal-array.c b/gperl-i11n-marshal-array.c
index e5eb459..fca757a 100644
--- a/gperl-i11n-marshal-array.c
+++ b/gperl-i11n-marshal-array.c
@@ -37,28 +37,28 @@ _need_struct_value_semantics (GIArrayType array_type, 
GITypeInfo *param_info, GI
 static void
 _free_raw_array (gpointer raw_array)
 {
-       dwarn ("free_raw_array %p\n", raw_array);
+       dwarn ("%p\n", raw_array);
        g_free (raw_array);
 }
 
 static void
 _free_array (GArray *array)
 {
-       dwarn ("free_array %p\n", array);
+       dwarn ("%p\n", array);
        g_array_free (array, TRUE);
 }
 
 static void
 _free_ptr_array (GPtrArray *array)
 {
-       dwarn ("free_ptr_array %p\n", array);
+       dwarn ("%p\n", array);
        g_ptr_array_free (array, TRUE);
 }
 
 static void
 _free_byte_array (GByteArray *array)
 {
-       dwarn ("free_byte_array %p\n", array);
+       dwarn ("%p\n", array);
        g_byte_array_free (array, TRUE);
 }
 
@@ -80,6 +80,8 @@ array_to_sv (GITypeInfo *info,
        gssize length = -1, i;
        AV *av;
 
+       dwarn ("pointer %p\n", pointer);
+
        if (pointer == NULL) {
                return &PL_sv_undef;
        }
@@ -146,11 +148,11 @@ array_to_sv (GITypeInfo *info,
        need_struct_value_semantics =
                _need_struct_value_semantics (array_type, param_info, 
param_tag);
 
-       dwarn ("    C array: pointer %p, array %p, elements %p, "
-              "length %"G_GSSIZE_FORMAT", item size %"G_GSIZE_FORMAT", "
-              "param_info %p with type tag %d (%s)\n",
-              pointer, array, elements,
-              length, item_size,
+       dwarn ("type %d, array %p, elements %p\n",
+              array_type, array, elements);
+       dwarn ("length %"G_GSSIZE_FORMAT", item size %"G_GSIZE_FORMAT", 
param_info %p, param_tag %d (%s)\n",
+              length,
+              item_size,
               param_info,
               param_tag,
               g_type_tag_to_string (param_tag));
@@ -159,6 +161,7 @@ array_to_sv (GITypeInfo *info,
                GIArgument arg;
                SV *value;
                gpointer element = elements + ((gsize) i) * item_size;
+               dwarn ("  element %"G_GSSIZE_FORMAT": %p\n", i, element);
                if (need_struct_value_semantics) {
                        raw_to_arg (&element, &arg, param_info);
                } else {
@@ -188,6 +191,9 @@ array_to_sv (GITypeInfo *info,
 
        g_base_info_unref ((GIBaseInfo *) param_info);
 
+       dwarn ("  -> AV %p of length %"G_GSIZE_FORMAT"\n",
+              av, av_len (av) + 1);
+
        return newRV_noinc ((SV *) av);
 }
 
@@ -212,7 +218,7 @@ sv_to_array (GITransfer transfer,
        gsize item_size;
        gboolean need_struct_value_semantics;
 
-       dwarn ("%s: sv %p\n", G_STRFUNC, sv);
+       dwarn ("sv %p\n", sv);
 
        /* Add an array info entry even before the undef check so that the
         * corresponding length arg is set to zero later by
@@ -241,9 +247,11 @@ sv_to_array (GITransfer transfer,
 
        param_info = g_type_info_get_param_type (type_info, 0);
        param_tag = g_type_info_get_tag (param_info);
-       dwarn ("  GArray: param_info %p with type tag %d (%s) and transfer 
%d\n",
-              param_info, param_tag,
-              g_type_tag_to_string (g_type_info_get_tag (param_info)),
+       dwarn ("type %d, param_info %p, param_tag %d (%s), transfer %d\n",
+              array_type,
+              param_info,
+              param_tag,
+              g_type_tag_to_string (param_tag),
               transfer);
 
        need_struct_value_semantics =
@@ -270,10 +278,10 @@ sv_to_array (GITransfer transfer,
        for (i = 0; i < length; i++) {
                SV **svp;
                svp = av_fetch (av, i, 0);
+               dwarn ("  element %"G_GSIZE_FORMAT": svp = %p\n", i, svp);
                if (svp && gperl_sv_is_defined (*svp)) {
                        GIArgument arg;
 
-                       dwarn ("    converting SV %p\n", *svp);
                        /* FIXME: Is it OK to always allow undef here? */
                        sv_to_arg (*svp, &arg, NULL, param_info,
                                   item_transfer, TRUE, NULL);
@@ -301,8 +309,6 @@ sv_to_array (GITransfer transfer,
                }
        }
 
-       dwarn ("    -> array %p of size %d\n", array, array->len);
-
        if (length_pos >= 0) {
                array_info->length = length;
        }
@@ -331,5 +337,8 @@ sv_to_array (GITransfer transfer,
 
        g_base_info_unref ((GIBaseInfo *) param_info);
 
+       dwarn ("  -> array %p of length %"G_GSIZE_FORMAT"\n",
+              return_array, length);
+
        return return_array;
 }
diff --git a/gperl-i11n-marshal-callback.c b/gperl-i11n-marshal-callback.c
index 4dd5dc2..af93b63 100644
--- a/gperl-i11n-marshal-callback.c
+++ b/gperl-i11n-marshal-callback.c
@@ -12,7 +12,7 @@ sv_to_callback (GIArgInfo * arg_info,
 
        /* the destroy notify func is handled by _handle_automatic_arg */
 
-       dwarn ("      Perl callback at %d (%s)\n",
+       dwarn ("pos = %d, name = %s\n",
               invocation_info->current_pos,
               g_base_info_get_name (arg_info));
 
@@ -23,7 +23,7 @@ sv_to_callback (GIArgInfo * arg_info,
        callback_info->free_after_use = FALSE;
        g_base_info_unref (callback_interface_info);
 
-       dwarn ("      Perl callback data at %d, destroy at %d\n",
+       dwarn ("  data at %d, destroy at %d\n",
               callback_info->data_pos, callback_info->destroy_pos);
 
        scope = (!gperl_sv_is_defined (sv))
@@ -31,17 +31,17 @@ sv_to_callback (GIArgInfo * arg_info,
                : g_arg_info_get_scope (arg_info);
        switch (scope) {
            case GI_SCOPE_TYPE_CALL:
-               dwarn ("      Perl callback has scope 'call'\n");
+               dwarn ("  scope = 'call'\n");
                free_after_call (invocation_info,
                                 (GFunc) release_perl_callback, callback_info);
                break;
            case GI_SCOPE_TYPE_NOTIFIED:
-               dwarn ("      Perl callback has scope 'notified'\n");
+               dwarn ("  scope = 'notified'\n");
                /* This case is already taken care of by the notify
                 * stuff above */
                break;
            case GI_SCOPE_TYPE_ASYNC:
-               dwarn ("      Perl callback has scope 'async'\n");
+               dwarn ("  scope = 'async'\n");
                /* FIXME: callback_info->free_after_use = TRUE; */
                break;
            default:
@@ -53,7 +53,7 @@ sv_to_callback (GIArgInfo * arg_info,
                g_slist_prepend (invocation_info->callback_infos,
                                 callback_info);
 
-       dwarn ("      returning Perl closure %p from info %p\n",
+       dwarn ("  -> closure %p from info %p\n",
               callback_info->closure, callback_info);
        return callback_info->closure;
 }
@@ -68,7 +68,7 @@ sv_to_callback_data (SV * sv,
        for (l = invocation_info->callback_infos; l != NULL; l = l->next) {
                GPerlI11nPerlCallbackInfo *callback_info = l->data;
                if (callback_info->data_pos == ((gint) 
invocation_info->current_pos)) {
-                       dwarn ("      user data for Perl callback %p\n",
+                       dwarn ("user data for Perl callback %p\n",
                               callback_info);
                        attach_perl_callback_data (callback_info, sv);
                        /* If the user did not specify any code and data and if
@@ -81,7 +81,7 @@ sv_to_callback_data (SV * sv,
                            !gperl_sv_is_defined (callback_info->data) &&
                            -1 == callback_info->destroy_pos)
                        {
-                               dwarn ("        handing over NULL");
+                               dwarn ("  -> handing over NULL");
                                return NULL;
                        }
                        return callback_info;
@@ -89,7 +89,7 @@ sv_to_callback_data (SV * sv,
        }
        if (invocation_info->is_callback) {
                GPerlI11nCCallbackInfo *wrapper = INT2PTR 
(GPerlI11nCCallbackInfo*, SvIV (sv));
-               dwarn ("      user data for C callback %p\n", wrapper);
+               dwarn ("user data for C callback %p\n", wrapper);
                return wrapper->data;
        }
        return NULL;
@@ -107,7 +107,7 @@ callback_to_sv (GICallableInfo *interface, gpointer func, 
GPerlI11nInvocationInf
        for (l = invocation_info->callback_infos; l != NULL; l = l->next) {
                GPerlI11nCCallbackInfo *callback_info = l->data;
                if ((gint) invocation_info->current_pos == 
callback_info->destroy_pos) {
-                       dwarn ("      destroy notify for C callback %p\n",
+                       dwarn ("destroy notify for C callback %p\n",
                               callback_info);
                        callback_info->destroy = func;
                        /* release_c_callback is called from
@@ -119,7 +119,7 @@ callback_to_sv (GICallableInfo *interface, gpointer func, 
GPerlI11nInvocationInf
        arg_info = g_callable_info_get_arg (invocation_info->interface,
                                            (gint) 
invocation_info->current_pos);
 
-       dwarn ("      C callback at %d (%s)\n",
+       dwarn ("C callback: pos = %d, name = %s\n",
               invocation_info->current_pos,
               g_base_info_get_name (arg_info));
 
@@ -137,7 +137,7 @@ callback_to_sv (GICallableInfo *interface, gpointer func, 
GPerlI11nInvocationInf
        }
        callback_info->data_sv = data_sv;
 
-       dwarn ("      C callback data at %d, destroy at %d\n",
+       dwarn ("  data at %d, destroy at %d\n",
               callback_info->data_pos, callback_info->destroy_pos);
 
 
@@ -145,7 +145,7 @@ callback_to_sv (GICallableInfo *interface, gpointer func, 
GPerlI11nInvocationInf
                g_slist_prepend (invocation_info->callback_infos,
                                 callback_info);
 
-       dwarn ("      returning C closure %p from info %p\n",
+       dwarn ("  -> SV %p from info %p\n",
               code_sv, callback_info);
        return code_sv;
 }
@@ -160,7 +160,7 @@ callback_data_to_sv (gpointer data,
        for (l = invocation_info->callback_infos; l != NULL; l = l->next) {
                GPerlI11nCCallbackInfo *callback_info = l->data;
                if (callback_info->data_pos == (gint) 
invocation_info->current_pos) {
-                       dwarn ("      user data for C callback %p\n",
+                       dwarn ("user data for C callback %p\n",
                               callback_info);
                        attach_c_callback_data (callback_info, data);
                        return callback_info->data_sv;
@@ -168,7 +168,7 @@ callback_data_to_sv (gpointer data,
        }
        if (data && invocation_info->is_callback) {
                GPerlI11nPerlCallbackInfo *wrapper = data;
-               dwarn ("      user data for Perl callback %p\n", wrapper);
+               dwarn ("user data for Perl callback %p\n", wrapper);
                return wrapper->data;
        }
        return NULL;
diff --git a/gperl-i11n-marshal-hash.c b/gperl-i11n-marshal-hash.c
index f8f0c47..2c5f0e8 100644
--- a/gperl-i11n-marshal-hash.c
+++ b/gperl-i11n-marshal-hash.c
@@ -16,6 +16,8 @@ ghash_to_sv (GITypeInfo *info,
        GHashTableIter iter;
        HV *hv;
 
+       dwarn ("pointer = %p\n", pointer);
+
        if (pointer == NULL) {
                return &PL_sv_undef;
        }
@@ -32,10 +34,7 @@ ghash_to_sv (GITypeInfo *info,
        value_type_tag = g_type_info_get_tag (value_param_info);
 #endif
 
-       dwarn ("    GHashTable: pointer %p\n"
-              "      key type tag %d (%s)\n"
-              "      value type tag %d (%s)\n",
-              pointer,
+       dwarn ("  key tag = %d (%s), value tag = %d (%s)\n",
               key_type_tag, g_type_tag_to_string (key_type_tag),
               value_type_tag, g_type_tag_to_string (value_type_tag));
 
@@ -46,13 +45,13 @@ ghash_to_sv (GITypeInfo *info,
                GIArgument arg = { 0, };
                SV *key_sv, *value_sv;
 
-               dwarn ("      converting key pointer %p\n", key_p);
+               dwarn ("  key pointer %p\n", key_p);
                arg.v_pointer = key_p;
                key_sv = arg_to_sv (&arg, key_param_info, item_transfer, NULL);
                if (key_sv == NULL)
                         break;
 
-               dwarn ("      converting value pointer %p\n", value_p);
+               dwarn ("  value pointer %p\n", value_p);
                arg.v_pointer = value_p;
                value_sv = arg_to_sv (&arg, value_param_info, item_transfer, 
NULL);
                if (value_sv == NULL)
@@ -82,7 +81,7 @@ sv_to_ghash (GITransfer transfer,
        GEqualFunc equal_func;
        I32 n_keys;
 
-       dwarn ("%s: sv %p\n", G_STRFUNC, sv);
+       dwarn ("sv = %p\n", sv);
 
        if (!gperl_sv_is_defined (sv))
                return NULL;
@@ -123,9 +122,7 @@ sv_to_ghash (GITransfer transfer,
                break;
        }
 
-       dwarn ("  GHashTable with transfer %d\n"
-              "    key_param_info %p with type tag %d (%s)\n"
-              "    value_param_info %p with type tag %d (%s)\n",
+       dwarn ("  transfer = %d, key info = %p, key tag = %d (%s), value info = 
%p, value tag = %d (%s)\n",
               transfer,
               key_param_info,
               g_type_info_get_tag (key_param_info),
@@ -148,8 +145,8 @@ sv_to_ghash (GITransfer transfer,
                key_p = value_p = NULL;
 
                sv = hv_iterkeysv (he);
+               dwarn ("  key SV %p\n", sv);
                if (sv && gperl_sv_is_defined (sv)) {
-                       dwarn ("    converting key SV %p\n", sv);
                        /* FIXME: Is it OK to always allow undef here? */
                        sv_to_arg (sv, &arg, NULL, key_param_info,
                                   item_transfer, TRUE, NULL);
@@ -157,8 +154,8 @@ sv_to_ghash (GITransfer transfer,
                }
 
                sv = hv_iterval (hv, he);
+               dwarn ("  value SV %p\n", sv);
                if (sv && gperl_sv_is_defined (sv)) {
-                       dwarn ("    converting value SV %p\n", sv);
                        sv_to_arg (sv, &arg, NULL, key_param_info,
                                   item_transfer, TRUE, NULL);
                        value_p = arg.v_pointer;
@@ -169,7 +166,7 @@ sv_to_ghash (GITransfer transfer,
        }
 
 out:
-       dwarn ("    -> hash %p of size %d\n", hash, g_hash_table_size (hash));
+       dwarn ("  -> hash %p of size %d\n", hash, g_hash_table_size (hash));
 
        g_base_info_unref ((GIBaseInfo *) key_param_info);
        g_base_info_unref ((GIBaseInfo *) value_param_info);
diff --git a/gperl-i11n-marshal-interface.c b/gperl-i11n-marshal-interface.c
index dedee79..93c1ce2 100644
--- a/gperl-i11n-marshal-interface.c
+++ b/gperl-i11n-marshal-interface.c
@@ -13,15 +13,15 @@ instance_sv_to_pointer (GICallableInfo *info, SV *sv)
 
        /* FIXME: Much of this code is duplicated in sv_to_interface. */
 
-       dwarn ("  instance_sv_to_pointer: container name: %s, info type: %d\n",
+       dwarn ("container name = %s, info type = %d (%s)\n",
               g_base_info_get_name (container),
-              info_type);
+              info_type, g_info_type_to_string (info_type));
 
        switch (info_type) {
            case GI_INFO_TYPE_OBJECT:
            case GI_INFO_TYPE_INTERFACE:
                pointer = gperl_get_object (sv);
-               dwarn ("    -> object pointer: %p\n", pointer);
+               dwarn ("  -> object pointer: %p\n", pointer);
                break;
 
            case GI_INFO_TYPE_BOXED:
@@ -30,22 +30,22 @@ instance_sv_to_pointer (GICallableInfo *info, SV *sv)
            {
                GType type = get_gtype ((GIRegisteredTypeInfo *) container);
                if (!type || type == G_TYPE_NONE) {
-                       dwarn ("    unboxed type\n");
+                       dwarn ("  -> untyped record\n");
                        pointer = sv_to_struct (GI_TRANSFER_NOTHING,
                                                container,
                                                info_type,
                                                sv);
                } else {
-                       dwarn ("    boxed type: %s (%"G_GSIZE_FORMAT")\n",
+                       dwarn ("  -> boxed: type=%s (%"G_GSIZE_FORMAT")\n",
                               g_type_name (type), type);
                        pointer = gperl_get_boxed_check (sv, type);
                }
-               dwarn ("    -> boxed pointer: %p\n", pointer);
+               dwarn ("  -> record pointer: %p\n", pointer);
                break;
            }
 
            default:
-               ccroak ("instance_sv_to_pointer: Don't know how to handle info 
type %d", info_type);
+               ccroak ("Don't know how to handle info type %d for instance 
SV", info_type);
        }
 
        return pointer;
@@ -64,15 +64,15 @@ instance_pointer_to_sv (GICallableInfo *info, gpointer 
pointer)
 
        /* FIXME: Much of this code is duplicated in interface_to_sv. */
 
-       dwarn ("  instance_pointer_to_sv: container name: %s, info type: %d\n",
+       dwarn ("container name = %s, info type = %d (%s)\n",
               g_base_info_get_name (container),
-              info_type);
+              info_type, g_info_type_to_string (info_type));
 
        switch (info_type) {
            case GI_INFO_TYPE_OBJECT:
            case GI_INFO_TYPE_INTERFACE:
                sv = gperl_new_object (pointer, FALSE);
-               dwarn ("    -> object SV: %p\n", sv);
+               dwarn ("  -> object SV: %p\n", sv);
                break;
 
            case GI_INFO_TYPE_BOXED:
@@ -81,19 +81,19 @@ instance_pointer_to_sv (GICallableInfo *info, gpointer 
pointer)
            {
                GType type = get_gtype ((GIRegisteredTypeInfo *) container);
                if (!type || type == G_TYPE_NONE) {
-                       dwarn ("    unboxed type\n");
+                       dwarn ("  -> untyped record\n");
                        sv = struct_to_sv (container, info_type, pointer, 
FALSE);
                } else {
-                       dwarn ("    boxed type: %s (%"G_GSIZE_FORMAT")\n",
+                       dwarn ("  -> boxed: type=%s (%"G_GSIZE_FORMAT")\n",
                               g_type_name (type), type);
                        sv = gperl_new_boxed (pointer, type, FALSE);
                }
-               dwarn ("    -> boxed pointer: %p\n", pointer);
+               dwarn ("  -> record pointer: %p\n", pointer);
                break;
            }
 
            default:
-               ccroak ("instance_pointer_to_sv: Don't know how to handle info 
type %d", info_type);
+               ccroak ("Don't know how to handle info type %d for instance 
pointer", info_type);
        }
 
        return sv;
@@ -116,8 +116,9 @@ sv_to_interface (GIArgInfo * arg_info,
                ccroak ("Could not convert sv %p to pointer", sv);
        info_type = g_base_info_get_type (interface);
 
-       dwarn ("    interface %p (%s) of type %d\n",
-              interface, g_base_info_get_name (interface), info_type);
+       dwarn ("interface = %p (%s), type = %d (%s)\n",
+              interface, g_base_info_get_name (interface),
+              info_type, g_info_type_to_string (info_type));
 
        switch (info_type) {
            case GI_INFO_TYPE_OBJECT:
@@ -155,7 +156,7 @@ sv_to_interface (GIArgInfo * arg_info,
                if (!type || type == G_TYPE_NONE) {
                        const gchar *namespace, *name, *package;
                        GType parent_type;
-                       dwarn ("    untyped record\n");
+                       dwarn ("  -> untyped record\n");
                        g_assert (!need_value_semantics);
                        /* Find out whether this untyped record is a member of
                         * a boxed union before using raw hash-to-struct
@@ -181,14 +182,14 @@ sv_to_interface (GIArgInfo * arg_info,
 
                else if (type == G_TYPE_CLOSURE) {
                        /* FIXME: User cannot supply user data. */
-                       dwarn ("    closure type\n");
+                       dwarn ("  -> closure\n");
                        g_assert (!need_value_semantics);
                        arg->v_pointer = gperl_closure_new (sv, NULL, FALSE);
                }
 
                else if (type == G_TYPE_VALUE) {
                        GValue *gvalue = SvGValueWrapper (sv);
-                       dwarn ("    value type\n");
+                       dwarn ("  -> value\n");
                        if (!gvalue)
                                ccroak ("Cannot convert arbitrary SV to 
GValue");
                        if (need_value_semantics) {
@@ -206,7 +207,7 @@ sv_to_interface (GIArgInfo * arg_info,
                }
 
                else if (g_type_is_a (type, G_TYPE_BOXED)) {
-                       dwarn ("    boxed type: %s, name=%s, 
caller-allocates=%d, is-pointer=%d\n",
+                       dwarn ("  -> boxed: type=%s, name=%s, 
caller-allocates=%d, is-pointer=%d\n",
                               g_type_name (type),
                               g_base_info_get_name (interface),
                               g_arg_info_is_caller_allocates (arg_info),
@@ -233,7 +234,7 @@ sv_to_interface (GIArgInfo * arg_info,
 
 #if GLIB_CHECK_VERSION (2, 24, 0)
                else if (g_type_is_a (type, G_TYPE_VARIANT)) {
-                       dwarn ("    variant type\n");
+                       dwarn ("  -> variant type\n");
                        g_assert (!need_value_semantics);
                        arg->v_pointer = SvGVariant (sv);
                        if (GI_TRANSFER_EVERYTHING == transfer)
@@ -298,14 +299,14 @@ interface_to_sv (GITypeInfo* info, GIArgument *arg, 
gboolean own, GPerlI11nInvoc
        GIInfoType info_type;
        SV *sv = NULL;
 
-       dwarn ("  interface_to_sv: arg %p, info %p\n",
-              arg, info);
+       dwarn ("arg %p, info %p\n", arg, info);
 
        interface = g_type_info_get_interface (info);
        if (!interface)
                ccroak ("Could not convert arg %p to SV", arg);
        info_type = g_base_info_get_type (interface);
-       dwarn ("    info type: %d (%s)\n", info_type, g_info_type_to_string 
(info_type));
+       dwarn ("  info type: %d (%s)\n",
+              info_type, g_info_type_to_string (info_type));
 
        switch (info_type) {
            case GI_INFO_TYPE_OBJECT:
@@ -321,26 +322,26 @@ interface_to_sv (GITypeInfo* info, GIArgument *arg, 
gboolean own, GPerlI11nInvoc
                GType type;
                type = get_gtype ((GIRegisteredTypeInfo *) interface);
                if (!type || type == G_TYPE_NONE) {
-                       dwarn ("    untyped record\n");
+                       dwarn ("  -> untyped record\n");
                        sv = struct_to_sv (interface, info_type, 
arg->v_pointer, own);
                }
 
                else if (type == G_TYPE_VALUE) {
-                       dwarn ("    value type\n");
+                       dwarn ("  -> value\n");
                        sv = gperl_sv_from_value (arg->v_pointer);
                        if (own)
                                g_boxed_free (type, arg->v_pointer);
                }
 
                else if (g_type_is_a (type, G_TYPE_BOXED)) {
-                       dwarn ("    boxed type: %"G_GSIZE_FORMAT" (%s)\n",
+                       dwarn ("  -> boxed: type=%"G_GSIZE_FORMAT" (%s)\n",
                               type, g_type_name (type));
                        sv = gperl_new_boxed (arg->v_pointer, type, own);
                }
 
 #if GLIB_CHECK_VERSION (2, 24, 0)
                else if (g_type_is_a (type, G_TYPE_VARIANT)) {
-                       dwarn ("    variant type\n");
+                       dwarn ("  -> variant\n");
                        sv = own ? newSVGVariant_noinc (arg->v_pointer)
                                 : newSVGVariant (arg->v_pointer);
                }
diff --git a/gperl-i11n-marshal-list.c b/gperl-i11n-marshal-list.c
index 64a79b8..41c370d 100644
--- a/gperl-i11n-marshal-list.c
+++ b/gperl-i11n-marshal-list.c
@@ -3,14 +3,14 @@
 static void
 free_list (GList *list)
 {
-       dwarn ("free_list %p\n", list);
+       dwarn ("%p\n", list);
        g_list_free (list);
 }
 
 static void
 free_slist (GSList *list)
 {
-       dwarn ("free_slist %p\n", list);
+       dwarn ("%p\n", list);
        g_slist_free (list);
 }
 
@@ -40,7 +40,7 @@ glist_to_sv (GITypeInfo* info,
                : GI_TRANSFER_NOTHING;
 
        param_info = g_type_info_get_param_type (info, 0);
-       dwarn ("    G(S)List: pointer %p, param_info %p with type tag %d 
(%s)\n",
+       dwarn ("pointer = %p, param_info = %p, param tag = %d (%s)\n",
               pointer,
               param_info,
               g_type_info_get_tag (param_info),
@@ -51,7 +51,7 @@ glist_to_sv (GITypeInfo* info,
        av = newAV ();
        for (i = pointer; i; i = i->next) {
                GIArgument arg = {0,};
-               dwarn ("      converting pointer %p\n", i->data);
+               dwarn ("  element %p: %p\n", i, i->data);
                arg.v_pointer = i->data;
                value = arg_to_sv (&arg, param_info, item_transfer, NULL);
                if (value)
@@ -67,6 +67,8 @@ glist_to_sv (GITypeInfo* info,
 
        g_base_info_unref ((GIBaseInfo *) param_info);
 
+       dwarn ("  -> AV = %p, length = %ld\n", av, av_len (av) + 1);
+
        return newRV_noinc ((SV *) av);
 }
 
@@ -80,7 +82,7 @@ sv_to_glist (GITransfer transfer, GITypeInfo * type_info, SV 
* sv, GPerlI11nInvo
        gboolean is_slist;
        gint i, length;
 
-       dwarn ("%s: sv %p\n", G_STRFUNC, sv);
+       dwarn ("sv = %p\n", sv);
 
        if (!gperl_sv_is_defined (sv))
                return NULL;
@@ -94,7 +96,7 @@ sv_to_glist (GITransfer transfer, GITypeInfo * type_info, SV 
* sv, GPerlI11nInvo
                : GI_TRANSFER_NOTHING;
 
        param_info = g_type_info_get_param_type (type_info, 0);
-       dwarn ("  G(S)List: param_info %p with type tag %d (%s) and transfer 
%d\n",
+       dwarn ("  param_info = %p, param tag = %d (%s), transfer = %d\n",
               param_info,
               g_type_info_get_tag (param_info),
               g_type_tag_to_string (g_type_info_get_tag (param_info)),
@@ -106,9 +108,9 @@ sv_to_glist (GITransfer transfer, GITypeInfo * type_info, 
SV * sv, GPerlI11nInvo
        for (i = 0; i < length; i++) {
                SV **svp;
                svp = av_fetch (av, i, 0);
+               dwarn ("  element %d: svp = %p\n", i, svp);
                if (svp && gperl_sv_is_defined (*svp)) {
                        GIArgument arg;
-                       dwarn ("    converting SV %p\n", *svp);
                        /* FIXME: Is it OK to always allow undef here? */
                        sv_to_arg (*svp, &arg, NULL, param_info,
                                   item_transfer, TRUE, NULL);
@@ -126,7 +128,7 @@ sv_to_glist (GITransfer transfer, GITypeInfo * type_info, 
SV * sv, GPerlI11nInvo
                                 is_slist ? ((GFunc)free_slist) : 
((GFunc)free_list),
                                 list);
 
-       dwarn ("    -> list %p of length %d\n", list, g_list_length (list));
+       dwarn ("  -> list = %p, length = %d\n", list, g_list_length (list));
 
        g_base_info_unref ((GIBaseInfo *) param_info);
 
diff --git a/gperl-i11n-marshal-struct.c b/gperl-i11n-marshal-struct.c
index e4ff30e..51c8298 100644
--- a/gperl-i11n-marshal-struct.c
+++ b/gperl-i11n-marshal-struct.c
@@ -30,7 +30,7 @@ struct_to_sv (GIBaseInfo* info,
 {
        HV *hv;
 
-       dwarn ("%s: pointer %p\n", G_STRFUNC, pointer);
+       dwarn ("pointer = %p\n", pointer);
 
        if (pointer == NULL) {
                return &PL_sv_undef;
@@ -62,6 +62,7 @@ struct_to_sv (GIBaseInfo* info,
                        SV *sv;
                        field_info =
                                g_struct_info_get_field ((GIStructInfo *) info, 
i);
+                       dwarn ("  field %d (%s)\n", i, g_base_info_get_name 
(field_info));
                        /* FIXME: Check GIFieldInfoFlags. */
                        /* FIXME: Is it right to use GI_TRANSFER_NOTHING
                         * here? */
@@ -105,7 +106,7 @@ sv_to_struct (GITransfer transfer,
        GITransfer field_transfer;
        gpointer pointer = NULL;
 
-       dwarn ("%s: sv %p\n", G_STRFUNC, sv);
+       dwarn ("sv = %p\n", sv);
 
        if (!gperl_sv_is_defined (sv))
                return NULL;
@@ -139,10 +140,10 @@ sv_to_struct (GITransfer transfer,
                g_assert_not_reached ();
        }
 
-       dwarn ("  size: %"G_GSIZE_FORMAT"\n", size);
+       dwarn ("  size = %"G_GSIZE_FORMAT"\n", size);
 
        field_transfer = GI_TRANSFER_NOTHING;
-       dwarn ("  transfer: %d\n", transfer);
+       dwarn ("  transfer = %d\n", transfer);
        switch (transfer) {
            case GI_TRANSFER_EVERYTHING:
                field_transfer = GI_TRANSFER_EVERYTHING;
@@ -173,6 +174,7 @@ sv_to_struct (GITransfer transfer,
                        /* FIXME: Check GIFieldInfoFlags. */
                        field_name = g_base_info_get_name (
                                       (GIBaseInfo *) field_info);
+                       dwarn ("  field %d (%s)\n", i, field_name);
                        svp = hv_fetch (hv, field_name, strlen (field_name), 0);
                        if (svp && gperl_sv_is_defined (*svp)) {
                                set_field (field_info, pointer,
diff --git a/gperl-i11n-union.c b/gperl-i11n-union.c
index 60d1bbf..b62210d 100644
--- a/gperl-i11n-union.c
+++ b/gperl-i11n-union.c
@@ -55,8 +55,8 @@ associate_union_members_with_gtype (GIUnionInfo *info, const 
gchar *package, GTy
 
                type_name = g_base_info_get_name (field_interface);
                full_name = g_strconcat (package, "::", type_name, 
UNION_MEMBER_TYPE_SUFFIX, NULL);
-               dwarn ("associating %s with GType %"G_GSIZE_FORMAT"\n",
-                      type_name, type);
+               dwarn ("%s::%s => %"G_GSIZE_FORMAT" (%s)\n",
+                      package, type_name, type, g_type_name (type));
                sv = get_sv (full_name, GV_ADD);
                sv_setuv (sv, type);
                g_free (full_name);
diff --git a/gperl-i11n-vfunc-interface.c b/gperl-i11n-vfunc-interface.c
index d66aa5d..9c7d8ec 100644
--- a/gperl-i11n-vfunc-interface.c
+++ b/gperl-i11n-vfunc-interface.c
@@ -42,7 +42,7 @@ generic_interface_init (gpointer iface, gpointer data)
                /* callback_info takes over ownership of perl_method_name. */
                callback_info = create_perl_callback_closure_for_named_sub (
                                  field_interface_info, perl_method_name);
-               dwarn ("generic_interface_init: installing vfunc %s.%s as %s at 
offset %d (vs. %d) inside %p\n",
+               dwarn ("installing vfunc %s.%s as %s at offset %d (vs. %d) 
inside %p\n",
                       g_base_info_get_name (info), vfunc_name, 
perl_method_name,
                       field_offset, g_vfunc_info_get_offset (vfunc_info),
                       iface);
@@ -61,6 +61,6 @@ generic_interface_finalize (gpointer iface, gpointer data)
 {
        GIInterfaceInfo *info = data;
        PERL_UNUSED_VAR (iface);
-       dwarn ("releasing interface info\n");
+       dwarn ("info = %p\n", info);
        g_base_info_unref ((GIBaseInfo *) info);
 }
diff --git a/gperl-i11n-vfunc-object.c b/gperl-i11n-vfunc-object.c
index 6e3f48f..2f9be47 100644
--- a/gperl-i11n-vfunc-object.c
+++ b/gperl-i11n-vfunc-object.c
@@ -48,7 +48,7 @@ generic_class_init (GIObjectInfo *info, const gchar 
*target_package, gpointer cl
                        HV * stash = gv_stashpv (target_package, 0);
                        GV * slot = gv_fetchmethod (stash, perl_method_name);
                        if (!slot) {
-                               dwarn ("generic_class_init: skipping vfunc 
%s.%s because it has no implementation\n",
+                               dwarn ("skipping vfunc %s.%s because it has no 
implementation\n",
                                      g_base_info_get_name (info), vfunc_name);
                                g_base_info_unref (vfunc_info);
                                g_free (perl_method_name);
@@ -68,7 +68,7 @@ generic_class_init (GIObjectInfo *info, const gchar 
*target_package, gpointer cl
                /* callback_info takes over ownership of perl_method_name. */
                callback_info = create_perl_callback_closure_for_named_sub (
                                  field_interface_info, perl_method_name);
-               dwarn ("generic_class_init: installing vfunc %s.%s as %s at 
offset %d (vs. %d) inside %p\n",
+               dwarn ("installing vfunc %s.%s as %s at offset %d (vs. %d) 
inside %p\n",
                       g_base_info_get_name (info), vfunc_name, 
perl_method_name,
                       field_offset, g_vfunc_info_get_offset (vfunc_info),
                       class);

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/pkg-perl/packages/libglib-object-introspection-perl.git

_______________________________________________
Pkg-perl-cvs-commits mailing list
Pkg-perl-cvs-commits@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-perl-cvs-commits

Reply via email to