Now, I've got a question. What should happen if there are 2 the same libraries import in the same import clause and one (or more) of the identifier(s) is(are) renamed like this?
(import (scheme base) (rename (only (scheme base) car) (car kar))) ;; are car and kar required to be the same binding?Honestly, I couldn't read if it's required to be the same in such case from R7RS. Though my guess is the followings:
- The last paragraph of section 5.6.1 only specifies the case of 2 import clauses importing the same libraries
- This type of import can't be merged into one import in sense of R7RS import definition (or can it be?)
- Thus this can be multiple import of the same library.
- The third last paragraph of section 5.6.1 suggesting the possibility of multiple load when there's multiple import of the same library (can be interpreted as multiple evaluation of library).
karmust be the same bindings. Otherwise, can be different.
Why this matters? Generally, it doesn't. Just wondering if the last case of this Gist is required to print
I've also posted this question to comp.lang.scheme: this