Update of /cvsroot/sbcl/sbcl/src/code
In directory usw-pr-cvs1:/tmp/cvs-serv6292/src/code
Modified Files:
early-extensions.lisp
Log Message:
0.7.2.11:
Miscellaneous uncontroversial fixes, motivated by compilation
under CLISP:
... delete fixed bug 58
... implement BUG on the host compiler, and use it in genesis.lisp
... refer to existing variable in give-up-ir1-transform in
DEFTRANSFORM MAKE-ARRAY
... change declarations from (SOME-STRUCT VAR) to
(TYPE SOME-STRUCT VAR)
... remove quote from CASE clauses
... conditionalize PSEUDO_ATOMIC_TRAP on #!+sparc for now
Index: early-extensions.lisp
===================================================================
RCS file: /cvsroot/sbcl/sbcl/src/code/early-extensions.lisp,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -d -r1.41 -r1.42
*** early-extensions.lisp 12 Apr 2002 12:15:56 -0000 1.41
--- early-extensions.lisp 15 Apr 2002 15:58:24 -0000 1.42
***************
*** 715,724 ****
--- 715,749 ----
`(unless ,expr
(%failed-aver ,(format nil "~A" expr))))
+
(defun %failed-aver (expr-as-string)
(bug "~@<failed AVER: ~2I~_~S~:>" expr-as-string))
+
+ ;;; We need a definition of BUG here for the host compiler to be able
+ ;;; to deal with BUGs in sbcl. This should never affect an end-user,
+ ;;; who will pick up the definition that signals a CONDITION of
+ ;;; condition-class BUG; however, this is not defined on the host
+ ;;; lisp, but for the target. SBCL developers sometimes trigger BUGs
+ ;;; in their efforts, and it is useful to get the details of the BUG
+ ;;; rather than an undefined function error. - CSR, 2002-04-12
+ #+sb-xc-host
+ (defun bug (format-control &rest format-arguments)
+ (error 'simple-error
+ :format-control "~@< ~? ~:@_~?~:>"
+ :format-arguments `(,format-control
+ ,format-arguments
+ "~@<If you see this and are an SBCL ~
+ developer, then it is probable that you have made a change to the ~
+ system that has broken the ability for SBCL to compile, usually by ~
+ removing an assumed invariant of the system, but sometimes by making ~
+ an averrance that is violated (check your code!). If you are a user, ~
+ please submit a bug report to the developers' mailing list, details of ~
+ which can be found at <http://sbcl.sourceforge.net/>.~:@>"
+ ())))
+
(defmacro enforce-type (value type)
(once-only ((value value))
`(unless (typep ,value ',type)
(%failed-enforce-type ,value ',type))))
+
(defun %failed-enforce-type (value type)
(error 'simple-type-error ; maybe should be TYPE-BUG, subclass of BUG?
|