| ▲ | zelphirkalt 4 days ago | |
Instead of defining a Visitor interface and then making objects to implement the interface and then passing those objects to whatever traverses a graph or iterates through something, you pass the function, that will be called, by whatever traverses a graph or iterates through something. | ||
| ▲ | vips7L 3 days ago | parent [-] | |
Kind of like how sum types and matching are implemented in library code? Example from D here: | ||