Fix ENVIRONMENT-SYNTAX-TABLE so that it works for compiled-code
authorChris Hanson <org/chris-hanson/cph>
Thu, 30 Apr 1998 22:24:48 +0000 (22:24 +0000)
committerChris Hanson <org/chris-hanson/cph>
Thu, 30 Apr 1998 22:24:48 +0000 (22:24 +0000)
environments.

v7/src/runtime/syntax.scm

index bdc53e112fd9efff1005f9481c73fbcc7731d483..bd3b542f7a6d627c0d7caae4ecf4e8067accb709 100644 (file)
@@ -1,6 +1,6 @@
 #| -*-Scheme-*-
 
-$Id: syntax.scm,v 14.29 1998/04/30 21:28:01 cph Exp $
+$Id: syntax.scm,v 14.30 1998/04/30 22:24:48 cph Exp $
 
 Copyright (c) 1988-98 Massachusetts Institute of Technology
 
@@ -130,9 +130,13 @@ MIT in each case. |#
   *syntax-top-level?*)
 
 (define (environment-syntax-table environment)
-  (lexical-reference environment syntax-table-tag))
+  (environment-lookup environment syntax-table-tag))
 
 (define (set-environment-syntax-table! environment table)
+  (if (not (interpreter-environment? environment))
+      (error:wrong-type-argument environment
+                                "interpreter environment"
+                                'SET-ENVIRONMENT-SYNTAX-TABLE!))
   (local-assignment environment syntax-table-tag table))
 
 (define-integrable syntax-table-tag