Revision
4173
Author
martinlagardette@apple.com
Date
2010-05-27 18:52:31 -0700 (Thu, 27 May 2010)

Log Message

Set the actual backtrace to Obj-C exceptions, instead of an empty array

Modified Paths

Diff

Modified: MacRuby/trunk/objc.m (4172 => 4173)


--- MacRuby/trunk/objc.m	2010-05-27 21:55:13 UTC (rev 4172)
+++ MacRuby/trunk/objc.m	2010-05-28 01:52:31 UTC (rev 4173)
@@ -639,8 +639,8 @@
     snprintf(buf, sizeof buf, "%s: %s", [[exc name] UTF8String],
 	    [[exc reason] UTF8String]);
     VALUE e = rb_exc_new2(rb_eRuntimeError, buf);
-    // Set an empty backtrace for Obj-C exceptions (instead of nil)
-    rb_iv_set(e, "bt", rb_ary_new());
+    // Set the backtrace for Obj-C exceptions
+    rb_iv_set(e, "bt", rb_vm_backtrace(0));
     return e;
 }