perl6/specs — Issue #6: .perl for self-referent structures
Author: coke
Created: 2011-10-21 12:59:07+00:00
State: open

Pulled from https://rt.perl.org/rt3/Ticket/Display.html?id=58922

Subject: .perl for self-referent structures
Date: Tue, 16 Sep 2008 17:17:27 +0200
To: rakudobug@perl.org
From: "Carl M�sak"
Download (untitled) [text/plain 631b]
Calling .perl on a self-referent structure makes Rakudo r31152 hang.

$ ./perl6 -e 'my @a = (1); @a[0] := @a; @a.perl'

pmichaud: what about @a[0] := @a ?
masak: I don't know about that one. :-)
[...]
:)
[...]
part of me thinks that ends up with a self-referential structure
I hope so
that seems to be what's happening in at least one case in
Rakudo right now
question is, should .perl be able to handle that, and if so, how?
masak: it should
perhaps it should emit something like 'do { my @x = (...);
@x[0] := @x; @x }'
* masak submits rakudobug

# Fri Nov 07 15:01:43 2008 pmichaud - Correspondence added [Reply] [Comment]
RT-Send-CC: perl6-compiler@perl.org
Download (untitled) [text/plain 193b]
I'm going to mark this ticket as stalled until we have a good idea of
how self-referent structures should be handled in the output, either
through the spec itself or the spectests.

Thanks!

Pm