Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tail Recursive Consensus #17

Open
ashwin153 opened this issue Apr 27, 2018 · 0 comments
Open

Tail Recursive Consensus #17

ashwin153 opened this issue Apr 27, 2018 · 0 comments
Labels
enhancement New feature or request

Comments

@ashwin153
Copy link
Owner

Consensus is already tail recursive; however, the Scala compiler isn't smart enough to know it. If we replace the various flatMap calls with match expressions, the Scala compiler will recognize the function as tail-call optimizable.

@ashwin153 ashwin153 added the enhancement New feature or request label Apr 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant