Skip to content

Conversation

@jbgi
Copy link

@jbgi jbgi commented May 15, 2016

Gof visitor example has been fixed by f1f498d

... but then it leaves a clearly inferior lambda visitor implementation which does not guarantee at compile time that all 3 cases are handled (plus the implementation would not work for generic classes). This guarantee is what make the visitor pattern superior to using instanceof.

Hopefully this can be easily fixed with a little help from https://github.com/derive4j/derive4j (or equivalent manually written code).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant