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

Properly tail recursive functions in VeLa #364

Open
dbenn opened this issue Jul 15, 2023 · 0 comments
Open

Properly tail recursive functions in VeLa #364

dbenn opened this issue Jul 15, 2023 · 0 comments
Assignees
Labels
VeLa VStar expression Language

Comments

@dbenn
Copy link
Collaborator

dbenn commented Jul 15, 2023

Detecting and handling properly tail recursive functions, e.g. to allow loops.

Detection:

  • final AST in function is a recursive call, or
  • final select AST consequent is a recursive call

Thoughts:

  • compiling VeLa would do it;
  • continuation passing vs direct style combined with iteration;
  • loop that invokes Java code that handled this: do...while(tailCall && !finished);
  • need to detect leaf nodes in relevant part of AST (function, selection statement in function) that are calls to the currently activated function.
@dbenn dbenn added the VeLa VStar expression Language label Jul 15, 2023
@dbenn dbenn self-assigned this Jul 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
VeLa VStar expression Language
Projects
Development

No branches or pull requests

1 participant