# New Ticket Created by # Please include the string: [perl #124242] # in the subject line of all future correspondence about this issue. # <URL: https://rt.perl.org/Ticket/Display.html?id=124242 >
OS: Ubuntu 14.04 LTS in VirtualBox Host: Windows 8, Intel Core i5 Dual Rakudo version: This is perl6 version 2015.03-159-g4afc9e9 built on MoarVM version 2015.03-45-ge0f1cb0 The code below creates a self-referencing object then tries to print it. Creating the self-reference proceeds normally but any attempt to print it, even with the .perl modifier, ends up invoking the OOM killer, I'm guessing as it goes round-and-round the object tree, which now has a loop in it. I haven't tried to see if changing @.myself to $.myself has any effect because trying the normal things causes a different compile-time error. --cut here-- class Bug { has @.myself; method bind( $myself ) { @.myself[0] = $myself; } } my $a1 = Bug.new; $a1.bind( $a1 ); say $a1; --cut here--