るりまサーチ

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

別のキーワード

  1. _builtin to_r
  2. open3 pipeline_r
  3. matrix elements_to_r
  4. fileutils rm_r
  5. fileutils cp_r

ライブラリ

キーワード

検索結果

<< 1 2 3 ... > >>

Kernel.#require_relative(relative_feature) -> bool (12601.0)

現在のファイルからの相対パスで require します。

...相対パスで require します。

r
equire File.expand_path(relative_feature, File.dirname(__FILE__))
とほぼ同じです。

Kernel
.#eval などで文字列を評価した場合に、そこから
r
equire_relative を呼出すと必ず失敗します。

@param relative_feature ファイル...
...名の文字列です。
@raise LoadError ロードに失敗した場合に発生します。
@see Kernel.#require

=== require と load のスコープ

ローカル変数はファイル間では共有されません。ですので、
ロードしたライブラリのローカル変数を
ロード...
...扱い方はKernel.#loadでも同様です。

//emlist[例][ruby]{
# ---------- some.rb -----------
$a = 1
@a = 1
A = 1
a = 1
# ---------- end some.rb -------

r
equire 'some'
p $a #=> 1
p @a #=> 1
p A #=> 1
p a # undefined local variable or method `a' for #<Object:0x294f9ec @a=1> (NameError)
//}...

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

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

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

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

例えば

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

である場合、HAVE_STRUCT_FOO_BAR というプリプロセッサマクロをコンパイラに渡します。
また、後方互換性のために HAVE_ST_BAR というプリプロセッサマ...
...クロも定義します。

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

@param member 検査したい構造体のメンバの名前を指定します。

@param headers 追加のヘッダファイルを指定します。...

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

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

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

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

例えば

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

である場合、HAVE_STRUCT_FOO_BAR というプリプロセッサマクロをコンパイラに渡します。
また、後方互換性のために HAVE_ST_BAR というプリプロセッサマ...
...クロも定義します。

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

@param member 検査したい構造体のメンバの名前を指定します。

@param headers 追加のヘッダファイルを指定します。...

Kernel#merge_libs(*libs) -> [String] (12301.0)

@todo 使われてない

...@todo 使われてない

@param libs ???...

Kernel$$INPUT_LINE_NUMBER -> Integer (12301.0)

$. の別名

...$. の別名

1 e
2 f
3 g
4 h
5 i
# end of a.txt

r
equire "English"

File.foreach(ARGV.at(0)){|line|
# read line
}
p $INPUT_LINE_NUMBER
# end of sample.rb

r
uby sample.rb a.txt
#=> 5...

絞り込み条件を変える

Kernel#convertible_int(type, headers = nil, opts = nil) (12201.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

...
R
eturns 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...
...assed 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'
suff...
...ed 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 FOOBART2...

Kernel#convertible_int(type, headers = nil, opts = nil) { ... } (12201.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

...
R
eturns 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...
...assed 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'
suff...
...ed 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 FOOBART2...

Kernel#describe(desc) { ... } (12201.0)

与えられた説明文から名前を作成してテストクラスを定義します。

...与えられた説明文から名前を作成してテストクラスを定義します。

クラスの定義は、与えられたブロックの内容になります。

@param desc ブロックに対する説明を指定します。...

Kernel#find_library(lib, func, *paths) -> bool (12201.0)

関数 func が定義されたライブラリ lib を探します。

...関数 func が定義されたライブラリ lib を探します。

最初はパスを指定せずに探し、
それに失敗したら paths[0] を指定して探し、
それにも失敗したら paths[1] を指定して探し……
というように、リンク可能なライブラリを探...
...ます。

上記の探索でライブラリ lib を発見できた場合は lib を $libs に追加し、
見つかったパスを $LDFLAGS に追加して true を返します。
指定されたすべてのパスを検査してもライブラリ lib が見つからないときは、
変数を変...
...paths を指定しないときは Kernel#have_library と同じ動作です。

@param lib ライブラリ名を指定します。

@param func 関数名を指定します。
nil または空文字列を指定した場合は "main" になります。

@param paths ライブラリを検...

Kernel#find_library(lib, func, *paths) { ... } -> bool (12201.0)

関数 func が定義されたライブラリ lib を探します。

...関数 func が定義されたライブラリ lib を探します。

最初はパスを指定せずに探し、
それに失敗したら paths[0] を指定して探し、
それにも失敗したら paths[1] を指定して探し……
というように、リンク可能なライブラリを探...
...ます。

上記の探索でライブラリ lib を発見できた場合は lib を $libs に追加し、
見つかったパスを $LDFLAGS に追加して true を返します。
指定されたすべてのパスを検査してもライブラリ lib が見つからないときは、
変数を変...
...paths を指定しないときは Kernel#have_library と同じ動作です。

@param lib ライブラリ名を指定します。

@param func 関数名を指定します。
nil または空文字列を指定した場合は "main" になります。

@param paths ライブラリを検...

絞り込み条件を変える

<< 1 2 3 ... > >>