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

inline functions #34

Open
2 of 8 tasks
ExpHP opened this issue Apr 20, 2021 · 0 comments
Open
2 of 8 tasks

inline functions #34

ExpHP opened this issue Apr 20, 2021 · 0 comments
Labels
enhancement New feature or request

Comments

@ExpHP
Copy link
Owner

ExpHP commented Apr 20, 2021

inline functions have been planned from the beginning. Basically, ECL is the only language that provides a mechanism for letting one subroutine invoke other subroutines. Therefore, in any other language, the only way to make it possible for the user to factor out any part of a script into a function would be to somehow inline it at the callsite.

Here is where we stand on these:

  • Parsing of inline functions
  • Scoping and name resolution
  • Inlining implementations
    • Implementation for the stackless lowerer
      • Registers used inside should be considered used by the function itself.
    • Implementation for the stackful lowerer
  • inline int (pass by reference) parameters
  • const string (pass by compile-time literal) parameters
@ExpHP ExpHP added the enhancement New feature or request label Apr 21, 2021
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