[MacRuby] #1102: segfault when trying const_get on unitialized constant with rspec2
#1102: segfault when trying const_get on unitialized constant with rspec2 ------------------------------------+--------------------------------------- Reporter: mrada@… | Owner: lsansonetti@… Type: defect | Status: new Priority: blocker | Milestone: Component: MacRuby | Keywords: ------------------------------------+--------------------------------------- When I try to run const_get inside of a begin/rescue/end statement it should be safe, but when I try to spec the code in rspec it causes MacRuby to segfault instead of rescuing. I was using rspec 2.4 with the latest nightly build (Jan 6). This may be related to ticket #1095, I have attached a reduced script. -- Ticket URL: <http://www.macruby.org/trac/ticket/1102> MacRuby <http://macruby.org/>
#1102: segfault when trying const_get on unitialized constant with rspec2 ------------------------------------+--------------------------------------- Reporter: mrada@… | Owner: lsansonetti@… Type: defect | Status: new Priority: blocker | Milestone: Component: MacRuby | Keywords: ------------------------------------+--------------------------------------- Comment(by lsansonetti@…): I reproduce with trunk. Looks like an infinite recursion in #const_missing. -- Ticket URL: <http://www.macruby.org/trac/ticket/1102#comment:1> MacRuby <http://macruby.org/>
#1102: segfault when trying const_get on unitialized constant with rspec2 ------------------------------------+--------------------------------------- Reporter: mrada@… | Owner: lsansonetti@… Type: defect | Status: new Priority: blocker | Milestone: Component: MacRuby | Keywords: ------------------------------------+--------------------------------------- Comment(by lsansonetti@…): Here is a reduction: {{{ $ cat t2.rb module M1 def const_missing(name) p :M1_const_missing super end end module M2 def const_missing(name) p :M2_const_missing super end end Object.extend(M1) Object.extend(M2) OMG }}} -- Ticket URL: <http://www.macruby.org/trac/ticket/1102#comment:2> MacRuby <http://macruby.org/>
#1102: segfault when trying const_get on unitialized constant with rspec2 ------------------------------------+--------------------------------------- Reporter: mrada@… | Owner: lsansonetti@… Type: defect | Status: new Priority: blocker | Milestone: Component: MacRuby | Keywords: ------------------------------------+--------------------------------------- Comment(by scott@…): This still occurs with the latest nightly (Aug 3, 2011) and with rspec 2.6.0. -- Ticket URL: <http://www.macruby.org/trac/ticket/1102#comment:3> MacRuby <http://macruby.org/>
participants (1)
-
MacRuby