[r6rs-discuss] [Formal] Requirement to detect circular lists

Dan Muresan dan-r6rs at omnigia.com
Tue Oct 3 03:45:50 EDT 2006


>>   (let ((x (list 1 2)))
>>     (set-cdr! (cdr x) x)   ;; x = #0=(1 2 . #0#)
>>     (map f some-list x))

> I may be misinterpreting what you mean by "miss it", but this example
> isn't valid in R5RS, so it's not something that used to be portable but no
> longer is.  In fact, it now has a portable semantics (though probably not
> the one you want), where it had none before.

The question is, which behavior would be more useful? Circularity checks,
or allowing Shiro and Andre's elegant constructs? I personally think the
answer is very, very obvious.

Best,
Dan Muresan
http://alumnus.caltech.edu/~muresan



More information about the r6rs-discuss mailing list