On May 11, 2015, at 4:22 PM, Alexis King <lexi.lam...@gmail.com> wrote:

> I’ve gotten my curly-fn meta-language working, and it works great within a 
> module. However, evaluating #{+ 2} within the REPL just evaluates as a plain 
> old vector, ignoring my readtable extension.
> 
> What gives? Using @-expression syntax in the REPL works just fine when using 
> the at-exp meta-language, which seems pretty similar to my approach.

To do that, you’d have to use language-info as described in:
http://docs.racket-lang.org/guide/module-runtime-config.html

The at-exp language does that with this code here:
https://github.com/plt/racket/blob/master/pkgs/at-exp-lib/at-exp/lang/reader.rkt#L34
https://github.com/plt/racket/blob/master/pkgs/at-exp-lib/at-exp/lang/language-info.rkt
https://github.com/plt/racket/blob/master/pkgs/at-exp-lib/at-exp/lang/runtime-config.rkt


Also, have you seen
https://github.com/AlexKnauth/afl
The afl language supports #λ(...), #fn(…) and #lambda(…) in the repl by doing a 
similar thing:
https://github.com/AlexKnauth/afl/blob/master/afl/lang/reader.rkt#L28
https://github.com/AlexKnauth/afl/blob/master/afl/lang/language-info.rkt
https://github.com/AlexKnauth/afl/blob/master/afl/lang/runtime-config.rkt


-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to