[Haskell-cafe] Local types
Imants Cekusins
imantc at gmail.com
Mon Jan 25 10:48:55 UTC 2016
>> is this not an attempt to move module functionality inside function?
> Same counter-argument can be applied to local functions.
not quite. Let's look at the current state:
Module inside module: ok (module reexport)
Type inside type: ok (data declaration etc)
Function inside function: ok (local functions)
Type / Instance / module inside function is quite a bit different
> finer granularity than module level.
by turning function into a mini module?
Currently module does not give control over instance export. Should
this not be addressed first?
This would be a step towards more complexity in syntax. While there
may be benefits, complexity always comes at a price.
> Haskell programmers are more or less used to pay the cost of abstraction.
well should we not start thinking about keeping those costs down if
possible - performance and otherwise? Ideally, minimizing them?
More information about the Haskell-Cafe
mailing list