3 # tests related to .core files
5 # This software is part of the SBCL system. See the README file for
8 # While most of SBCL is derived from the CMU CL system, the test
9 # files (like this one) were written from scratch after the fork
12 # This software is in the public domain and is provided with
13 # absolutely no warranty. See the COPYING and CREDITS files for
16 tmpcore
="core-test-sh-$$.core"
19 # In sbcl-0.7.7 SAVE-LISP-AND-DIE didn't work at all because of
20 # flakiness caused by consing/GC/purify twice-and-at-least-twice
23 # "serves yall right for fiddling with too much stuff"
24 # -- Eric Marsden, <http://tunes.org/~nef/logs/lisp/02.09.15>
26 # diagnosed and fixed by Dan Barlow in sbcl-0.7.7.29
28 (defun foo (x) (+ x 11))
29 (save-lisp-and-die "$tmpcore")
31 $SBCL_ALLOWING_CORE --core "$tmpcore" \
32 --userinit /dev
/null
--sysinit /dev
/null
<<EOF
33 (quit :unix-status (foo 10))
36 echo "/Basic SAVE-LISP-AND-DIE worked, good."
38 echo "failure in basic SAVE-LISP-AND-DIE: $?"
43 echo "/returning success from core.test.sh"