Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
MasonOfSpoons
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
4 ms
·
1.
▲
by
MasonOfSpoons
6y ago
It feels a bit like a rhetorical device to discuss OOP in any context other than the version of Java that's currently in widest usage.
2.
▲
by
MasonOfSpoons
6y ago
Pure functional languages are capable of this, although they likely aren't modeling it as you envision. Pure record constructors let you do perform arbitrary mutation on the stack (e.g. calling other functions to build field values),
3.
▲
by
MasonOfSpoons
6y ago
It really isn't, as OOP languages don't traditionally provide robust mechanisms around immutability. And why would they? The core design of OOP is to wrap mutable state behind methods which control that mutation. OOP was in man