[plt-scheme] FFI stuff: getting a fileno file descriptor from an input port?

From: Danny Yoo (dyoo at hkn.eecs.berkeley.edu)
Date: Fri Sep 2 00:12:02 EDT 2005

> Is there a nice runtime way to know if one is running under mzscheme3m
> or mzscheme?  How do people write FFI extensions that are supposed to
> interact with both the conservative and precise collectors?

Followup: Ok, that was another stupid question of mine.  I see
system-library-subpath now.  This should let me find out if I'm running
with the precise or conservative collector by just doing:

  (define (running-as-3m?)
    (let-values (((base name must-be-dir)
                        (split-path (system-library-subpath #t))))
      (equal? name (build-path "3m")))))

Sorry for the silly question!



Posted on the users mailing list.