From: Chris Hanson Date: Thu, 4 Jun 1987 00:02:13 +0000 (+0000) Subject: Add error handlers for compiled code unbound/unassigned variable X-Git-Tag: 20090517-FFI~13418 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=0b87e5b5f424a29a0b7d250a845dbe5b05adea3b;p=mit-scheme.git Add error handlers for compiled code unbound/unassigned variable errors during lookup-apply operations. --- diff --git a/v7/src/runtime/error.scm b/v7/src/runtime/error.scm index d6792dfaa..56a1fcbd7 100644 --- a/v7/src/runtime/error.scm +++ b/v7/src/runtime/error.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/error.scm,v 13.46 1987/04/13 18:42:53 cph Exp $ +;;; $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/error.scm,v 13.47 1987/06/04 00:02:13 cph Exp $ ;;; ;;; Copyright (c) 1987 Massachusetts Institute of Technology ;;; @@ -320,6 +320,13 @@ using the current read-eval-print environment.")) (if (continuation-evaluated-object? object) (continuation-evaluated-object-value object) (error "Not evaluated -- get a wizard" unwrap-evaluated-object object))) + +(define (combination-operator? expression) + (and (combination? expression) + (variable? (combination-operator expression)))) + +(define (combination-operator-name combination) + (variable-name (combination-operator combination))) ;;;; Environment Operation Errors @@ -330,6 +337,7 @@ using the current read-eval-print environment.")) (define-unbound-variable-error variable? variable-name) (define-unbound-variable-error access? access-name) (define-unbound-variable-error assignment? assignment-name) +(define-unbound-variable-error combination-operator? combination-operator-name) (define-unbound-variable-error (list (make-primitive-procedure 'LEXICAL-REFERENCE) (make-primitive-procedure 'LEXICAL-ASSIGNMENT)) @@ -349,6 +357,8 @@ using the current read-eval-print environment.")) (define-unassigned-variable-error variable? variable-name) (define-unassigned-variable-error access? access-name) +(define-unassigned-variable-error combination-operator? + combination-operator-name) (define-unassigned-variable-error (list (make-primitive-procedure 'LEXICAL-REFERENCE)) combination-second-operand)