3 ms·
I find myself wondering if this is getting upvoted by Haskell contrarians who aren't actually reading the article and noticing that it not about Haskell "being
by xi 16y ago
I find myself wondering if this is getting upvoted by Haskell contrarians who aren't actually reading the article and noticing that it not about Haskell "being too mathematical", but not being out-of-the-box suitable as a really convenient ring theory explorer.
I love how you, in the same sentence, managed to put in doubt credibility of the upvoters and downplay the issue in hand.
To answer your question: yes, I actually read the article. Why I upvoted it? Haskell's way of wrapping integer literals with implicit `fromInteger` seems to be a clever hack that alleviates some pain when dealing with basic arithmetics, but I always wondered what kind of unexpected problems it may cause. I got an answer in this article.
- jerf 16y ago"downplay the issue in hand." No, I don't. The issue is serious. I'm personally a proponent of tossing the current Prelude and replacing it with something more useful. I think the supposed costs are smaller than expected (it's already modular) and the benefits underestimated. I'm not a Haskell booster, I'm an interested skeptic. I just think an article about a relatively esotoric issue about Haskell got upvoted suspiciously quickly on a holiday weekend. It's not a bad article by any means.
- Confusion 16y agoHowever, you should wonder whether that is also the motivation of most other upvoters. I find the title so appallingly lacking in understanding and respect that I really couldn't care less about the contents when deciding whether to up- or downvote it. I don't doubt the same could hold for many others, only resulting in the reverse action.
- deleted 16y ago[deleted]
- applicative 16y ago`xi`, notice that if you substitute `Float` or `Double` for his `Int` throughout his module, you get the same type error he gets, as you would intuitively expect: [1 of 1] Compiling Main Ok, modules loaded: Main. *Main> p [1,2,3,4,5] <interactive>:1:11: Ambiguous type variable `t' in the constraints: If however you substitute `Integer` for `Int`, which is after all what he claims to have meant, then suddenly: [1 of 1] Compiling Main Ok, modules loaded: Main. *Main> p [1,2,3,4,5] (5x^4 + 4x^3 + 3x^2 + 2x + 1) *Main> :t it it :: UnivariatePolynomial Integer It seems, then, that if he had known that in Haskell the 'integer' type is called Integer, not Int, he wouldn't have had any difficulty, or any blog post, or any occasion unjustly to malign his teachers `conal` and `mauke`, to whom he ought rather to be grateful.