Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
codygman
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
72 ms
·
691.
▲
by
codygman
12y ago
How would you do decode this json in a type safe way using Go? {"purchaseType": "Rent","price": 0.99,"title": "inception"} Here is an implementation in Haskell: {-# LANGUAGE D
692.
▲
by
codygman
12y ago
> STM (Software transaction model) I thought this was software transactional memory? Java has an implementation?
693.
▲
by
codygman
12y ago
A related musing about Go I wrote somewhere else before... Option types as well as lack of support for things like either and generics are why Go quickly became unappealing to me for real world work. Check out this haskell example (note tha
694.
▲
by
codygman
12y ago
> I believe Go is the future and I recently tried to push Go in using it to write a new semi-real time system to handle many little messages with complex business logic but nope CTO went with node.js and have a callback hell. I used to t
695.
▲
by
codygman
12y ago
> design it right using channels, constructs like Futures and Promises aren't necessary Careful implying that using futures and promises are incorrect unless you can prove that channels can do anything futures and promises can do wh
696.
▲
by
codygman
12y ago
> Writing in those other languages was indeed a hellish experience - it was very clear that they lacked the expressivity to model half of even just this very core piece. This is something that keeps sending me back to Haskell, I'm g
697.
▲
by
codygman
12y ago
If I recall correctly those libraries aren't type safe and composable, but perhaps I'm remembering wrong.
698.
▲
by
codygman
12y ago
What would the advantages of spectrwm be if you could configure Xmonad with a text file?
699.
▲
by
codygman
12y ago
Probably? https://news.ycombinator.com/item?id=9018229
700.
▲
by
codygman
12y ago
> debugging 2 different codes, where the second one is machine generated. After that you try to work around on the first to make the generated one do what you want. Please forgive me for the accusation, but I've heard many people sa
701.
▲
by
codygman
12y ago
I've been using this and it's pretty nice. See a real world example in this pull request: https://github.com/Gabriel439/Haskell-Turtle-Library/commit/...
702.
▲
by
codygman
12y ago
Unrelated but you don't have contact information and this is the most related thread I could find. Here is context: " I've been trying to get my mind around this kind of stuff for maybe a year. And I have to say that monads d
703.
▲
by
codygman
12y ago
> However, one thing you're unlikely to find in OCaml and which is unfortunately not uncommon in Haskell is functions with a long list of positional parameters (since you have named arguments) or different versions of the same funct
704.
▲
by
codygman
12y ago
> Stateful is just so much more productive. There are a few reasons for this: If I want to make a game, there's no good functional framework. > my goto language is Python because I know for a fact that their libraries work and th
705.
▲
by
codygman
12y ago
Oh, I'm going to have to see if I can use Turtle with IHaskell tomorrow! 0: http://gibiansky.github.io/IHaskell/ 1: https://registry.hub.docker.com/u/gregweber/ihaskell/
706.
▲
by
codygman
12y ago
Imagine a super-charged version of the method where Java Architects make class hierarchies and interfaces for offshore/contract programmers. I think FP (and contract based programming) would do a much better job than Java for varying q
707.
▲
by
codygman
12y ago
> OCaml is a good language, but I would recommend against it. Like F#, it has some syntactic and semantic conveniences that Haskell lacks. I haven't had a chance to use OCaml or F# yet, what syntactic and semantic conveniences are y
708.
▲
by
codygman
12y ago
What about: http://wiki.inkscape.org/wiki/index.php/CompilingMacOsX#Comp...
709.
▲
by
codygman
12y ago
How do they compare in practice might be too broad a question, I'm willing to bet you'd get more responses if you asked for comparisons in certain use cases.
710.
▲
by
codygman
12y ago
Maybe, but if/else is more approachable especially if you haven't seen that pattern before.
711.
▲
by
codygman
12y ago
In Haskell I wouldn't write a test to verify a type that is already guaranteed.
712.
▲
by
codygman
12y ago
In Haskell I wouldn't write a test to verify that it's already guaranteed.
713.
▲
by
codygman
12y ago
I think we can agree the construction of the actions as pure. I'm not sure about after those actions are realized in main.
714.
▲
by
codygman
12y ago
> FP like Haskell have yet to prove their worth in production environments Huh? What is your definition of proving worth in a production environment? Did you hear recently about bond? It's written in haskell by Microsoft and used in
715.
▲
by
codygman
12y ago
I've never understood claims that function keys are convenient, but I guess it's because I don't use them that much.
716.
▲
by
codygman
12y ago
You might want to look at Haskell again and not read too much into the type theory stuff at first, but learn how to use common monads, functors, etc. Here's some code that might be convincing and understandable (correct me if I'm
717.
▲
by
codygman
12y ago
> imperative and side-effect programming (which often the most readable and understandable way to write code) Oh come on, at least provide a couple examples with a claim like that... > One thing that I disliked about Haskell is that i
718.
▲
by
codygman
12y ago
> Haskell vs Python (more secure) If you mean comparing type systems there isn't much of a debate!
719.
▲
by
codygman
12y ago
Oh! I know what you are talking about and remember the issue. You had/have to add `setWMName "LG3D"' to the configuration since versions older than Java 7 don't include Xmonad on their hardcoded list of suppported w
720.
▲
by
codygman
12y ago
Since I use Xmonad as my window manager, I'm rather invested in you elaborating on Xmonad being "fairly buggy". Should I worry about my data?
More ›