
Clang (and recent GCC versions) do something like this in error
messages. They say
MyString (aka std::string<...lots of junk...>) is uncool
maybe a similar system would help you?
Cheers,
Gabor
On 6/16/15, Ömer Sinan Ağacan
Hi all,
While working with complex types with lots of arguments etc. errors are becoming annoying very fast. For example, GHC prints errors in this way:
Expected type: <type without any synonyms> Actual type: <type with synonyms>
Now I have to expand that synonym in my head to understand the error.
I was wondering if implementing something like this is possible:
In type error messages, GHC also prints types that are cleaned from type synonyms. Maybe something like this:
Expected type: <type1> (without synonyms):
Actual type: <type2> (without synonyms): If this is not always desirable for some reason, we can hide this behavior behind a flag.
What do GHC devs think about this? Is this, in theory, possible to do? How hard would it be to implement this?
Thanks. _______________________________________________ ghc-devs mailing list ghc-devs@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs