Skip to content

feat(precompiles): add performant PrecompileError::OtherCowStr variant#3144

Merged
rakita merged 6 commits intomainfrom
rakita/precompile-error-other-str
Nov 10, 2025
Merged

feat(precompiles): add performant PrecompileError::OtherCowStr variant#3144
rakita merged 6 commits intomainfrom
rakita/precompile-error-other-str

Conversation

@rakita
Copy link
Member

@rakita rakita commented Nov 5, 2025

Using &'static str does not require creating a string so it is more performant.

@codspeed-hq
Copy link

codspeed-hq bot commented Nov 5, 2025

CodSpeed Performance Report

Merging #3144 will not alter performance

Comparing rakita/precompile-error-other-str (5eda9b4) with main (eb1d49f)

Summary

✅ 173 untouched

@rakita rakita changed the title feat(precompiles): add performant PrecompileError::OtherStr variant feat(precompiles): add performant PrecompileError::OtherCowStr variant Nov 10, 2025
@rakita rakita merged commit d762d4b into main Nov 10, 2025
30 checks passed
@rakita rakita deleted the rakita/precompile-error-other-str branch November 10, 2025 18:41
@github-actions github-actions bot mentioned this pull request Nov 10, 2025
theochap pushed a commit to ethereum-optimism/optimism that referenced this pull request Jan 21, 2026
bluealloy/revm#3144)

* feat(precompiles): add performant PrecompileError::OtherStr variant

* Apply suggestion from @rakita

* use cow

* rm Other(String) and use Other(Cow<'static,str>)

* fn other_static

* revert api change
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.

2 participants