mirror of
https://github.com/ruby/ruby.git
synced 2025-08-16 05:59:00 +02:00
RJIT: Print an error message first
Creating a backtrace can crash if RJIT is triggered by branch_stub_hit. In that case, it's useful to at least print the error message.
This commit is contained in:
parent
fac7d2c1ab
commit
c28177cd57
1 changed files with 2 additions and 1 deletions
|
@ -67,7 +67,8 @@ module RubyVM::RJIT
|
||||||
compile_block(asm, jit:, pc:)
|
compile_block(asm, jit:, pc:)
|
||||||
iseq.body.jit_entry = @cb.write(asm)
|
iseq.body.jit_entry = @cb.write(asm)
|
||||||
rescue Exception => e
|
rescue Exception => e
|
||||||
$stderr.puts e.full_message
|
$stderr.puts "#{e.class}: #{e.message}"
|
||||||
|
$stderr.puts e.backtrace
|
||||||
exit 1
|
exit 1
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue