[gobject-introspection] girepository: ArgBlob: rename allow_none parameter



commit 3ede3b8f9e038cde4a731e9e56c4060961d74ef8
Author: Ryan Lortie <desrt desrt ca>
Date:   Wed Apr 16 11:33:36 2014 -0400

    girepository: ArgBlob: rename allow_none parameter
    
    Rename the "allow_none" parameter on internal/private structure ArgBlob
    to "nullable".
    
    This is a straight rename with no other changes.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=660879

 girepository/giarginfo.c          |    2 +-
 girepository/girnode.c            |   10 +++++-----
 girepository/girnode.h            |    2 +-
 girepository/girparser.c          |    4 ++--
 girepository/gitypelib-internal.h |    4 ++--
 5 files changed, 11 insertions(+), 11 deletions(-)
---
diff --git a/girepository/giarginfo.c b/girepository/giarginfo.c
index 572839c..c96976a 100644
--- a/girepository/giarginfo.c
+++ b/girepository/giarginfo.c
@@ -162,7 +162,7 @@ g_arg_info_may_be_null (GIArgInfo *info)
 
   blob = (ArgBlob *)&rinfo->typelib->data[rinfo->offset];
 
-  return blob->allow_none;
+  return blob->nullable;
 }
 
 /**
diff --git a/girepository/girnode.c b/girepository/girnode.c
index 093a378..53385c2 100644
--- a/girepository/girnode.c
+++ b/girepository/girnode.c
@@ -1660,7 +1660,7 @@ _g_ir_node_build_typelib (GIrNode         *node,
         _g_ir_node_build_typelib ((GIrNode *)function->result->type,
                                 node, build, &signature, offset2);
 
-       blob2->may_return_null = function->result->allow_none;
+       blob2->may_return_null = function->result->nullable;
        blob2->caller_owns_return_value = function->result->transfer;
        blob2->caller_owns_return_container = function->result->shallow_transfer;
        blob2->skip_return = function->result->skip;
@@ -1702,7 +1702,7 @@ _g_ir_node_build_typelib (GIrNode         *node,
         _g_ir_node_build_typelib ((GIrNode *)function->result->type,
                                 node, build, &signature, offset2);
 
-       blob2->may_return_null = function->result->allow_none;
+       blob2->may_return_null = function->result->nullable;
        blob2->caller_owns_return_value = function->result->transfer;
        blob2->caller_owns_return_container = function->result->shallow_transfer;
        blob2->reserved = 0;
@@ -1759,7 +1759,7 @@ _g_ir_node_build_typelib (GIrNode         *node,
         _g_ir_node_build_typelib ((GIrNode *)signal->result->type,
                                 node, build, &signature, offset2);
 
-       blob2->may_return_null = signal->result->allow_none;
+       blob2->may_return_null = signal->result->nullable;
        blob2->caller_owns_return_value = signal->result->transfer;
        blob2->caller_owns_return_container = signal->result->shallow_transfer;
        blob2->reserved = 0;
@@ -1817,7 +1817,7 @@ _g_ir_node_build_typelib (GIrNode         *node,
         _g_ir_node_build_typelib ((GIrNode *)vfunc->result->type,
                                 node, build, &signature, offset2);
 
-       blob2->may_return_null = vfunc->result->allow_none;
+       blob2->may_return_null = vfunc->result->nullable;
        blob2->caller_owns_return_value = vfunc->result->transfer;
        blob2->caller_owns_return_container = vfunc->result->shallow_transfer;
        blob2->reserved = 0;
@@ -1848,7 +1848,7 @@ _g_ir_node_build_typelib (GIrNode         *node,
        blob->in = param->in;
        blob->out = param->out;
        blob->caller_allocates = param->caller_allocates;
-       blob->allow_none = param->allow_none;
+       blob->nullable = param->nullable;
        blob->skip = param->skip;
        blob->optional = param->optional;
        blob->transfer_ownership = param->transfer;
diff --git a/girepository/girnode.h b/girepository/girnode.h
index 07b084c..4beef7f 100644
--- a/girepository/girnode.h
+++ b/girepository/girnode.h
@@ -146,7 +146,7 @@ struct _GIrNodeParam
   gboolean caller_allocates;
   gboolean optional;
   gboolean retval;
-  gboolean allow_none;
+  gboolean nullable;
   gboolean skip;
   gboolean transfer;
   gboolean shallow_transfer;
diff --git a/girepository/girparser.c b/girepository/girparser.c
index c7feb6a..ac21f6a 100644
--- a/girepository/girparser.c
+++ b/girepository/girparser.c
@@ -1127,9 +1127,9 @@ start_parameter (GMarkupParseContext *context,
     param->optional = FALSE;
 
   if (allow_none && strcmp (allow_none, "1") == 0)
-    param->allow_none = TRUE;
+    param->nullable = TRUE;
   else
-    param->allow_none = FALSE;
+    param->nullable = FALSE;
 
   if (skip && strcmp (skip, "1") == 0)
     param->skip = TRUE;
diff --git a/girepository/gitypelib-internal.h b/girepository/gitypelib-internal.h
index 23f4d62..93d621b 100644
--- a/girepository/gitypelib-internal.h
+++ b/girepository/gitypelib-internal.h
@@ -396,7 +396,7 @@ typedef union _SimpleTypeBlob SimpleTypeBlob;
  *   parameter, the function actually takes an uint32*.
  * @caller_allocates: The parameter is a pointer to a struct or object that
  *   will receive an output of the function.
- * @allow_none: Only meaningful for types which are passed as pointers. For an
+ * @nullable: Only meaningful for types which are passed as pointers. For an
  *   in parameter, indicates if it is ok to pass NULL in. Gor an out
  *   parameter, indicates whether it may return NULL. Note that NULL is a
  *   valid GList and GSList value, thus allow_none will normally be set
@@ -437,7 +437,7 @@ typedef struct {
   guint          in                           : 1;
   guint          out                          : 1;
   guint          caller_allocates             : 1;
-  guint          allow_none                   : 1;
+  guint          nullable                     : 1;
   guint          optional                     : 1;
   guint          transfer_ownership           : 1;
   guint          transfer_container_ownership : 1;


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