feat(static): add static package as a DCE-friendly alternative#956
Closed
vincentbernat wants to merge 1 commit intoexpr-lang:masterfrom
Closed
feat(static): add static package as a DCE-friendly alternative#956vincentbernat wants to merge 1 commit intoexpr-lang:masterfrom
vincentbernat wants to merge 1 commit intoexpr-lang:masterfrom
Conversation
The package is a drop-in replacement with two features removed: - functions in environment - Eval() method Fix expr-lang#863.
7 tasks
Contributor
Author
|
Dunno why the coverage test fails. Some benchmarks: I didn't try to adapt the benchmark for the "static" version. Maybe we will get better results. |
Member
|
I was thinking about creating a build tag: expr_nomethod. |
Contributor
Author
Yes, it should have 0 performance impact as Go should be able to eliminate the additional tests. Do you want me to do a PR for that? Most of this PR can be reused for this. Edit: I am working on it. |
Member
|
Nice! Seems like still one test is failing in coverage. |
Contributor
Author
In this pull request, yes, but not in #957. Let me close this one. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The package is a drop-in replacement with two features removed:
The changes are quite minimal and I am using
go generateto copyexpr.gotov2/expr.go. The full user interface is therefore not present inexpr.goanymore. We could keepEval()and make it panic instead.Fix #863.