gcl-devel
[Top][All Lists]
Advanced

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

Re: [Gcl-devel] some GCL bugs revealed by ansi test suite


From: Camm Maguire
Subject: Re: [Gcl-devel] some GCL bugs revealed by ansi test suite
Date: 20 Aug 2002 01:51:31 -0400

Greetings!

"Paul F. Dietz" <address@hidden> writes:

> (The stack extension worked; thanks.)
> 
> ANSI compliance bugs in gcl compiled with --enable-ansi:
> 
> 1. LAST should take an optional second argument (which defaults
> to 1), but only takes one argument.
> 

Done. Please verify.

> 2. LDIFF doesn't work on dotted lists.
> 
>   (LDIFF '(A B C . D) 'D) should give (A B C)
>     but instead throws an error
> 

Done. Please verify.


> 3. TAILP doesn't work on dotted lists.
> 
>   (TAILP '(A B C . D) 'D) should be true, but
>     instead throw an error.
> 

Done. Please verify.

Several dotted list issues should have been cleared by the change to
endp1, which now appears right to me from reading the spec on list
termination.  But there could be other issues arising in treating
final elements correctly, like the one that is fixed in tailp here
separately.  I didn't change the logic regarding nil objects in tailp
-- this may need to be done, but I'd like clarification on the spec
from some of you in the know.

Please try all the related tests you can think of here.

BTW, I verified that gcl with this commit builds maxima fine.

Items below waiting for another session.

Take care,

> 4. ASSOC-IF is not taking the required :KEY argument.
> 
> 5. When ASSOC-IF is called on a list in which one of the elements
>    is NIL, it does not ignore that element.
> 
>   Example:
> 
>    (ASSOC-IF #'EVENP '((1 . a) nil (3 . b) (4 . c) (6 . d)))
>       should yield (4 . c)
>       but instead is throwing an error.
> 
> 6, 7.  Same as 4, 5, but for ASSOC-IF-NOT.
> 
> 8, 9.  Same as 4, 5, but for RASSOC-IF.
> 
> 10, 11.  Same as 4, 5, but for RASSOC-IF-NOT.
> 
> 12. BUTLAST doesn't work on dotted lists.
> 
>    (BUTLAST (LIST* 1 2 3 4) 1) should yield (1 2)
>      but instead throws an error.
> 
> 13. NBUTLAST doesn't work on dotted lists (same as 12).
> 
> 14. This expression
>  (let ((p (copy-list '(a 1 b 2)))
>         (foo nil))
>       (setf (getf p 'a (progn (setf foo t) 0)) 3)
>       (and
>        (eql (getf p 'a) 3)
>        (eql (getf p 'b) 2)
>        (eql
>       (loop
>           for ptr on p by #'cddr count
>             (not (member (car ptr) '(a b))))
>       0)
>        foo))
> 
> should evaluate to T, but (contrary to the standard) the third
> argument to the getf in the setf form is not being evaluated.
> (See the CLHS entry for GETF.)
> 
> 15.  This is a tricky one.  As I read the standard, the :test or :test-not
>   function for SET-EXCLUSIVE-OR must preserve the order of the items being
>   compared.  That is, the first must be from the first list and the second
>   from the second list.  This is not being done -- the argument order is
>   getting reversed.
> 
>       Paul
> 
> 
> _______________________________________________
> Gcl-devel mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/gcl-devel
> 
> 

-- 
Camm Maguire                                            address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah




reply via email to

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