mirror of
https://github.com/ruby/ruby.git
synced 2025-09-15 16:44:01 +02:00
error.c: rb_get_backtrace
* error.c (rb_get_backtrace): move from eval_error.c to call exc_backtrace directly. [ruby-core:78097] [Bug #12925] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56766 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
48d5a921ab
commit
d432839cbd
4 changed files with 33 additions and 21 deletions
|
@ -952,4 +952,17 @@ $stderr = $stdout; raise "\x82\xa0"') do |outs, errs, status|
|
|||
::Warning.warn "\x00a\x00b\x00c".force_encoding("utf-16be")
|
||||
end
|
||||
end
|
||||
|
||||
def test_undefined_backtrace
|
||||
assert_separately([], "#{<<-"begin;"}\n#{<<-"end;"}")
|
||||
begin;
|
||||
class Exception
|
||||
undef backtrace
|
||||
end
|
||||
|
||||
assert_raise(RuntimeError) {
|
||||
raise RuntimeError, "hello"
|
||||
}
|
||||
end;
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue