Project

General

Profile

Actions

Bug #1617

closed

Exception Raised by Uncaught Throw (Disagreement Between Documentation and Reality)

Added by runpaint (Run Paint Run Run) about 16 years ago. Updated about 14 years ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
ruby 1.9.2dev (2009-06-01 trunk 23614) [i686-linux]
Backport:
[ruby-core:23824]

Description

=begin
On 1.9 an ArgumentError is raised when a symbol is thrown without being subsequently caught:

 >> throw :foo
 ArgumentError: uncaught throw :foo
from (irb):2:in `throw'
from (irb):2
from /usr/local/bin/irb:12:in `<main>'

The documentation for throw states "Raises +NameError+ if there is no +catch+ block for the symbol." Either the documentation or the code is wrong. (Question previously raised in [ruby-core:17629] by Vladimir Sizikov nearly a year ago).
=end

Actions #1

Updated by nobu (Nobuyoshi Nakada) about 16 years ago

  • Status changed from Open to Closed
  • % Done changed from 0 to 100

=begin
Applied in changeset r23673.
=end

Actions

Also available in: Atom PDF

Like0
Like0