[r6rs-discuss] [Formal] Problems in description of instantiation
semantics
AndrevanTonder
andre at het.brown.edu
Mon Jan 22 12:55:40 EST 2007
---
This message is a formal comment which was submitted to formal-comment at r6rs.org, following the requirements described at: http://www.r6rs.org/process.html
---
Name : Andre van Tonder
Email : andre at het.brown.edu
Type : defect
Priority : medium
Component : Libraries
Version : 5.92
Pages : 25-26
Dependencies: None
Summary:
--------
Library instantiation semantics insufficient or incorrect.
Description:
------------
The document does not distinguish evaluation times of macro definitions and
variable definitions. In particular, it states "An instance of a library
corresponds to an evaluation of its definitions and expressions in a particular
phase relative to another library."
Given this, the following statement is incorrect:
"... if the expanded form of one library references
at phase 0 an identifier from another library, then
before the referencing library is instantiated at phase n,
the referenced library must be instantiated at phase n."
It is incorrect because it requires that macro definitions in the referenced
library must be re-evaluated (unnecessarily) when the /already expanded/
referencing library is run.
Furthermore, the decription on pages 25-26 is incomplete. It does not
actually decribe the phase where the macro definitions in an imported must
be evaluated (but the variable definitions must not).
More information about the r6rs-discuss
mailing list