Re: Hiding import behaviour

2014-10-19 Thread Herbert Valerio Riedel
On 2014-10-19 at 00:39:42 +0200, Joachim Breitner wrote: I guess my central point is I don't see how anyone can benefit from the current behaviour. For instance, a simple real world example: import Prelude import Data.Text.Lazy.IO (putStrLn) I find this quite convincing. If I bother to

Re: Hiding import behaviour

2014-10-19 Thread Erik Hesselink
I feel that this extension, while looking tempting for writing code from scratch, might hurt maintainability of code. Adding an explicit import can suddenly cause type errors in completely unrelated places (when it hides an implicit import and the new function is type incorrect), or worse, can

Re: Hiding import behaviour

2014-10-19 Thread htebalaka
At least in the case where something being hidden causes an unintended type error, compiler errors could /potentially/ be aware of the extension, though defining unintended seems non-trivial. You don't want actual type errors being replaced with maybe you didn't realize this other function is

Re: Hiding import behaviour

2014-10-19 Thread htebalaka
There is one more case that I hadn't considered that would be kind of ambiguous. If you import something like import Control.Comonad (Comonad(..)) it's unclear if the compiler should automatically treat it as if you added hiding (Comonad(..)) to implicit imports, or added hiding (Comonad, extend,