[plt-scheme] dynamic require

From: Hans Oesterholt-Dijkema (hdnews at gawab.com)
Date: Thu Jun 2 18:08:45 EDT 2005


I'd like to do something like this:

;; Load the right sqld-driver
(define driver "psql")


(define load
   ((string=? driver "oracle")
   ((string=? driver "sqlite")
   ((string=? driver "psql")
    (error "DRIVER unknown"))))
(require load)

Is this somehow possible in mzscheme?

Thanks in advance for answers,

Hans Oesterholt

Posted on the users mailing list.