get-defined-fun: handle :declared-verify.
[sbcl.git] / tests / save10.test.sh
blobf9c502aab4cbbfc376c7ba785990cd573efca0b1
1 . ./subr.sh
3 this_file=`pwd`/save10.test.sh
4 use_test_subdirectory
6 tmpcore=$TEST_FILESTEM.core
7 set -e
9 # This test asserts that preparing read-only space prior to savign a core file
10 # does not attempt to rewrite pointers that appear to point to unknown memory.
11 # So the test attempts to fabricate such pointers. However it's a bad idea
12 # to store into the car of a cons the value
13 # (sb-kernel:%make-lisp-obj sb-vm:instance-pointer-lowtag)
14 # as that cons is indistinguishable from a forwarded cons in 32-bit builds,
15 # where INSTANCE_POINTER_LOWTAG is 1 and forwarding_pointer_p(x) is '*x == 1'
16 run_sbcl <<EOF
17 (defvar *x* (list (sb-kernel:%make-lisp-obj sb-vm:fun-pointer-lowtag)
18 (sb-kernel:%make-lisp-obj
19 (logior #x100 sb-vm:instance-pointer-lowtag))))
20 (save-lisp-and-die "$tmpcore")
21 EOF
23 exit $EXIT_TEST_WIN