るりまサーチ

最速Rubyリファレンスマニュアル検索!
11件ヒット [1-11件を表示] (0.107秒)
トップページ > 種類:インスタンスメソッド[x] > クエリ:Float[x] > クラス:Fiddle::Function[x]

別のキーワード

  1. _builtin float
  2. float to_d
  3. json float
  4. float rationalize
  5. fiddle type_float

ライブラリ

検索結果

Fiddle::Function#call(*args) -> Integer|DL::CPtr|nil (8.0)

関数を呼び出します。

...関数を呼び出します。

Fiddle::Function
.new で指定した引数と返り値の型に基いて
Ruby のオブジェクトを適切に C のデータに変換して C の関数を呼び出し、
その返り値を Ruby のオブジェクトに変換して返します。

引数の変換は...
...
アドレスと見なします

: (unsigned) char/short/int/long/long long
Ruby の整数を C の整数に変換します。

: double/float
Ruby の整数 or 浮動小数点数を C の浮動小数点数に変換します

返り値の変換は以下の通りです。

: void
nil...
...を返します

: (unsigned) char/short/int/long/long long
C の整数を Ruby の整数に変換します

: void*(つまり任意のポインタ型)
C のポインタを保持した Fiddle::Pointer を返します。

@param args 関数の引数
@see Fiddle::Function.new...