# Code Review: Fixes for setting/getting backtraces

**URL:** <https://www.ruby-forum.com/t/code-review-fixes-for-setting-getting-backtraces/161916>\
**Category:** IronRuby\
**Created:** [March 3, 2009, 8:44pm UTC](https://www.ruby-forum.com/t/code-review-fixes-for-setting-getting-backtraces/161916 "2009-03-03T20:44:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shri\_B](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/898d66/32.png) [@Shri\_B](https://www.ruby-forum.com/u/Shri_B)\
**Post date:** [March 3, 2009, 8:44pm UTC](https://www.ruby-forum.com/t/code-review-fixes-for-setting-getting-backtraces/161916/1 "2009-03-03T20:44:46Z")

</div>

tfpt review “/shelveset:exc;REDMOND\sborde”

Comment :  
Exception backtracesL:

- minitest was failing while reporting a test failure because  
.backtrace was returning null. This was because “raise  
existingExceptionObject” was setting backtrace to nil. Fixed this and  
added tests for it.
- Overridden versions of set\_trace were also not being called. Fixed  
this.
- The model now is that RubyExceptionData.SetBacktrace manages the  
case of firing (the most override version of) Exception#set\_backtrace  
for the case of an exception being raised. ExceptionOps.SetBacktrace  
handles the generic case of the user calling the base implmenetation of  
Exception#set\_backtrace (ie. it is the normal library API which does not  
have to worry about the complications of exception handling).  
RubyExceptionData.SetBacktrace now eagerly creates the Ruby backtrace in  
most cases, but this should not affect perf since an exception is being  
thrown which is much more expensive.  
Added RubySpec project to Ruby.sln as a placeholder to make it easy to  
get to the rubyspec files. It contains a link to just a couple of files.  
Once these are opened, Ctrl-O will open a File Open dialog box in the  
same folder as that file.  
Added all the supported command-line options to ir.exe help
