In the new GHCi system we plan to make it *required* that the module name
and the file name
match, EXCEPT for module Main.

This seems to remove a whole class of errors.

Yell if that'll be problematic for you

Simon

| -----Original Message-----
| From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
| Sent: 18 August 2000 19:45
| To: [EMAIL PROTECTED]
| Subject: My mistake is harder to diagnose than it could be
| 
| 
| I've just done the same mistake a third time: took a module A, moved
| part of it to a new module B, imported A from B, but forgot to change
| the module header in B which still said "module A".
| 
| The GHC's answer to that when compiling B.hs is that the module A
| does not export a bunch of things (if listed explicitly in import),
| or that they are not found at all (if imported the whole A). Things
| that are easily seen exported from A.hs - strange that I was wondering
| again what's going on.
| 
| GHC should warn when a module imports itself. Or warn about mismatches
| between the module and file name except Main. Or whatever - 
| the current
| error message is not very helpful.
| 
| -- 
|  __("<  Marcin Kowalczyk * [EMAIL PROTECTED] http://qrczak.ids.net.pl/
|  \__/
|   ^^                      SYGNATURA ZASTEPCZA
| QRCZAK
| 
| 

_______________________________________________
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to