1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-20 19:50:24 +02:00

Add tests for more kinds of typed arrays.

* test-suite/tests/arrays.test: Add more type array tests.
This commit is contained in:
Daniel Llorens 2013-05-02 11:43:31 +02:00 committed by Andy Wingo
parent b98e2f47aa
commit c6eaad9757

View file

@ -751,7 +751,15 @@
(with-input-from-string "'#1:-3(#t #t)" read)) (with-input-from-string "'#1:-3(#t #t)" read))
(pass-if "bitvector is self-evaluating" (pass-if "bitvector is self-evaluating"
(equal? (compile (bitvector)) (bitvector)))) (equal? (compile (bitvector)) (bitvector)))
; this failed in 2.0.9.
(pass-if "typed arrays that are not uniform arrays"
(let ((a #2b((#t #f) (#f #t)))
(b (make-typed-array 'b #f 2 2)))
(array-set! b #t 0 0)
(array-set! b #t 1 1)
(array-equal? a b))))
;;; ;;;
;;; equal? with vector and one-dimensional array ;;; equal? with vector and one-dimensional array