るりまサーチ

最速Rubyリファレンスマニュアル検索!
66件ヒット [1-66件を表示] (0.050秒)
トップページ > クエリ:nil[x] > クエリ:at[x] > クエリ:autoload[x]

別のキーワード

  1. _builtin nil?
  2. nilclass nil?
  3. object nil?
  4. object nil
  5. _builtin nil

ライブラリ

クラス

モジュール

検索結果

Module#autoload(const_name, feature) -> nil (18368.0)

定数 const_name を最初に参照した時に feature を Kernel.#require するように設定します。

...初に参照した時に feature を Kernel.#require するように設定します。

const_name が autoload 設定されていて、まだ定義されてない(ロードされていない)ときは、
autoload
する対象を置き換えます。
const_name が(autoloadではなく)既に定義...
...か指定できません。

@param feature Kernel.#require と同様な方法で autoload する対象を指定する。

//emlist[例][ruby]{
# ------- /tmp/foo.rb ---------
class Foo
class Bar
end
end
# ----- end of /tmp/foo.rb ----

class Foo
autoload
:Bar, '/tmp/foo'
end
p Foo::Bar #=> Fo...
...tmp/bar.rb ---------
class Bar
end
# ----- end of /tmp/bar.rb ----

class Foo
autoload
:Bar, '/tmp/bar.rb'
end
p Foo::Bar
p Foo.autoload?(:Bar)
#=> -:4: warning: toplevel constant Bar referenced by Foo::Bar
# Bar
# nil
//}

これは以下のようにネストせずに定義したのと同じ...
...-- /tmp/foo.rb ---------
class Foo
class Bar
end
end
# ----- end of /tmp/foo.rb ----

class Foo
end
Foo.autoload :Bar, '/tmp/foo'
p Foo::Bar #=> Foo::Bar
//}

以下のように、autoload したライブラリがネストした定数を定義しない場
合、NameError が発生します。

/...

Kernel.#autoload(const_name, feature) -> nil (18350.0)

定数 const_name を最初に参照した時に feature を Kernel.#require するように設定します。

...に参照した時に feature を
Kernel.#require するように設定します。

const_name には、 "::" 演算子を含めることはできません。
ネストした定数を指定する方法は Module#autoload を参照してください。

const_name が autoload 設定されていて...
...い)ときは、
autoload
する対象を置き換えます。
const_name が(autoloadではなく)既に定義されているときは何もしません。

@param const_name 定数をString または Symbol で指定します。
@param feature require と同様な方法で autoload する対象を...
...指定します。
@raise LoadError featureのロードに失敗すると発生します。

//emlist[][ruby]{
# ------- /tmp/foo.rb ---------
class Bar
end
# ----- end of /tmp/foo.rb ----

autoload
:Bar, '/tmp/foo'
p Bar #=> Bar
//}

@see Kernel.#autoload?,Module#autoload,Kernel.#require...

ObjectSpace.#count_tdata_objects(result_hash = nil) -> Hash (6207.0)

T_DATA の種類ごとにオブジェクトの数を格納したハッシュを返します。

...T_DATA の種類ごとにオブジェクトの数を格納したハッシュを返します。

@param result_hash 戻り値のためのハッシュを指定します。省略した場合は新
しくハッシュを作成します。result_hash の内容は上書き...
...ObjectSpace.count_tdata_objects
# => {RubyVM::InstructionSequence=>504, :parser=>5, :barrier=>6,
# :mutex=>6, Proc=>60, RubyVM::Env=>57, Mutex=>1, Encoding=>99,
# ThreadGroup=>1, Binding=>1, Thread=>1, RubyVM=>1, :iseq=>1,
# Random=>1, ARGF.class=>1, Data=>1, :autoload=>3, Time=>2}
//}...
...ラスオブジェクトです。それ
以外の内部的なオブジェクトの場合、キーはシンボルです。シンボルの値は
rb_data_type_struct に格納された名前が使用されます。

戻り値のハッシュは処理系に依存します。これは将来変更になる...

ruby 1.6 feature (3306.0)

ruby 1.6 feature ruby version 1.6 は安定版です。この版での変更はバグ修正がメイン になります。

...ruby 1.6 feature
ruby version 1.6 は安定版です。この版での変更はバグ修正がメイン
になります。

((<stable-snapshot|URL:ftp://ftp.netlab.co.jp/pub/lang/ruby/stable-snapshot.tar.gz>)) は、日々更新される安定版の最新ソースです。

== 1.6.8 (2002-12-24) ->...
... nil
を返すようになりました。(String#[]やString#slice と同じ結果を返すと
いうことです)

p "foo".slice!("bar") # <- 以前からこちらは nil を返していた
p "foo".slice!(5,10)

=> ruby 1.6.7 (2002-03-01) [i586-linux]
nil
...
...#<MatchData:0x401b1be4>
#<MatchData:0x401b198c>
#<MatchData:0x401b1644>
#<MatchData:0x401b1414>
=> ruby 1.6.7 (2002-03-19) [i586-linux]
nil

nil

nil

nil


: 2002-03-14 拡張ライブラリの autoload

...

ruby 1.8.4 feature (3036.0)

ruby 1.8.4 feature ruby 1.8.4 での ruby 1.8.3 からの変更点です。

...ruby 1.8.4 feature
ruby 1.8.4 での ruby 1.8.3 からの変更点です。

掲載方針

*バグ修正の影響も含めて動作が変わるものを収録する。
*単にバグを直しただけのものは収録しない。
*ライブラリへの単なる定数の追加は収録しない。...
...# => ruby 1.8.3 (2005-09-21) [i686-linux]
0
nil

# => ruby 1.8.4 (2005-12-22) [i686-linux]
0
0

: シグナル [bug]

#Sun Oct 16 03:38:07 2005 Yukihiro Matsumoto <matz@ruby-lang.org>
#
# * rubysig.h (CHECK_INTS): prevent sig...
...nobu@ruby-lang.org>
#
# * eval.c (ev_const_get), variable.c (rb_const_get_0): retry only when
# autoload succeeded.
#
# * variable.c (rb_autoload_load): now return true if autoload
# succeeded. fixed: [ruby-dev:27331]

const_missingが再定義されていて実行...

絞り込み条件を変える

1.6.8から1.8.0への変更点(まとめ) (492.0)

1.6.8から1.8.0への変更点(まとめ) * ((<1.6.8から1.8.0への変更点(まとめ)/インタプリタの変更>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加されたクラス/モジュール>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加されたメソッド>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加された定数>)) * ((<1.6.8から1.8.0への変更点(まとめ)/拡張されたクラス/メソッド(互換性のある変更)>)) * ((<1.6.8から1.8.0への変更点(まとめ)/変更されたクラス/メソッド(互換性のない変更)>)) * ((<1.6.8から1.8.0への変更点(まとめ)/文法の変更>)) * ((<1.6.8から1.8.0への変更点(まとめ)/正規表現>)) * ((<1.6.8から1.8.0への変更点(まとめ)/Marshal>)) * ((<1.6.8から1.8.0への変更点(まとめ)/Windows 対応>)) * ((<1.6.8から1.8.0への変更点(まとめ)/廃止された(される予定の)機能>)) * ((<1.6.8から1.8.0への変更点(まとめ)/ライブラリ>)) * ((<1.6.8から1.8.0への変更点(まとめ)/拡張ライブラリAPI>)) * ((<1.6.8から1.8.0への変更点(まとめ)/バグ修正>)) * ((<1.6.8から1.8.0への変更点(まとめ)/サポートプラットフォームの追加>))

...りました。
* nil: 警告を出力しない (-W0 新しい警告レベル)
* false: 重要な警告のみ出力 (-W1 デフォルト)
* true: すべての警告を出力する (-W2 or -W or -v or -w or --verbose)

追加された -W オプションは $VERBOSE = nil の指定(-W0)を...
...うになります。((<ruby-dev:20358>))

: defined? [compat]

属性代入、配列要素への代入に対して "method" でなく "assignment" を返
すようになりました。

: ((<リテラル/数値リテラル>)) [compat]

10進((*整数*))リテラルの prefix として 0d が...
...<Math/Math.atan>)) [new]
: ((<Math/Math.cosh>)) [new]
: ((<Math/Math.sinh>)) [new]
: ((<Math/Math.tanh>)) [new]
: ((<Math/Math.hypot>)) [new]
追加

=== Method

: ((<Method#==|Method/==>)) [new]

追加

=== Module

: ((<組み込み関数/autoload>...