3 ms·
> Haskell code has the unfortunate property that the types of the functions are harder to understand than their implementations. Interesting point. What is the
by galaxyLogic 4y ago
> Haskell code has the unfortunate property that the types of the functions are harder to understand than their implementations.
Interesting point. What is the purpose of type-declarations? To make implementation easier to understand, I think. When you know (and understand) the type of a component or function you know how to use it, and how to not use it, and thus how to write code that uses it and does what you think it should do.
But if types are harder to understand than the implementation, then types don't help much, do they?
- axman6 4y agoOn the contrary, when you can move your complexity into the type system, the. You have just taught your compiler how to check that you are using things correctly, and that is insanely useful in large scale software.