X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tests%2Farith.pure.lisp;h=3452abea638a676e5ff0a39535e932117f5be43f;hb=ba02429b75951fc407be01c44fdcb01ff2908707;hp=563f3695799ca6088d5c1c6c94566adfc9a4e162;hpb=6cc71ab8ffad49f43895ad0a1df6885c81876687;p=sbcl.git diff --git a/tests/arith.pure.lisp b/tests/arith.pure.lisp index 563f369..3452abe 100644 --- a/tests/arith.pure.lisp +++ b/tests/arith.pure.lisp @@ -137,3 +137,11 @@ (65 (ash most-negative-fixnum 36) t))) (destructuring-bind (index int result) x (assert (eq (eval `(logbitp ,index ,int)) result)))) + +;;; off-by-1 type inference error for %DPB and %DEPOSIT-FIELD: +(let ((f (compile nil '(lambda (b) + (integer-length (dpb b (byte 4 28) -1005)))))) + (assert (= (funcall f 1230070) 32))) +(let ((f (compile nil '(lambda (b) + (integer-length (deposit-field b (byte 4 28) -1005)))))) + (assert (= (funcall f 1230070) 32)))