Ifdef-ize the hopscotch hash stuff for non-x86.
[sbcl.git] / src / code / restart.lisp
blobb83a05f70cebbe90ec83c9f13f0c73083d5e4df9
1 ;;;; This software is part of the SBCL system. See the README file for
2 ;;;; more information.
3 ;;;;
4 ;;;; This software is derived from the CMU CL system, which was
5 ;;;; written at Carnegie Mellon University and released into the
6 ;;;; public domain. The software is in the public domain and is
7 ;;;; provided with absolutely no warranty. See the COPYING and CREDITS
8 ;;;; files for more information.
10 (in-package "SB!KERNEL")
12 #!+stack-allocatable-fixed-objects
13 (declaim (inline make-restart)) ;; to allow DX-allocation
15 ;;;; This defstruct should appear before any use of WITH-CONDITION-RESTARTS
16 ;;;; so that the slot accessors are transformed.
17 (defstruct (restart (:constructor make-restart
18 ;; Having TEST-FUNCTION at the end allows
19 ;; to not replicate its default value in RESTART-BIND.
20 (name function
21 &optional report-function
22 interactive-function
23 test-function))
24 (:copier nil) (:predicate nil))
25 (name (missing-arg) :type symbol :read-only t)
26 (function (missing-arg) :type function :read-only t)
27 (report-function nil :type (or null function) :read-only t)
28 (interactive-function nil :type (or null function) :read-only t)
29 (test-function (lambda (cond) (declare (ignore cond)) t) :type function :read-only t)
30 ;; the list of conditions which are currently associated to the
31 ;; restart. maintained by WITH-CONDITION-RESTARTS in a neither
32 ;; thread- nor interrupt-safe way. This should not be a problem
33 ;; however, since safe uses of restarts have to assume dynamic
34 ;; extent.
35 (associated-conditions '() :type list))
37 #!-sb-fluid (declaim (freeze-type restart))