るりまサーチ (Ruby 3.1)

最速Rubyリファレンスマニュアル検索!
10件ヒット [1-10件を表示] (0.058秒)
トップページ > クエリ:b[x] > バージョン:3.1[x] > クエリ:TYPE[x] > モジュール:Kernel[x]

別のキーワード

  1. string b
  2. _builtin b
  3. b
  4. b string
  5. b _builtin

ライブラリ

キーワード

検索結果

Kernel#convertible_int(type, headers = nil, opts = nil) (19234.0)

Returns the convertible integer type of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. _Convertible_ means actually same type, or typedefed from same type. If the +type+ is a integer type and _convertible_ type is found, following macros are passed as preprocessor constants to the compiler using the +type+ name, in uppercase. * 'TYPEOF_', followed by the +type+ name, followed by '=X' where 'X' is the found _convertible_ type name. * 'TYP2NUM' and 'NUM2TYP, where 'TYP' is the +type+ name in uppercase with replacing '_t' suffix with 'T', followed by '=X' where 'X' is the macro name to convert +type+ to +Integer+ object, and vice versa. For example, if foobar_t is defined as unsigned long, then convertible_int("foobar_t") would return "unsigned long", and define macros: #define TYPEOF_FOOBAR_T unsigned long #define FOOBART2NUM ULONG2NUM #define NUM2FOOBART NUM2ULONG

Returns the convertible integer type of the given +type+. You may
optionally specify additional +headers+ to search in for the +type+.
_Convertible_ means actually same type, or typedefed from same type.

If the +type+ is a integer type and _convertible_ type is found,
following macros are p...

Kernel#convertible_int(type, headers = nil, opts = nil) { ... } (19234.0)

Returns the convertible integer type of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. _Convertible_ means actually same type, or typedefed from same type. If the +type+ is a integer type and _convertible_ type is found, following macros are passed as preprocessor constants to the compiler using the +type+ name, in uppercase. * 'TYPEOF_', followed by the +type+ name, followed by '=X' where 'X' is the found _convertible_ type name. * 'TYP2NUM' and 'NUM2TYP, where 'TYP' is the +type+ name in uppercase with replacing '_t' suffix with 'T', followed by '=X' where 'X' is the macro name to convert +type+ to +Integer+ object, and vice versa. For example, if foobar_t is defined as unsigned long, then convertible_int("foobar_t") would return "unsigned long", and define macros: #define TYPEOF_FOOBAR_T unsigned long #define FOOBART2NUM ULONG2NUM #define NUM2FOOBART NUM2ULONG

Returns the convertible integer type of the given +type+. You may
optionally specify additional +headers+ to search in for the +type+.
_Convertible_ means actually same type, or typedefed from same type.

If the +type+ is a integer type and _convertible_ type is found,
following macros are p...

Kernel#have_type(type, headers = nil, opt = "") -> bool (19072.0)

静的な型 type がシステムに存在するかどうか検査します。

静的な型 type がシステムに存在するかどうか検査します。

型 type がシステムに存在する場合は、グローバル変数 $defs に
"-DHAVE_type" を追加し、真を返します。型 type がシステムに存在しない場
合は、偽を返します。

例えば、

require 'mkmf'
have_type('foo') # => true

である場合、HAVE_TYPE_FOO をというプリプロセッサマクロをコンパイラに渡します。

@param type 検査したい型の名前を指定します。

@param headers 追加のヘッダを指定します。

@param opt ...

Kernel#have_type(type, headers = nil, opt = "") { ... } -> bool (19072.0)

静的な型 type がシステムに存在するかどうか検査します。

静的な型 type がシステムに存在するかどうか検査します。

型 type がシステムに存在する場合は、グローバル変数 $defs に
"-DHAVE_type" を追加し、真を返します。型 type がシステムに存在しない場
合は、偽を返します。

例えば、

require 'mkmf'
have_type('foo') # => true

である場合、HAVE_TYPE_FOO をというプリプロセッサマクロをコンパイラに渡します。

@param type 検査したい型の名前を指定します。

@param headers 追加のヘッダを指定します。

@param opt ...

Kernel#have_struct_member(type, member, headers = nil) -> bool (19030.0)

member というメンバを持つ構造体 type がシステムに存在するかどうか検査します。

member というメンバを持つ構造体 type がシステムに存在するかどうか検査します。

member というメンバを持つ構造体 type がシステムに存在する場合は、
グローバル変数 $defs に "-DHAVE_type_member" を追加し、真を返します。
member というメンバを持つ構造体 type が存在しない場合は、偽を返します。

例えば

require 'mkmf'
have_struct_member('struct foo', 'bar') # => true

である場合、HAVE_STRUCT_FOO_BAR というプリプロセッサマクロをコンパ...

絞り込み条件を変える

Kernel#have_struct_member(type, member, headers = nil) { ... } -> bool (19030.0)

member というメンバを持つ構造体 type がシステムに存在するかどうか検査します。

member というメンバを持つ構造体 type がシステムに存在するかどうか検査します。

member というメンバを持つ構造体 type がシステムに存在する場合は、
グローバル変数 $defs に "-DHAVE_type_member" を追加し、真を返します。
member というメンバを持つ構造体 type が存在しない場合は、偽を返します。

例えば

require 'mkmf'
have_struct_member('struct foo', 'bar') # => true

である場合、HAVE_STRUCT_FOO_BAR というプリプロセッサマクロをコンパ...

Kernel#try_type(type, headers = nil, opt = "") -> bool (18982.0)

Kernel#have_type を使ってください。

...
Kernel
#have_type を使ってください。

@param type 検査したい型の名前を指定します。

@param headers 追加のヘッダを指定します。

@param opt コンパイラに渡す追加のオプションを指定します。...

Kernel#try_type(type, headers = nil, opt = "") { ... } -> bool (18982.0)

Kernel#have_type を使ってください。

...
Kernel
#have_type を使ってください。

@param type 検査したい型の名前を指定します。

@param headers 追加のヘッダを指定します。

@param opt コンパイラに渡す追加のオプションを指定します。...

Kernel.#fail(error_type, message = nil, backtrace = caller(0), cause: $!) -> () (664.0)

例外を発生させます。 発生した例外は変数 $! に格納されます。また例外が 発生した時のスタックトレースは変数 $@ に格納され ます。発生した例外は rescue 節で捕捉できます。

...します。
@param message 例外のメッセージとなる文字列です。
@param backtrace 例外発生時のスタックトレースで、Kernel.#caller の戻り値と同じ
形式で指定しなければいけません。
@param cause 現在の例外($!)の代わりに Exception#cause に...
...end

foo(4) #=> in method.in rescue.in method.in else.in ensure.
//}

//emlist[例3][ruby]{
class MyException
def exception(mesg=nil)
SecurityError.new(mesg)
end
end

begin
raise MyException.new
rescue SecurityError
p $! #=> #<SecurityError: SecurityError>
end
//}

@see Kernel.#caller...

Kernel.#raise(error_type, message = nil, backtrace = caller(0), cause: $!) -> () (664.0)

例外を発生させます。 発生した例外は変数 $! に格納されます。また例外が 発生した時のスタックトレースは変数 $@ に格納され ます。発生した例外は rescue 節で捕捉できます。

...します。
@param message 例外のメッセージとなる文字列です。
@param backtrace 例外発生時のスタックトレースで、Kernel.#caller の戻り値と同じ
形式で指定しなければいけません。
@param cause 現在の例外($!)の代わりに Exception#cause に...
...end

foo(4) #=> in method.in rescue.in method.in else.in ensure.
//}

//emlist[例3][ruby]{
class MyException
def exception(mesg=nil)
SecurityError.new(mesg)
end
end

begin
raise MyException.new
rescue SecurityError
p $! #=> #<SecurityError: SecurityError>
end
//}

@see Kernel.#caller...

絞り込み条件を変える