On Sep 16, 2009, at 7:55 PM, Derick Eddington wrote:

> Further, inexpert users regularly accidentally include
> unnecessary levels because they don't understand what levels are
> necessary, and for systems which always instantiate/visit libraries  
> for
> every given level, this could cause additional phase problems which
> would not happen in an implicit phasing system.

What problems would creating an unnecessary instantiation of a library  
cause? It will be created and then destroyed. Hopefully, nothing bad  
comes of just instantiating a library. Otherwise, you're probably  
doing something goofy in the first place.

>        I'm willing to continue using "explicit phasing" to keep my  
> code
>        portable and to gain more experience with it.  So far (2  
> years),
>        I've become more convinced I like "implicit phasing" better.  I
>        think a better compromise would be that imports without level
>        declarations are always "implicit phasing" and imports with
>        level declarations are always verified (which I suppose would
>        always require declarations for level 0 to verify that only
>        level 0 is used, and I see that as more consistent with the
>        purpose of "explicit phasing"), instead of the current
>        compromise where "implicit phasing" style is not portable and
>        "explicit phasing" style is ignored by some systems and so not
>        portable according to the authors' intent  -- this way both
>        sides can do it their way *and* be portable.


Having imports without level declarations "implicitly" phased is not  
generally possible for separate-instantiation systems (which need to  
instantiate the library *before* deciding that the binding access  
should be allowable). You could instead say that no level declaration  
means phases (-1, 0, 1). This would probably have the same effect for  
most users.

I imagine that very few users ever need to import libraries at level  
1, assuming that the rnrs meta library is the most common way of  
getting at `syntax-case' & friends. I would imagine that even fewer  
ever need to touch a level greater than 1, or lower than 0. My general  
preference is to use `syntax-rules' whenever possible, and to dip into  
`syntax-case' when it's absolutely necessary for the task at hand. As  
such, I very rarely need to touch phases at all. Others seem to use  
`syntax-case' even when it's not necessary at all, but rarely do I see  
metasyntax. (If *anyone* has written a library import for phase >= 2  
I'd like to see it. I can vaguely understand why one might need to use  
a phase <= -1, but I'd like to see a good example for that one too.)
--
Brian Mastenbrook
[email protected]
http://brian.mastenbrook.net/

_______________________________________________
r6rs-discuss mailing list
[email protected]
http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss

Reply via email to