Hi

> case (local,res) of
>     ([x], _) -> return x
>     (_, [x]) -> return x
>     ([], []) -> raiseError $ ErrorFileNone noErrPos askMsg file rs
>     (as, bs) -> raiseError $ ErrorFileMany noErrPos askMsg file (map
> anyOne (as ++ bs))
> ...

You are right, my patch is wrong. Here are some additional notes: At some
point, I had getModule reporting additional information using:

... raiseError $ ErrorFileMany noErrPos (askMsg++" (as,bs)=<"++show
(as,bs)++">") file (map anyOne (as ++ bs))

This resulted in the following:

Thorkil-Naurs-Computer:~/tn/test/Yhc/multiple thorkilnaur$ yhc T1.hs
yhc: Error: Found file multiple times, T2
Reason: imported from Main (as,bs)=<([],[])>
Found in:

Thorkil-Naurs-Computer:~/tn/test/Yhc/multiple thorkilnaur$

That is absolutely bizare!

This indicates that the ghc-6.6 pattern matching is not working as we expect.

I would be shocked if pattern matching was broken in GHC, that is a
fairly fundamental aspect of GHC! That said, I can't think of anything
else off hand...

Can you please try:

cd src/compiler98
touch Package.hs
ghc Package.hs -i.;../../depends/filepath -c -fext-core

Then send me Package.hcr, and I can see what GHC's translation is.
With any luck that (and a whole load of pain!) will let me figure out
what GHC is actually doing.

Thanks

Neil
_______________________________________________
Yhc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/yhc

Reply via email to