るりまサーチ

最速Rubyリファレンスマニュアル検索!
17件ヒット [1-17件を表示] (0.042秒)

別のキーワード

  1. pointer ref
  2. entity ref
  3. fiddle ref
  4. _builtin _id2ref
  5. rexml/document ref

検索結果

NEWS for Ruby 3.0.0 (283.0)

NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。

...", "f", 3]
in [*pre, String => x, String => y, *post]
p pre #=> ["a", 1]
p x #=> "b"
p y #=> "c"
p post #=> [2, "d", "e", "f", 3]
end
//}

* Endless method definition is added. [EXPERIMENTAL]
16746

//emlist{
def square(x) = x * x
//}

* Interpolated String literals are no lo...
...nger frozen when
`# frozen-string-literal: true` is used. 17104
* Magic comment `shareable_constant_value` added to freeze constants.
See {Magic Comments}[rdoc-ref:doc/syntax/comments.rdoc@Magic+Comments] for more details.
17273
* A {static analysis}[rdoc-label:label-Static+analysis]...
...pt has been added, which returns a hash excluding the given keys and their values. 15822
* Windows: Read ENV names and values as UTF-8 encoded Strings 12650
* Encoding
* Added new encoding IBM720. 16233
* Changed default for Encoding.default_external to UTF-8 on Windows 16604
* Fib...

クラス/メソッドの定義 (275.0)

クラス/メソッドの定義 * クラス/メソッドの定義: * class * singleton_class * module * method * operator * nest_method * eval_method * singleton_method * class_method * limit * 定義に関する操作: * alias * undef * defined

...ray を明示的に指定しても同じ)
class Foo
def bar
end
end

# 間違ったスーパークラスを指定するとエラー
class Foo < String
end
# => superclass mismatch for class Foo (TypeError)
//}

クラス定義式の中は self がそのクラスであることと、
limitのデ...
...出し等の一切の評価は行われません。

メソッドの定義内で別名を付けるにはModuleクラスのメソッド
Module#alias_method を利用して下さい。

別名を付けられたメソッドは、その時点でのメソッド定義を引き継
ぎ、元のメソッド...