On Saturday, 20 April 2019 23:55:50 UTC+1, Stephen Chang wrote:
>
> fwiw, I think here is a working version along the lines of your
> original attempt.
>
I see what you did there. This is both icky (as requested) and cute :0
Thanks, it's actually illuminating
--
You received this message b
fwiw, I think here is a working version along the lines of your
original attempt.
#lang racket
(require (for-syntax syntax/parse))
(define-syntax set/define
(syntax-parser
[(_ h k v)
#:when (with-handlers ([exn:fail:syntax:unbound? (lambda _ #f)])
(local-expand #'h 'expre
identifier-binding returns #f for top-level bindings. I believe
make-base-eval is evaluating expressions at top-level.
On Sat, Apr 20, 2019 at 4:56 PM Ryan Kramer wrote:
>
> Below is a short example showing that identifier-binding doesn't seem to work
> quite right with Scribble's make-base-eval
The third argument to identifier-binding, top-level-symbol?, controls the
result of identifier-binding when the identifier is bound to a top-level
binding (and both the REPL and sandboxed evaluators are kinds of top-level
evaluation). The docs elaborate this way:
> The result is (list source-id)
4 matches
Mail list logo