From: Chris Hanson Date: Tue, 21 Jul 1992 04:26:40 +0000 (+0000) Subject: Change type code names. X-Git-Tag: 20090517-FFI~9216 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=678cb9456cd8a9f9485c958d5a19857c510bc4cc;p=mit-scheme.git Change type code names. --- diff --git a/v7/src/runtime/global.scm b/v7/src/runtime/global.scm index 3614a9fb7..62ea332a8 100644 --- a/v7/src/runtime/global.scm +++ b/v7/src/runtime/global.scm @@ -1,6 +1,6 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/global.scm,v 14.37 1992/05/26 19:34:04 mhwu Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/global.scm,v 14.38 1992/07/21 04:24:07 cph Exp $ Copyright (c) 1988-92 Massachusetts Institute of Technology @@ -264,18 +264,18 @@ MIT in each case. |# (define (undefined-value? object) ;; Note: the unparser takes advantage of the fact that objects ;; satisfying this predicate also satisfy: - ;; (object-type? (microcode-type 'TRUE) object) + ;; (object-type? (microcode-type 'CONSTANT) object) (or (eq? object undefined-conditional-branch) ;; same as `undefined-conditional-branch'. ;; (eq? object *the-non-printing-object*) ;; (eq? object unspecific) (eq? object (microcode-object/unassigned)))) -(define *the-non-printing-object* - (object-new-type (ucode-type true) 1)) - (define unspecific - (object-new-type (ucode-type true) 1)) + (object-new-type (microcode-type 'CONSTANT) 1)) + +(define *the-non-printing-object* + unspecific) (define (obarray->list #!optional obarray) (let ((table (if (default-object? obarray) diff --git a/v7/src/runtime/parse.scm b/v7/src/runtime/parse.scm index 8a2ccde6b..73cadffb1 100644 --- a/v7/src/runtime/parse.scm +++ b/v7/src/runtime/parse.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/parse.scm,v 14.17 1991/11/26 07:06:39 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/parse.scm,v 14.18 1992/07/21 04:24:43 cph Exp $ -Copyright (c) 1988-91 Massachusetts Institute of Technology +Copyright (c) 1988-92 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -57,8 +57,8 @@ MIT in each case. |# (char-set #\0 #\1 #\2 #\3 #\4 #\5 #\6 #\7 #\8 #\9 #\+ #\- #\. #\#))) - (set! lambda-optional-tag (object-new-type (ucode-type true) 3)) - (set! lambda-rest-tag (object-new-type (ucode-type true) 4)) + (set! lambda-optional-tag (object-new-type (microcode-type 'CONSTANT) 3)) + (set! lambda-rest-tag (object-new-type (microcode-type 'CONSTANT) 4)) (set! dot-symbol (intern ".")) (set! named-objects `((NULL . ,(list)) @@ -319,7 +319,7 @@ MIT in each case. |# (define (collect-list/list-close) (discard-char) - '()) + (list)) (define ignore-extra-list-closes true) diff --git a/v7/src/runtime/scomb.scm b/v7/src/runtime/scomb.scm index 19360f46a..5883930c6 100644 --- a/v7/src/runtime/scomb.scm +++ b/v7/src/runtime/scomb.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/scomb.scm,v 14.10 1991/02/15 18:07:03 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/scomb.scm,v 14.11 1992/07/21 04:25:13 cph Exp $ -Copyright (c) 1988-91 Massachusetts Institute of Technology +Copyright (c) 1988-92 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -197,7 +197,7 @@ MIT in each case. |# (object-type? (ucode-type conditional) object)) (define undefined-conditional-branch - (object-new-type (ucode-type true) 1)) + (object-new-type (microcode-type 'CONSTANT) 1)) (define-integrable (conditional-predicate conditional) (&triple-first conditional)) diff --git a/v7/src/runtime/uenvir.scm b/v7/src/runtime/uenvir.scm index 4917a97ef..961f66ef7 100644 --- a/v7/src/runtime/uenvir.scm +++ b/v7/src/runtime/uenvir.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/uenvir.scm,v 14.25 1991/10/29 13:31:11 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/uenvir.scm,v 14.26 1992/07/21 04:25:47 cph Exp $ -Copyright (c) 1988-91 Massachusetts Institute of Technology +Copyright (c) 1988-92 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -237,7 +237,7 @@ MIT in each case. |# (ic-environment/set-parent! environment null-environment)) (define null-environment - (object-new-type (ucode-type null) 1)) + (object-new-type (microcode-type 'NULL) 1)) (define (make-null-interpreter-environment) (let ((environment (let () (the-environment)))) diff --git a/v7/src/runtime/unpars.scm b/v7/src/runtime/unpars.scm index 2c937cd4e..11b113362 100644 --- a/v7/src/runtime/unpars.scm +++ b/v7/src/runtime/unpars.scm @@ -1,6 +1,6 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/unpars.scm,v 14.26 1992/03/25 21:58:07 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/runtime/unpars.scm,v 14.27 1992/07/21 04:26:40 cph Exp $ Copyright (c) 1988-92 Massachusetts Institute of Technology @@ -81,21 +81,22 @@ MIT in each case. |# (CHARACTER ,unparse/character) (COMPILED-ENTRY ,unparse/compiled-entry) (COMPLEX ,unparse/number) + (CONSTANT ,unparse/constant) (ENTITY ,unparse/entity) (ENVIRONMENT ,unparse/environment) (EXTENDED-PROCEDURE ,unparse/compound-procedure) - (FIXNUM ,unparse/number) (FLONUM ,unparse/flonum) (FUTURE ,unparse/future) (INTERNED-SYMBOL ,unparse/interned-symbol) (LIST ,unparse/pair) + (NEGATIVE-FIXNUM ,unparse/number) (NULL ,unparse/null) + (POSITIVE-FIXNUM ,unparse/number) (PRIMITIVE ,unparse/primitive-procedure) (PROCEDURE ,unparse/compound-procedure) (RATNUM ,unparse/number) (RETURN-ADDRESS ,unparse/return-address) (STRING ,unparse/string) - (TRUE ,unparse/true) (UNINTERNED-SYMBOL ,unparse/uninterned-symbol) (VARIABLE ,unparse/variable) (VECTOR ,unparse/vector) @@ -257,7 +258,8 @@ MIT in each case. |# type-name))) (define renamed-user-object-types - '((FIXNUM . NUMBER) + '((NEGATIVE-FIXNUM . NUMBER) + (POSITIVE-FIXNUM . NUMBER) (BIGNUM . NUMBER) (FLONUM . NUMBER) (COMPLEX . NUMBER) @@ -286,8 +288,10 @@ MIT in each case. |# (*unparse-string "#f") (unparse/default object)))) -(define (unparse/true object) - (cond ((eq? object #t) (*unparse-string "#t")) +(define (unparse/constant object) + (cond ((not object) (*unparse-string "#f")) + ((null? object) (*unparse-string "()")) + ((eq? object #t) (*unparse-string "#t")) ((undefined-value? object) (*unparse-string "#[undefined-value]")) ((eq? object lambda-optional-tag) (*unparse-string "#!optional")) ((eq? object lambda-rest-tag) (*unparse-string "#!rest")) diff --git a/v8/src/runtime/global.scm b/v8/src/runtime/global.scm index 44861dc1e..4b4c8be22 100644 --- a/v8/src/runtime/global.scm +++ b/v8/src/runtime/global.scm @@ -1,6 +1,6 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v8/src/runtime/global.scm,v 14.37 1992/05/26 19:34:04 mhwu Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v8/src/runtime/global.scm,v 14.38 1992/07/21 04:24:07 cph Exp $ Copyright (c) 1988-92 Massachusetts Institute of Technology @@ -264,18 +264,18 @@ MIT in each case. |# (define (undefined-value? object) ;; Note: the unparser takes advantage of the fact that objects ;; satisfying this predicate also satisfy: - ;; (object-type? (microcode-type 'TRUE) object) + ;; (object-type? (microcode-type 'CONSTANT) object) (or (eq? object undefined-conditional-branch) ;; same as `undefined-conditional-branch'. ;; (eq? object *the-non-printing-object*) ;; (eq? object unspecific) (eq? object (microcode-object/unassigned)))) -(define *the-non-printing-object* - (object-new-type (ucode-type true) 1)) - (define unspecific - (object-new-type (ucode-type true) 1)) + (object-new-type (microcode-type 'CONSTANT) 1)) + +(define *the-non-printing-object* + unspecific) (define (obarray->list #!optional obarray) (let ((table (if (default-object? obarray) diff --git a/v8/src/runtime/uenvir.scm b/v8/src/runtime/uenvir.scm index 55ce64b40..10c940018 100644 --- a/v8/src/runtime/uenvir.scm +++ b/v8/src/runtime/uenvir.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v8/src/runtime/uenvir.scm,v 14.25 1991/10/29 13:31:11 cph Exp $ +$Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v8/src/runtime/uenvir.scm,v 14.26 1992/07/21 04:25:47 cph Exp $ -Copyright (c) 1988-91 Massachusetts Institute of Technology +Copyright (c) 1988-92 Massachusetts Institute of Technology This material was developed by the Scheme project at the Massachusetts Institute of Technology, Department of Electrical Engineering and @@ -237,7 +237,7 @@ MIT in each case. |# (ic-environment/set-parent! environment null-environment)) (define null-environment - (object-new-type (ucode-type null) 1)) + (object-new-type (microcode-type 'NULL) 1)) (define (make-null-interpreter-environment) (let ((environment (let () (the-environment))))