Sha256: 38730595122c48769e33f7a4c4dd81bcd8f3aaea305b55c7c44703b7a7c86b41

Contents?: true

Size: 462 Bytes

Versions: 9

Compression:

Stored size: 462 Bytes

Contents

module GirFFI
  module InfoExt
    # Extensions for GObjectIntrospection::IFunctionInfo needed by GirFFI
    module IFunctionInfo
      def argument_ffi_types
        super.tap do |types|
          types.unshift :pointer if method?
          types << :pointer if throws?
        end
      end

      def return_ffi_type
        return_type.to_ffitype
      end
    end
  end
end

GObjectIntrospection::IFunctionInfo.send :include, GirFFI::InfoExt::IFunctionInfo

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
gir_ffi-0.7.8 lib/gir_ffi/info_ext/i_function_info.rb
gir_ffi-0.7.7 lib/gir_ffi/info_ext/i_function_info.rb
gir_ffi-0.7.6 lib/gir_ffi/info_ext/i_function_info.rb
gir_ffi-0.7.5 lib/gir_ffi/info_ext/i_function_info.rb
gir_ffi-0.7.4 lib/gir_ffi/info_ext/i_function_info.rb
gir_ffi-0.7.3 lib/gir_ffi/info_ext/i_function_info.rb
gir_ffi-0.7.2 lib/gir_ffi/info_ext/i_function_info.rb
gir_ffi-0.7.1 lib/gir_ffi/info_ext/i_function_info.rb
gir_ffi-0.7.0 lib/gir_ffi/info_ext/i_function_info.rb