←back to thread

873 points belter | 1 comments | | HN request time: 0.214s | source
Show context
gorjusborg ◴[] No.42947212[source]
No, objects aren't generally 'good', unless you think keeping multiple state machines in sync is 'good'.

OO is not evil, but it also shouldn't be your default solution to everything.

Also, who is this person? I immediately distrust someone who calls themselves 'a pretty cool guy'. That's for the rest of us to decide.

replies(4): >>42948148 #>>42948743 #>>42949044 #>>42949626 #
Insanity ◴[] No.42948148[source]
I had a different read of that point. More along the lines of “don’t throw the baby out with the bath water” (might have butchered that saying?).

I’m also more in the FP camp - even wrote a book on the topic of FP. But I also acknowledge OO is not inherently a bad choice for a project, and many languages nowadays do exist along a spectrum of OO and FP rather than being strictly one of the other.

To me a benefit for OO might be the ubiquity - you can generally assume people will understand an OO codebase if they have done a few years of coding. With more strict FP that is just not a given - even if people took a Haskell course in Uni a decade ago :).

replies(1): >>42948249 #
latexr ◴[] No.42948249[source]
> More along the lines of “don’t throw the baby out with the bath water” (might have butchered that saying?).

No, you got it right.

https://en.wikipedia.org/wiki/Don't_throw_the_baby_out_with_...

> even wrote a book on the topic of FP.

Care to share? If not, that’s fine.

replies(1): >>42948607 #
1. Insanity ◴[] No.42948607[source]
Sure, “Functional Programming in Go”, this is the Amazon link: https://a.co/d/htv3BOu