> So.... this is just a fancy name for the advice "give your functions a name"?
Not quite: "defunctionalization" is a name for replacing functions with not-functions (data structures). (And IMO it's the most unfancy name one can give to that activity, as the name literally just indicates "removing functions"... I can't think of a less fancy name for it: maybe "un-function-ize"? But that's pretty much the same as "defunctionalization".)
BTW I recommend reading the 3 linked articles in this order:
Not quite: "defunctionalization" is a name for replacing functions with not-functions (data structures). (And IMO it's the most unfancy name one can give to that activity, as the name literally just indicates "removing functions"... I can't think of a less fancy name for it: maybe "un-function-ize"? But that's pretty much the same as "defunctionalization".)
BTW I recommend reading the 3 linked articles in this order:
1. https://blog.sigplan.org/2019/12/30/defunctionalization-ever...
2. http://www.pathsensitive.com/2019/07/the-best-refactoring-yo... (with accompanying video)
3. https://www.gresearch.co.uk/article/defunctionalisation/ (this one actually shows how you can incrementally adopt this)