[plt-scheme] require: broken compiled code (phase 0): cannot find module |,X:\ants\geometry| in: sensed-cell

From: ifconfig (nslookupifconfig at hotmail.com)
Date: Mon Jun 7 13:32:01 EDT 2004

First of all, it was indeed a stupid error.
Second, I forgot to mention that error also happens on Check Syntax.
Third, I have reproduced the problem in smaller scale with test-a.ss and
test-b.ss:

(module test-a mzscheme
  b
  (require "test-b.ss"))

(module test-b mzscheme
  (define b "Hello, world!\n")
  (provide b))

[Error-message: require: broken compiled code (phase 0): cannot find =
module
|,u:\test-b| in: b]

This does not happen if I change test-a.ss to

(module test-a mzscheme
  (display b)
  (require "test-b.ss"))

Or to

(module test-a mzscheme
  (require "test-b.ss")
  b)

But does happen with

(module test-a mzscheme
  (newline)
  b
  (require "test-b.ss"))

Any idea why using an identifier by itself would cause a different
behaviour? The last module was tested to make sure that it's not using =
it as
some sort of weird third-parameter to "module" (as in (module a b c
(code))).

ifconfig.



-----Original Message-----
From: John Clements [mailto:clements at brinckerhoff.org]=20
Sent: Monday, June 07, 2004 3:59 PM
To: ifconfig
Cc: plt-scheme at list.cs.brown.edu
Subject: Re: [plt-scheme] require: broken compiled code (phase 0): =
cannot
find module |,X:\ants\geometry| in: sensed-cell


On Jun 4, 2004, at 9:40 PM, ifconfig wrote:

> I made a module that uses a variable before its require:
>
> (module check-syntax mzscheme
>
> =A0 sensed-cell
>
> =A0 (require "biology.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "cells.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "deaths.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "exceptions.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "geography.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "geometry.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "global.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "markers.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "randomint.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "senses.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "step.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "tokens.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "world-ants.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "world-file-input.ss"
>
> =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 "world-file-output.ss"))
>
> =A0
>
> I got this error message:
>
> require: broken compiled code (phase 0): cannot find module=20
> |,X:\ants\geometry| in: sensed-cell
>
> =A0
>
> But when I made the following two modules (Pretty big language):
>
> =A0
>
> (module d mzscheme
>
> =A0 (define b display))
>
> =A0
>
> (module a mzscheme
>
> =A0 (define c 5)
>
> =A0 (b c)
>
> =A0 (require d))
>
> =A0
>
> =A0
>
> I got this error message:
>
> expand: unbound variable in module in: b
>
> =A0
>
> Why are the error messages different?
>
> Is this some sign of a different error?
>


Well, for one thing, you forgot to "(provide b)" in module d.  That=20
would account for the error you got.  Fixing this makes the error go=20
away:

(module d mzscheme
   (provide b)
   (define b 14))

(module c mzscheme
   (printf "value of b: ~v\n" b)
   (require d))

(require c)

=3D=3D>
value of b: 14



Don't know what causes the error you reported, though.

john



Posted on the users mailing list.