[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Srfi-159/166 - monadic formatting for guile

From: John Cowan
Subject: Re: Srfi-159/166 - monadic formatting for guile
Date: Sun, 16 Jun 2019 12:20:55 -0400

On Sun, Jun 16, 2019 at 2:47 AM Mark H Weaver <address@hidden> wrote:

> How do you implement 'written-shared', 'pretty-shared', and
> 'trimmed/lazy'?  In particular, how do you avoid non-termination when
> asked to print cyclic data, when the cycle includes a non-standard data
> type printed using a custom printer?  For example, what if you print a
> list that includes an object whose custom printer will print output that
> includes the same list that you started with?

Of course it can't cope with that.  But consider an object whose custom
printer outputs its instance variables where one of those instance variables
has been assigned to the object itself.  No procedure other than the object
printer itself is going to be able to break *that* loop.

John Cowan        address@hidden
Yes, chili in the eye is bad, but so is your ear.  However, I would
suggest you wash your hands thoroughly before going to the toilet.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]