3 ms·
"Functional core" littered with classes, attr_readers, data that's not data (Curosr.new) and += imperative loops. Yikes.
by stevebmark 8y ago
"Functional core" littered with classes, attr_readers, data that's not data (Curosr.new) and += imperative loops. Yikes.
- gary_bernhardt 8y agoThe classes serve to close some functions over variables for convenience; the attr_readers serve as destructuring functions for convenience; the += replaces a recursive function for convenience and familiarity. The function with the += doesn't mutate any value and it remains pure from all callers' perspectives. You're complaining about syntax, but this screencast is about semantics.
- stevebmark 8y agoNo, something with "functional" in the title that doesn't use functions isn't related to syntax.
- gary_bernhardt 8y agoWhat is a function?