Have you asked about this on #haskell IRC? I find the IRC channel often are
really quick to sort out what's going on with these kinds of things. I
still suspect it is some weirdness with encoding, and the folks there will
be able to say if that suspicion is totally wrong :)


On Mon, Nov 4, 2013 at 10:33 PM, Justin S. Leitgeb <notifications@github.com
> wrote:

> In compiler/Metadata/Prelude.hs:
>
> > \ No newline at end of file
> > +readDocs filePath = do
> > +  bytes <- IS.loadInterface filePath
> > +  let interfaces = bytes >>= IS.interfaceDecode filePath
> > +
> > +  -- Although every ModuleInterface that is deserialized in this collection
> > +  -- contains the compiler version, we only check the first ModuleInterface
> > +  -- since it doesn't make sense that different modules in Prelude would have
> > +  -- been compiled by different compiler versions.
> > +  case interfaces >>= firstModuleInterface >>= IS.validVersion filePath of
> > +    Left err -> do
> > +      hPutStrLn stderr err
> > +      exitFailure
> > +
> > +    -- Unwrapping the Right value here is safe since the whole above chain
> > +    -- returns a Right value. The toList/fromList is necessary because of a
>
> I tried changing a few instances to Data.ByteString.Char8 without success.
> The error that I receive involves dependencies that are in Prelude not
> being found. You can also reproduce this error in cabal repl fairly
> easily:
>
> https://gist.github.com/jsl/7294493
>
> Perhaps it could help to homogenize the serialization of the interface
> file in Setup.hs to be consistent with the way that we're reading the
> file?
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/evancz/Elm/pull/320/files#r7414173>
> .
>