[gambit-list] #ifdef equivalent in Scheme?

Ralph Moritz ralph.moeritz at outlook.com
Tue Apr 16 16:43:17 EDT 2013


I'm trying to get Black Hole trunk to run on Windows & need to compile
different Scheme code depending on the target OS.

eg. On Unix-like OSes the following is ok:

     (compile-file-to-target "/dev/null"
                             output: fn
                             options: options))

...but on Windows `/dev/null' needs to be replaced with `\\\\.\\NUL'. In C  
I'd
do something like:

     #ifdef _WINDOWS /* or whatever */
     # define NULLDEV "\\\\.\\NUL"
     #else
     # define NULLDEV "/dev/null"
     #endif

Is there a Scheme equivalent to #ifdef et al? If the answer is `no' then  
please
tell me what you'd do in this case?

Thx,
Ralph

-- 
Using Opera's mail client: http://www.opera.com/mail/



More information about the Gambit-list mailing list