Changeset 11264 for trunk/tests


Ignore:
Timestamp:
Oct 30, 2008, 3:04:25 PM (11 years ago)
Author:
gz
Message:

Regression test for aref optimizer bug

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/ansi-tests/ccl.lsp

    r11140 r11264  
    620620  (nil nil))
    621621
     622
     623(deftest ccl.50130
     624    ;; The compiler policy hack is just to have a predicatable way to catch the bug.
     625    ;; It doesn't have anything to do with causing the bug to happen.
     626    (let ((ccl::*default-file-compilation-policy* (ccl::new-compiler-policy :the-typechecks t))
     627          (f (test-source-file "(defun cl-test::ccl.50130-fn (arr idx)
     628                                  (aref (the (or (vector fixnum) (vector (unsigned-byte 8))) arr) idx))")))
     629      (test-compile f :load t)
     630      (funcall 'cl-test::ccl.50130-fn (make-array 4 :element-type 'fixnum :initial-element 17) 2))
     631  17)
    622632
    623633;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Note: See TracChangeset for help on using the changeset viewer.