From: Asumu Takikawa <as...@ccs.neu.edu>
Date: Sun, 18 Nov 2012 21:31:49 -0500
Local: Sun, Nov 18 2012 9:31 pm
Subject: Re: [racket] submodule paths and DrRacket
On 2012-11-18 21:10:25 -0500, Harry Spier wrote:
> Case 1 as follows works in the DrRacket Definitions window but doesn't
In the definitions window, the use of #lang implicitly wraps the entire
> work in the Interactions window > #lang racket
> (module m racket
contents of the window in a module. This allows the use of relative submodule references to module `m`. In the interactions window, you are defining top-level modules instead.
(module around racket
> Case 2 as follows works in the DrRacket Interactions window but doesn't
This time, it works in the interactions window because they are both
> work in the Definitions window > > (module m racket
top-level modules. Within a module, you can't refer to the parent's submodules directly with a quoted name. > Also is there a way to have
Yes. Suppose the first snippet is defined in "foo.rkt". Then you can
> #lang racket
> (module m racket
> in the definitions window but the following in the interactions window
> >(module n racket
just have (require (submod "foo.rkt" m)) if you're in the right directory. Cheers,
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||