[plt-scheme] `load` from custom port?

From: YC (yinso.chen at gmail.com)
Date: Wed Jun 25 22:35:35 EDT 2008

On Wed, Jun 25, 2008 at 6:31 PM, Matthew Flatt <mflatt at cs.utah.edu> wrote:

> > Yeah that's what I'm doing now - I was hoping there is a way to customize
> > mzscheme at this level without having to provide my own `load` and `read`
> > family symbols - oh well ;)
> Does it work to set the load handler via `current-load'?

`current-load` expects a load-handler to take in a path and a symbol/false
for module loading.  So yes theoritically I can handle the path resolver
here, but that requires me to be intimately familiar with how to load a
module -- unfortunately I do not.

So my choice was to either customize load (so I can use default-load-handler
to handle loading modules) or to customize below default-load-handler (via
something like `current-load-handler-path-resolver` that takes the path and
returns an input-port) to provide file port abstraction.

Are there other approaches?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20080625/c0e5fb2c/attachment.html>

Posted on the users mailing list.