Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
codygman
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
41 ms
·
151.
▲
by
codygman
9y ago
Yep, I've missed apostrophe's quite a few times. It's was a common cause of infinite loops for me in the past, but I suppose I've trained myself to spot them more quickly. Perhaps zip can be more simply explained by a si
152.
▲
by
codygman
9y ago
I made a more compact version closer to what I might write in a hurry. {-# LANGUAGE OverloadedStrings #-} module Main where import Prelude hiding (appendFile) import Data.Monoid ((<>)) import Network.Wreq
153.
▲
by
codygman
9y ago
Eh, I had a mistake. {-# LANGUAGE OverloadedStrings #-} module Main where import Prelude hiding (appendFile) import Data.Monoid ((<>)) import Network.Wreq import Control.Lens import Control.Concurren
154.
▲
by
codygman
9y ago
Well it's 51 minutes later, and I got to the third bullet point :D EDIT: I tried to focus on readability here. Things could be quite a bit more concise but that requires firmer grasp of interactions between >>=, <$>, and po
155.
▲
by
codygman
9y ago
I only have about 20 extra minutes, but I'll see if I can give a Haskell version for comparison.
156.
▲
by
codygman
10y ago
>> In Haskell (or indeed in C) it doesn't necessarily have performance implications; an 8-element structure may have exactly the same runtime representation as those 8 elements being passed distinctly. > Wow, okay, this conver
157.
▲
by
codygman
10y ago
> To be honest, I have never used one in anger, but if you told me to go write a production grade regex engine in Agda and Coq, I'd say you're nuts. It sounds like a fine experiment to do given infinite time, but I want people
158.
▲
by
codygman
10y ago
I've toyed around with using this example: Imagine C++ template programming with C++ syntax, sane error messages, and ability to use any C++ code.
159.
▲
by
codygman
10y ago
Haskell doesn't deserve it's own bullet point yet? It's used at Facebook, I don't think esoteric is a fair classification anymore!
160.
▲
by
codygman
10y ago
> Go doesn't go beyond Java level safety Go doesn't reach Java level safety because of a lack of generics.
161.
▲
by
codygman
10y ago
> Haskell doesn't really target industry, never has and never will. There are contributors to ghc who add features or fix bugs with "industry use" in mind. So your statement in its current form is a bit confusing to me. C
162.
▲
by
codygman
10y ago
If you used newtypes for z and x it would have been caught.
163.
▲
by
codygman
10y ago
> 1. Types don't enforce meaning Why do you think this? > Haskell style types only work as far as they enforce meaning. Doesn't this contradict your statement above or are you saying Haskell style types never work because t
164.
▲
by
codygman
10y ago
> You can't do that in Haskell either, and any FP purist What about us FP pragmatists? Also in some domains I'd argue being a FP purist is the most pragmatic option.
165.
▲
by
codygman
10y ago
That sounds less to do with quality and more to do with exposure to the functional paradigm.
166.
▲
by
codygman
10y ago
After quickly scanning https://realworldocaml.org/v1/en/html/variants.html , isn't the same thing accomplished by GADTs?
167.
▲
by
codygman
10y ago
I upvoted you for the IO part of your comment, but contend purity is a very big feature. More focus needs to be on reasoning about real world tasks where is needed though.
168.
▲
by
codygman
10y ago
Hoogle also exists to allow users to search for functions by type signature, not mentioning that is an unfair mischaracterizes.
169.
▲
by
codygman
10y ago
> For example, hashmaps are largely unnecessary in Haskell, and you find out why the more you use it. I use Haskell quite a bit and I don't know what you would use instead of a strict hashmap for something like O(1) lookups in an ap
170.
▲
by
codygman
10y ago
Wasn't quite ready to release this, but it seems relevant so see part two here: https://github.com/codygman/concise-json-parsing-in-haskell/... Please give feedback if you don't mind. I'd also like
171.
▲
by
codygman
10y ago
A bug report that is a good example of how to read core, at least it seemed easy to tie the very simplistic code to the expanded core in combination with the commentary. https://ghc.haskell.org/trac/ghc/ticket/
172.
▲
by
codygman
10y ago
> If the material is taught in high school, then educators must have decided that high schoolers can learn it, right? Did you miss that I said it wasn't taught in my school?
173.
▲
by
codygman
10y ago
That's quite presumptuous. The real reason is that Go programs can panic for silly things.
174.
▲
by
codygman
10y ago
> I like Go specifically because it is boring. I dislike Go because it's resulting programs are not boring. So many things can and do panic.
175.
▲
by
codygman
10y ago
> For a language with such powerful types, it's like a gun with no bullets lacking a good IDE to take full advantage. Agreed, though hare is trying (has, but needs editor integrations?) to address this: https://github.com
176.
▲
by
codygman
10y ago
What language don't you have to do that in where not doing so also won't change behavior and result in an error?
177.
▲
by
codygman
10y ago
High schools taught calculus outside of honors programs? My high school only went to algebra 1.5
178.
▲
by
codygman
10y ago
> Mathematical functions are taught in school. That function composition is associative and every set has an identity function, this is stuff that every high school graduate should know. As a haskeller myself I wholeheartedly disagree. I
179.
▲
by
codygman
10y ago
Most people don't Immediately go to learning foundations like that without having an idea of what they'll get out of it first, is the problem. For example, the poster you replied to can only see the advantage being that his questi
180.
▲
by
codygman
10y ago
Reposting my message to evincarofautumn to you as well: If you aren't planning on submitting that to those docs I will. In fact I'm sure many would find you adding examples along those lines to the most popular but math inspired H
More ›