Re:I'm Betting on Call-by-Push-Value
by erik_seaberg on Saturday March 09, 2024 @07:15PM
(#39655681)
Not sure I see a difference between thunks and futures.
[ Parent
| on HN ]
Thunk is a general concept of a small function which is used only to adapt the call or prepare/modify it in some way and then redirect to the proper function. Things like promises, futures, closures, wrappers, stubs or implementations of the concept of virtual function tables in some OO languages (like C++) are just special use cases of thunks (thunks are often used to implement them).
Re:I'm Betting on Call-by-Push-Value
by soulbadguy on Saturday March 09, 2024 @07:49PM
(#39655860)
The definition that the source is using seems wrong to me. Promise,futures and closures are not used to redirect to anything or wrapper around something else... They are proper compationational object with they own behaviors...