Changeset 29420 in project


Ignore:
Timestamp:
07/26/13 20:55:59 (6 years ago)
Author:
sjamaan
Message:

r7rs: Fix import spec to expand to "use" instead of just plain "import"; the code needs to be loaded!

File:
1 edited

Legend:

Unmodified
Added
Removed
  • release/4/r7rs/trunk/r7rs-compile-time.scm

    r29419 r29420  
    9393              specs))
    9494       (define (parse-imports specs)
    95          (map (lambda (spec)
    96                 `(import ,(fixup-import/export-spec spec 'import)))
    97               specs))
     95         ;; What R7RS calls IMPORT, we call USE (it imports *and* loads code)
     96         ;; XXX TODO: Should be import-for-syntax'ed as well?
     97         `(##core#require-extension
     98           ,(map (lambda (s) (fixup-import/export-spec s 'import)) specs)
     99           #t))
    98100       (define (process-includes fnames ci?)
    99101         `(##core#begin
     
    114116           ((('import specs ...) . more)
    115117            `(##core#begin
    116               ,@(parse-imports specs)
     118              ,(parse-imports specs)
    117119              ,(parse-decls more)))
    118120           ((('include fnames ...) . more)
     
    129131              ,(parse-decls more)))
    130132           ((('cond-expand decls ...) . more)
    131             `(##core#begin
    132               ,(parse-decls (process-cond-expand decls))
     133            `(##core#begin
     134              ,(parse-decls (process-cond-expand decls))
    133135              ,(parse-decls more)))
    134136           ((('begin code ...) . more)
Note: See TracChangeset for help on using the changeset viewer.