summaryrefslogtreecommitdiff
path: root/girepository/ginfo.c
diff options
context:
space:
mode:
authorMark Lee <marklee@src.gnome.org>2009-06-19 16:53:03 -0700
committerColin Walters <walters@verbum.org>2009-06-22 14:01:56 -0400
commit7048d711b2787af81767bb472f5dbaf0f97d6db9 (patch)
tree1f5635988ec08dd7020c947e02f58cb32def5c90 /girepository/ginfo.c
parent94bae77228d816a308c054357125713b746b687c (diff)
downloadgobject-introspection-7048d711b2787af81767bb472f5dbaf0f97d6db9.tar.gz
Bug 584423 – Add short/ushort support
Add type tags for short and ushort, plus all of the requisite code needed to utilize them in libgirepository. Add support in the scanner's AST files. Add test functions to the everything library and the expected gir file. gtypelib.c constant validation fixed by Colin Walters <walters@verbum.org>
Diffstat (limited to 'girepository/ginfo.c')
-rw-r--r--girepository/ginfo.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/girepository/ginfo.c b/girepository/ginfo.c
index d522a565..6fbd464f 100644
--- a/girepository/ginfo.c
+++ b/girepository/ginfo.c
@@ -2091,6 +2091,12 @@ g_constant_info_get_value (GIConstantInfo *info,
case GI_TYPE_TAG_TIME_T:
value->v_long = *(long*)&base->typelib->data[blob->offset];
break;
+ case GI_TYPE_TAG_SHORT:
+ value->v_short = *(gshort*)&base->typelib->data[blob->offset];
+ break;
+ case GI_TYPE_TAG_USHORT:
+ value->v_ushort = *(gushort*)&base->typelib->data[blob->offset];
+ break;
case GI_TYPE_TAG_INT:
value->v_int = *(gint*)&base->typelib->data[blob->offset];
break;