Another small round of renaming.
authorChris Hanson <org/chris-hanson/cph>
Sat, 10 Feb 2018 04:53:13 +0000 (20:53 -0800)
committerChris Hanson <org/chris-hanson/cph>
Sat, 10 Feb 2018 04:53:13 +0000 (20:53 -0800)
src/runtime/mit-syntax.scm
src/runtime/runtime.pkg
src/runtime/syntax-declaration.scm
src/runtime/syntax-rename.scm

index 0668f992a03c23a330f66865143e93a45ae8d94c..87c19b46a7711e06e98b37c71e22355300ee6c89 100644 (file)
@@ -277,22 +277,20 @@ USA.
   (syntax-check '(_ * (identifier * datum)) form)
   (decl-item
    (lambda ()
-     (classify/declarations (cdr form) senv))))
-
-(define (classify/declarations declarations senv)
-  (map (lambda (declaration)
-        (classify/declaration declaration senv))
-       declarations))
-
-(define (classify/declaration declaration senv)
-  (map-declaration-identifiers (lambda (identifier)
-                                (var-item-id
-                                 (classify/variable-reference identifier
-                                                              senv)))
-                              declaration))
-
-(define (classify/variable-reference identifier senv)
-  (let ((item (classify-form identifier senv)))
+     (classify-decls (cdr form) senv))))
+
+(define (classify-decls decls senv)
+  (map (lambda (decl)
+        (classify-decl decl senv))
+       decls))
+
+(define (classify-decl decl senv)
+  (map-decl-ids (lambda (id)
+                 (classify-id id senv))
+               decl))
+
+(define (classify-id id senv)
+  (let ((item (classify-form id senv)))
     (if (not (var-item? item))
-       (syntax-error "Variable required in this context:" identifier))
-    item))
\ No newline at end of file
+       (syntax-error "Variable required in this context:" id))
+    (var-item-id item)))
\ No newline at end of file
index 3adfca4c5b4ed93c5bb52b3bd67b1d27f54a600d..23bec3c2077659afd9a51541d722b51c49b6c54b 100644 (file)
@@ -4525,7 +4525,7 @@ USA.
   (files "syntax-declaration")
   (parent (runtime syntax))
   (export (runtime syntax)
-         map-declaration-identifiers))
+         map-decl-ids))
 
 (define-package (runtime syntax transforms)
   (files "syntax-transforms")
index 80b0cb34341fe39ee65d6db819c70f392bbc6779..42ea88d761fc1fdb56a3665baf39351f6f77f17a 100644 (file)
@@ -39,7 +39,7 @@ USA.
                      known-declarations))
          unspecific))))
 
-(define (map-declaration-identifiers procedure declaration)
+(define (map-decl-ids procedure declaration)
   (if (not (pair? declaration))
       (error "Ill-formed declaration:" declaration))
   (let* ((declaration
index a0b988c10c6a2046de98bd38b1833831c5e8b585..f4f8d26b3ce1ee1f6994c8c983abe26313e18ea5 100644 (file)
@@ -339,7 +339,7 @@ USA.
        (make-scode-open-block
        (map substitution (scode-open-block-names expression))
        (map (lambda (declaration)
-              (map-declaration-identifiers substitution declaration))
+              (map-decl-ids substitution declaration))
             (scode-open-block-declarations expression))
        (alpha-substitute substitution (scode-open-block-actions expression)))))
 
@@ -347,7 +347,7 @@ USA.
      (lambda (substitution expression)
        (make-scode-declaration
        (map (lambda (declaration)
-              (map-declaration-identifiers substitution declaration))
+              (map-decl-ids substitution declaration))
             (scode-declaration-text expression))
        (alpha-substitute substitution
                          (scode-declaration-expression expression)))))