[racket] Call racket with long code from racket
Niitsuma Hirotaka wrote at 09/08/2011 04:35 PM:
> I am trying to call racket with long code from racket
> -----------
> #lang racket
> (require racket/system)
> (display (port->string (car (process "racket -e ' [long-code] ' "))))
> -----------
>
> But long-code contain " and ' .
> Thus
>
> (process "racket -e ' [long-long-code] ' "))
>
> does not work.
>
> How to call racket with long code ( contain " and ' ) from racket
>
> Saving long-code into file can not use. Because this is part of web application.
>
You can use "process*" instead of "process".
You can use "eval-string".
If those ways are not satisfactory, you can use processes and ports in
more elaborate ways.
--
http://www.neilvandyke.org/