Ignore:
Timestamp:
Aug 11, 2008, 3:49:48 AM (11 years ago)
Author:
gb
Message:

Merge a lot of the CLOS/type-system changes from working-0711 branch
into trunk. Todo: compiler-macros for those changes.

Have -not- yet merged source-tracking changes, new record-source file
from working-0711, but this stuff seems to bootstrap in one swell foop.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/level-1/l1-error-system.lisp

    r10356 r10426  
    7979(define-condition simple-error (simple-condition error) ())
    8080
    81 (define-condition simple-storage-condition (simple-condition storage-condition)())
     81(define-condition simple-storage-condition (simple-condition storage-condition) ())
    8282(define-condition stack-overflow-condition (simple-storage-condition) ())
    8383
     
    136136(define-condition cant-construct-arglist (improper-list)
    137137  ())
    138 
    139138
    140139
     
    492491                  (apply #'format stream (simple-condition-format-control c)
    493492                         (simple-condition-format-arguments c)))))
     493
     494(define-condition external-process-creation-failure (serious-condition)
     495  ((proc :initarg :proc))
     496  (:report (lambda (c stream)
     497             (with-slots (proc) c
     498               (let* ((code (external-process-%exit-code proc)))
     499                 (format stream "Fork failed in ~s: ~a. " proc (if (eql code -1) "random lisp error" (%strerror code))))))))
     500   
    494501                         
    495502(defun restartp (thing)
     
    987994
    988995
    989 (defun %check-type (value typespec placename typename)
    990   (let ((condition (make-condition 'type-error
    991                                    :datum value
    992                                    :expected-type typespec)))
    993     (if typename
    994       (setf (slot-value condition 'format-control)
    995             (format nil "value ~~S is not ~A (~~S)." typename)))
    996     (restart-case (%error condition nil (%get-frame-ptr))
    997                   (store-value (newval)
    998                                :report (lambda (s)
    999                                          (format s "Assign a new value of type ~a to ~s" typespec placename))
    1000                                :interactive (lambda ()
    1001                                               (format *query-io* "~&New value for ~S :" placename)
    1002                                               (list (eval (read))))
    1003                                newval))))
    1004996
    1005997
Note: See TracChangeset for help on using the changeset viewer.