るりまサーチ

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

別のキーワード

  1. _builtin backtrace_locations
  2. _builtin backtrace
  3. thread backtrace_locations
  4. thread backtrace
  5. configfile backtrace=

検索結果

Exception#==(other) -> bool (18162.0)

自身と指定された other のクラスが同じであり、 message と backtrace が == メソッドで比較して 等しい場合に true を返します。そうでない場合に false を返します。

...自身と指定された other のクラスが同じであり、
message と backtrace == メソッドで比較して
等しい場合に true を返します。そうでない場合に false を返します。

@param other 自身と比較したいオブジェクトを指定します。...
...on を実行して変換を試みます。

//emlist[例][ruby]{
require "date"
def check_long_month(month)
return if Date.new(2000, month, -1).day == 31
raise "#{month} is not long month"
end

def get_exception
return begin
yield
rescue => e
e
end
end

results = [2, 2, 4].map { |e...
...is not long month", "2 is not long month", "4 is not long month"]

# class, message, backtrace が同一のため true になる
p results[0] == results[1] # => true

# class, backtrace が同一だが、message がことなるため false になる
p results[0] == results[2] # => false
//}...

Exception#backtrace_locations -> [Thread::Backtrace::Location] (6258.0)

バックトレース情報を返します。Exception#backtraceに似ていますが、 Thread::Backtrace::Location の配列を返す点が異なります。

...バックトレース情報を返します。Exception#backtraceに似ていますが、
Thread::Backtrace::Location の配列を返す点が異なります。

現状では Exception#set_backtrace によって戻り値が変化する事はあり
ません。

//emlist[例: test.rb][ruby]{
require...
...k_long_month(month)
return if Date.new(2000, month, -1).day == 31
raise "#{month} is not long month"
end

def get_exception
return begin
yield
rescue => e
e
end
end

e = get_exception { check_long_month(2) }
p e.backtrace_locations
# => ["test.rb:4:in `check_long_month'", "test.rb:...
...15:in `block in <main>'", "test.rb:9:in `get_exception'", "test.rb:15:in `<main>'"]
//}

@see Exception#backtrace...

NEWS for Ruby 3.0.0 (102.0)

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

...照情報があるため短いです。
十分な情報と共に書かれた全ての変更のリストはリンク先を参照してください。

==
言語仕様の変更

* Keyword arguments are now separated from positional arguments.
Code that resulted in deprecation warnings in Ruby 2....
...rning.

==
Command line options

==
= `--help` option

When the environment variable `RUBY_PAGER` or `PAGER` is present and has
a non-empty value, and the standard input and output are tty, the `--help`
option shows the help message via the pager designated by the value.
16754

==
= `--backtrace-limit...
...` option

The `--backtrace-limit` option limits the maximum length of a backtrace.
8661

==
Core classes updates

Outstanding ones only.

* Array
* The following methods now return Array instances instead of subclass instances when called on subclass instances: 6087
* Array#drop
*...

NEWS for Ruby 3.1.0 (102.0)

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

...照情報があるため短いです。
十分な情報と共に書かれた全ての変更のリストはリンク先を参照してください。

==
言語仕様の変更

* ブロックが他のメソッドに渡されるだけの場合は、ブロックの引数を無名にできるように...
...ことに注意してください。 17398

==
コマンドラインオプション

* --disable-gems は"デバッグ専用"として明示的に宣言されました。デバッグ専用以外のコードでは使用しないでください。 17684

==
組み込みクラスの更新(注目す...
...thread_id が追加されました。 17853

* Thread::Backtrace
* 新規メソッド
* --backtrace-limit コマンドラインオプションで設定したバックトレースの長さを制限する値を返す Thread::Backtrace.limit が追加されました。 17479

* Thread::Qu...

Ruby用語集 (42.0)

Ruby用語集 A B C D E F G I J M N O R S Y

...Ruby用語集
A B C D E F G I J M N O R S Y

a ka sa ta na ha ma ya ra wa

==
= 記号・数字
: %記法
: % notation
「%」記号で始まる多種多様なリテラル記法の総称。

参照:d:spec/literal#percent

: 0 オリジン
: zero-ba...
...チャーの番号、
Ruby 2.7 で導入された番号指定ブロックパラメーター、
といったものは 1 オリジンである。

==
=[a:A] A

: AWK
テキスト処理に適したプログラミング言語。
名称は、開発者である Aho(エイホ)、Weinberger(ワ...
...また、例外オブジェクトは例外が発生した時点までのスタックトレースを保持しており、
Exception#backtrace や Exception#backtrace_locations で
取り出すことができる。

: スーパークラス
: superclass
クラス B がクラス A のサブクラ...

絞り込み条件を変える

NEWS for Ruby 2.0.0 (30.0)

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

...共に書かれた全ての変更のリストは ChangeLog ファイルか bugs.ruby-lang.org の issue を参照してください。

==
1.9.3 以降の変更

==
= 言語仕様の変更

* キーワード引数を追加しました
* %i, %I をシンボルの配列作成のために追加し...
...ーディングを US-ASCII から UTF-8 に変更しました
* '_' で始まる使用されていない変数は警告しなくなりました

==
= 組み込みクラスの更新

* ARGF.class
* 追加: ARGF.class#codepoints, ARGF.class#each_codepoint
IO にある同名のメソッ...
...handling of exceptions
* 追加: Thread#backtrace_locations Kernel#caller_locations に似た情報を返します
* 新規クラス: Thread::Backtrace::Location to hold backtrace location
information. These are returned by Thread#backtrace_locations and
Kernel#caller_locations...

NEWS for Ruby 2.3.0 (12.0)

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

...共に書かれた全ての変更のリストは ChangeLog ファイルか bugs.ruby-lang.org の issue を参照してください。

==
2.2.0 以降の変更

==
= 言語仕様の変更

* frozen-string-literal プラグマ:
* 実験的な機能として fronzen-string-literal というプ...
...ヒアドキュメント:
* 新しい文字列リテラルとして <<~ で始まるヒアドキュメントが追加されました
9098

==
= 組み込みクラスの更新

* ARGF
* ARGF.read_nonblock は IO#read_nonblock と同じように `exception: false' オプションをサ...
...* Numeric
* Numeric#positive?, Numeric#negative? を追加
11151

* Proc
* Proc#call ( Proc#[] , Proc#===, Proc#yield) は最適化されました。
Backtrace
doesn't show each method (show block lines directly).
TracePoint also ignores these calls.
11569

* Que...