From 5e9989ab1d065d2048f64f7588b4462024144266 Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Tue, 26 Dec 2017 14:03:52 -0500 Subject: [PATCH] Eliminate non-hygienic-macro-transformer. --- src/runtime/mit-syntax.scm | 4 ---- src/runtime/runtime.pkg | 2 -- src/runtime/syntax-definitions.scm | 2 -- src/runtime/syntax-environment.scm | 6 +----- src/runtime/syntax-transforms.scm | 8 -------- 5 files changed, 1 insertion(+), 21 deletions(-) diff --git a/src/runtime/mit-syntax.scm b/src/runtime/mit-syntax.scm index 686a6f1b0..dff676ab2 100644 --- a/src/runtime/mit-syntax.scm +++ b/src/runtime/mit-syntax.scm @@ -59,10 +59,6 @@ USA. ;; "Explicit Renaming" transformer (transformer-keyword 'ER-MACRO-TRANSFORMER->EXPANDER er-macro-transformer->expander)) - -(define classifier:non-hygienic-macro-transformer - (transformer-keyword 'NON-HYGIENIC-MACRO-TRANSFORMER->EXPANDER - non-hygienic-macro-transformer->expander)) ;;;; Core primitives diff --git a/src/runtime/runtime.pkg b/src/runtime/runtime.pkg index 9cb593867..e4e711d0c 100644 --- a/src/runtime/runtime.pkg +++ b/src/runtime/runtime.pkg @@ -4656,7 +4656,6 @@ USA. (parent (runtime syntax)) (export () er-macro-transformer->expander - non-hygienic-macro-transformer->expander rsc-macro-transformer->expander sc-macro-transformer->expander syntactic-keyword->item)) @@ -4671,7 +4670,6 @@ USA. classifier:er-macro-transformer classifier:let-syntax classifier:letrec-syntax - classifier:non-hygienic-macro-transformer classifier:rsc-macro-transformer classifier:sc-macro-transformer compiler:delay diff --git a/src/runtime/syntax-definitions.scm b/src/runtime/syntax-definitions.scm index e2dce3857..a8f3a738d 100644 --- a/src/runtime/syntax-definitions.scm +++ b/src/runtime/syntax-definitions.scm @@ -46,8 +46,6 @@ USA. (define-classifier 'ER-MACRO-TRANSFORMER classifier:er-macro-transformer) (define-classifier 'LET-SYNTAX classifier:let-syntax) (define-classifier 'LETREC-SYNTAX classifier:letrec-syntax) - (define-classifier 'NON-HYGIENIC-MACRO-TRANSFORMER - classifier:non-hygienic-macro-transformer) (define-classifier 'RSC-MACRO-TRANSFORMER classifier:rsc-macro-transformer) (define-classifier 'SC-MACRO-TRANSFORMER classifier:sc-macro-transformer) diff --git a/src/runtime/syntax-environment.scm b/src/runtime/syntax-environment.scm index a8c42782a..b642c0a30 100644 --- a/src/runtime/syntax-environment.scm +++ b/src/runtime/syntax-environment.scm @@ -117,11 +117,7 @@ USA. (if (interpreter-environment? env) 'runtime-top-level 'runtime)) (lambda (env name) (and (symbol? name) - (let ((item (environment-lookup-macro env name))) - (if (procedure? item) - ;; **** Kludge to support bootstrapping. - (non-hygienic-macro-transformer->expander item env) - item)))) + (environment-lookup-macro env name))) (lambda (env name item) (environment-define-macro env name item)) (lambda (env name) diff --git a/src/runtime/syntax-transforms.scm b/src/runtime/syntax-transforms.scm index 730810adc..f5c1a0419 100644 --- a/src/runtime/syntax-transforms.scm +++ b/src/runtime/syntax-transforms.scm @@ -68,14 +68,6 @@ USA. (identifier=? use-environment x use-environment y))) -(define (non-hygienic-macro-transformer->expander transformer - closing-environment) - closing-environment - (make-expander-item - (lambda (form use-environment) - (close-syntax (apply transformer (cdr form)) - use-environment)))) - (define (syntactic-keyword->item keyword environment) (let ((item (environment-lookup-macro environment keyword))) (if (not item) -- 2.25.1