[racket] Cyclic data structures in Typed Racket

From: Sam Tobin-Hochstadt (samth at cs.indiana.edu)
Date: Tue Sep 30 07:21:06 EDT 2014

On Sep 30, 2014 7:12 AM, "Konrad Hinsen" <konrad.hinsen at fastmail.net> wrote:
> Sam Tobin-Hochstadt writes:
>  > Ah, if you want to create truly cyclic structure with no base case
>  > like this, then you'll have to do more work. Either you'll need to
>  > expand the type of the `x` field in `foo` to allow an initial value,
>  > or you'll need to create a dummy `foo` with that extended type, and
>  > then copy the cyclic data once you've created it to a new version
> In my specific application, I ended up replacing the cyclic data
> structure, which was a singleton, by a function that simulates it.
> But for another project, which involves graphs, I'll stick to
> untyped Racket for now.

Robby reminds me that we wrote a paper about another trick that might be
useful here:

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20140930/52aae4ef/attachment.html>

Posted on the users mailing list.