Thanks for sharing your thoughts, Daphne!

Am Do., 14. Okt. 2021 um 14:41 Uhr schrieb Daphne Preston-Kendal <xxxxxx@nonceword.org>:
Should phasing issues be mentioned in SRFI 211?

To my knowledge there is only one implementation of R7RS with a low-level macro system which strongly enforces phasing so far: Gerbil. And in Gerbil’s case you can’t actually access the low-level macro system, syntax-case, from within R7RS yet. (There may be others — I haven’t tested all systems which claim R7RS support extensively.)

Outside the context of a library system and the question of (pre-)compiled libraries, I am not sure whether discussing phasing makes much sense. So far, SRFI 211 is not touched by the issue (or, rather, can afford being ignorant about it).
 
In Unsyntax, Marc has adopted the ‘meta’ keyword from Chez to help with resolve phasing issues more easily: <https://www.unsyntax.org/unsyntax/features/syntax/meta/phasing/2020/10/22/meta-definitions.html>
I think SRFI 211 would be a good place to mention this keyword, since this SRFI standardizes syntax-case etc. where this can become a problem. But if it did, it would presumably result in SRFI 211 having to define what phasing is, and having to introduce language at least as strong as ‘It is an error to use an identifier which is not defined in the phase in which it is used’ or similar. Which we may need to adopt in R7RS anyway. But also I sense this is a touchy issue for those who reject R6RS, and SRFI 211 is thus far a very politically neutral document in that sense.

I do think that the `meta' keyword is a sensible and helpful addition to the language (otherwise, I wouldn't have implemented it), but instead of adding it to SRFI 211, I'd suggest creating a separate SRFI for it. It has more to do with procedural macros and compile-time evaluation in general than with specific macro systems, which are the topic of SRFI 211.

As for the necessity of mentioning phasing in general: If we want to allow separate compilation of libraries, I think we can't ignore it.

Marc