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

Move template expansion / replacement to Go #103

Merged
merged 1 commit into from
Jun 5, 2024

Conversation

anuraaga
Copy link
Collaborator

@anuraaga anuraaga commented Jun 5, 2024

The regexp library is slow at executing expressions but is not bottlenecked in actual template expansion / building result strings. We can avoid trickiness related to malloc by using re2 only for finding the matches and doing the replacement natively.

Also fixes handling of character skipping in submatch search, which is only tested for replacement but not searching in the tests copied from upstream

Fixes #102

@anuraaga anuraaga merged commit db45b50 into wasilibs:main Jun 5, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

memory corruption on malloc failure
1 participant