Project

General

Profile

Bug #10170

Updated by nobu (Nobuyoshi Nakada) over 7 years ago

So if we have this 

 ```ruby 
 class `class A 
   define_method :a do 
     a 
   end 
 end 
 ``` end` 

 and call `A.new.a` we got `SystemStackError` 
 but with alias 

 ```ruby 
 class `class A 
   define_method :a do 
     a 
   end 
 end 
 ``` end` 

 when calling  

 ```ruby  
 `x=A.new 
 x=A.new 
 x.a 
 ``` 
 x.a` in irb or  

 ```ruby  
 `x=A.new 
 x=A.new 
 x.a; x.a 
 ``` 
 x.a` in pry    gives  

 `segmentation fault (core dumped)` 

 But `ruby -e 'class A; define_method :a do; a; end; end; A.new.a;'` 
 gives segfault randomly 
 Ubuntu 13.10

Back