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

Add support for ConstExpr #84

Closed
antonmedv opened this issue Jan 21, 2020 · 2 comments
Closed

Add support for ConstExpr #84

antonmedv opened this issue Jan 21, 2020 · 2 comments
Labels

Comments

@antonmedv
Copy link
Member

Add support for constexpr:

expr.Compile("foo(...)", expr.Env(env{}), expr.ConstExpr("foo"))

If helper declared as constexpr with expr.ConstExpr(string), it (helper) should be treated as a pure function. Compile will evaluate it during compile and replace it with the result.

@antonmedv
Copy link
Member Author

@davidklassen

@antonmedv
Copy link
Member Author

Implemented in #96

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant