[r6rs-discuss] Proposed features for small Scheme, part 9: modules
John Cowan
cowan at ccil.org
Tue Oct 13 17:24:00 EDT 2009
Alaric Snell-Pym scripsit:
> I mean: say you're writing a 3D graph drawing lib that would like to
> use opengl where available, or software rendering where not. How does
> it conditionally import the opengl module? Eg, attempt to import it,
> and not fail if it's not there? Once it's past that hurdle, cond-
> expand should be sufficient to select between opengl and software
> rendering.
It imports the same set of names in either case, whether it's using
real OpenGL code or its own fake code, which presumably are stored in
different code files.
> Anyway, if you're *defining* the OpenGL library, then who exactly is
> specifying "has-open-gl"? But that's another issue...
I don't know; someone who knows whether the *actual* OpenGL (in C)
is available on the system.
--
John Cowan http://www.ccil.org/~cowan cowan at ccil.org
One of the oil men in heaven started a rumor of a gusher down in hell. All
the other oil men left in a hurry for hell. As he gets to thinking about
the rumor he had started he says to himself there might be something in
it after all. So he leaves for hell in a hurry. --Carl Sandburg
More information about the r6rs-discuss
mailing list