diff options
author | Colin Walters <walters@verbum.org> | 2012-02-16 16:58:59 -0500 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2012-03-05 09:56:56 -0500 |
commit | c2fc7cb45243aa9e0e1e5569cc742f69c76a671a (patch) | |
tree | 7f9c5d292a4e71446d6071b7bb235383ba9ca989 /girepository/girffi.h | |
parent | bf71aba06ccbd3ae4b49133724389cf76108f6d9 (diff) | |
download | gobject-introspection-c2fc7cb45243aa9e0e1e5569cc742f69c76a671a.tar.gz |
repository: Add new public gi_type_info_extract_ffi_return_value() API
Dealing with FFI and return values is very tricky; this API allows
sharing the bits to do it between gobject-introspection and gjs (and
potentially other FFI binding consumers).
**NOTE** I swapped the order of the arguments, under the premise that
out arguments should generally be last.
https://bugzilla.gnome.org/show_bug.cgi?id=668902
Diffstat (limited to 'girepository/girffi.h')
-rw-r--r-- | girepository/girffi.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/girepository/girffi.h b/girepository/girffi.h index e976f924..56caff73 100644 --- a/girepository/girffi.h +++ b/girepository/girffi.h @@ -46,10 +46,16 @@ struct _GIFunctionInvoker { gpointer padding[3]; }; +typedef GIArgument GIFFIReturnValue; + ffi_type * gi_type_tag_get_ffi_type (GITypeTag type_tag, gboolean is_pointer); ffi_type * g_type_info_get_ffi_type (GITypeInfo *info); +void gi_type_info_extract_ffi_return_value (GITypeInfo *return_info, + GIFFIReturnValue *ffi_value, + GIArgument *arg); + gboolean g_function_info_prep_invoker (GIFunctionInfo *info, GIFunctionInvoker *invoker, GError **error); |