[racket-dev] replacing current-load/use-compiled

From: Tobias Hammer (tobias.hammer at dlr.de)
Date: Thu Jan 17 07:21:15 EST 2013

maybe there is a better way but you can write a little wrapper that  
changes the handler:

;; --- wrap.rkt
(begin-for-syntax
  (require racket/base)
  (define old-handler (current-load/use-compiled))

  (current-load/use-compiled
   (lambda args
     (printf "inside handler ~a\n" args)
     (apply old-handler args))))

start with
racket -f wrap.rkt -t <your-file.rkt>

Tobias


On Wed, 16 Jan 2013 18:49:12 +0100, Dan Liebgold <dan.liebgold at gmail.com>  
wrote:

> Does anyone know if there's a way to replace current-load/use-compiled at
> startup time without changing cstartup.inc and rebuilding executables?
>


-- 
---------------------------------------------------------
Tobias Hammer
DLR / Institute of Robotics and Mechatronics
Muenchner Str. 20, D-82234 Wessling
Tel.: 08153/28-1487
Mail: tobias.hammer at dlr.de

Posted on the dev mailing list.