On Jun 2, 2016, at 10:39 AM, Jack Firth <jackhfi...@gmail.com> wrote:
> 
> I think you can do this by having your language provide it's own #%top syntax 
> that defines what to do with unknown variables. 

IIUC `#%top` can only provide fallback behavior at runtime, right? AFAICT it 
doesn't help with definitions missing at compile time:

;;
#lang racket

(define-syntax-rule (#%top . id)
  (define id 42))

(set! f 1) ; still an error, because `f` isn't bound at the end of expansion
;;


Also, variables that are NOT assigned in the program should still throw 
unbound-identifier errors (in the REPL, say). Thus, any kind of auto-definer 
would still need to distinguish the two sets, which leads back to the original 
problem, I think.

-- 
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