Re:Simplify Your Code: Functional Core, Imperative Shell
by rcleveng on Monday October 27, 2025 @03:58PM
(#45725580)
If your language supports generators, this works a lot better than making copies of the entire dataset too.
[ Parent
| on HN ]
Re:Simplify Your Code: Functional Core, Imperative Shell
by KlayLay on Monday October 27, 2025 @04:40PM
(#45726017)
You don't need your programming language to implement generators for you. You can implement them yourself.
Re:Simplify Your Code: Functional Core, Imperative Shell
by akshayshah on Monday October 27, 2025 @05:00PM
(#45726236)
Sometimes, sure - but sometimes, passing around a fat wrapper around a DB cursor is worse, and the code would be better off paginating and materializing each page of data in memory. As usual, it depends.