[Top][All Lists]

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

Re: (< complex) and friends

From: Jon Wilson
Subject: Re: (< complex) and friends
Date: Thu, 18 Sep 2008 09:59:30 -0400
User-agent: Thunderbird (X11/20080724)

Say you want to both filter out most elements from a list and also make sure that the remaining elements are sorted.

(apply < (filter some-predicate original-list))

If (<) didn't evaluate to #t, then you'd have to put code in there to check the length of the value you get from filter, which makes things uglier. Also, having (<) => #t doesn't hurt anything.

Bill Schottstaedt wrote:
There are actually more problems in that area; for example:

guile> (< 2 1 1.0+3.0i)

which perhaps should be an error also.  My druthers for the
one arg case is to simply disallow it -- why does Guile support
stuff like:

guile> (<)

reply via email to

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