[racket] `unbound identifier' during interactive session with racket/gui

From: Diogo F. S. Ramos (diogofsr at gmail.com)
Date: Wed Jul 31 17:27:33 EDT 2013

I'm not sure how to describe this, so I'll show the steps to reproduce
it:

$ cat foo.rkt
#lang racket/gui

(define frame (new frame% (label "hello, world")))

(define canvas (new canvas% (parent frame)))

(send frame show #t)
$ cat bar.rkt
#lang racket/gui

(define frame (new frame% (label "bye, world")))

(define canvas (new canvas% (parent frame)))

(send frame show #t)
$ racket
Welcome to Racket v5.3.5.
> (enter! "foo.rkt")
> (new canvas% (parent frame))
(object:canvas% ...)
> (enter! "bar.rkt")
> (new canvas% (parent frame))
lifted.0: unbound identifier;
 also, no #%top syntax transformer is bound
  in: lifted.0
  context...:
   /usr/lib/racket/collects/racket/private/misc.rkt:87:7
> 

I can't create a new canvas when inside `bar.rkt' after creating one
when inside `foo.rkt'.

Posted on the users mailing list.