mirror of
https://github.com/ruby/ruby.git
synced 2025-09-16 00:54:01 +02:00
Backtrace for SystemStackError
* eval.c (setup_exception): set backtrace in system stack error other than the pre-allocated sysstack_error. [Feature #6216] * proc.c (Init_Proc): freeze the pre-allocated sysstack_error. * vm_insnhelper.c (vm_stackoverflow): raise new instance for each times without calling any methods to keep the backtrace with no further stack overflow. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46502 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
cf3890205f
commit
053759edfc
5 changed files with 24 additions and 6 deletions
|
@ -529,7 +529,8 @@ end.join
|
|||
end
|
||||
|
||||
def test_stackoverflow
|
||||
assert_raise(SystemStackError){m}
|
||||
e = assert_raise(SystemStackError){m}
|
||||
assert_operator(e.backtrace.size, :>, 10)
|
||||
end
|
||||
|
||||
def test_machine_stackoverflow
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue