chicken-hackers
[Top][All Lists]
Advanced

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

[Chicken-hackers] [PATCH] Fix for exactness check and enforcing types in


From: Peter Bex
Subject: [Chicken-hackers] [PATCH] Fix for exactness check and enforcing types in max/min (#887)
Date: Wed, 18 Jul 2012 21:23:45 +0200
User-agent: Mutt/1.4.2.3i

Hi all,

Attached is a fix for #887.  I also noticed that (max 'x) => x,
which means the #:enforcing in types.db is untrue, so I've also
added a check of the first value's type in the max/min procedures.
The other values (in "ns") are checked by the predicate.  Actually,
the first value's type is checked twice now if the list is nonempty.
If that's a huge deal we could change this, but it would complicate
the code more and the differentiation will make the code more
complicated and probably slow it down just as much as the extra check.

Cheers,
Peter
-- 
http://sjamaan.ath.cx
--
"The process of preparing programs for a digital computer
 is especially attractive, not only because it can be economically
 and scientifically rewarding, but also because it can be an aesthetic
 experience much like composing poetry or music."
                                                        -- Donald Knuth

Attachment: 0001-Add-check-to-max-and-min-for-exactness-of-all-values.patch
Description: Text document


reply via email to

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