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

Optimize Strings.equal #4262

Merged
merged 2 commits into from
Jun 6, 2023
Merged

Conversation

CodeSandwich
Copy link
Contributor

@CodeSandwich CodeSandwich commented May 18, 2023

Fixes #NONE

It's a really small optimization avoiding hashing strings when they're obviously different.

PR Checklist

  • Tests
  • Documentation
  • Changeset entry (run npx changeset add)

@changeset-bot
Copy link

changeset-bot bot commented May 18, 2023

🦋 Changeset detected

Latest commit: a01072f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
openzeppelin-solidity Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@CodeSandwich CodeSandwich changed the title Optimize Strings equal Optimize Strings equal (one-liner) May 31, 2023
@CodeSandwich CodeSandwich changed the title Optimize Strings equal (one-liner) Optimize Strings equal (ONE-LINE PR) May 31, 2023
@frangio
Copy link
Contributor

frangio commented May 31, 2023

Thanks for the clear title. 😛

This is definitely good, we just need a changeset. Can you add it (npx changeset add) or let me know if I should do that for you.

@frangio frangio changed the title Optimize Strings equal (ONE-LINE PR) Optimize Strings.equal May 31, 2023
@frangio frangio added this to the 5.0 milestone May 31, 2023
@CodeSandwich
Copy link
Contributor Author

CodeSandwich commented May 31, 2023

I've added the changeset. Sorry for not doing it before, this PR seemed too small to litter the changelog with it, my misake 🤷

BTW you've added this PR to the 5.0 milestone, does it mean that it won't be available in 4.9.1 and 4.10 if such versions ever exist? I'm not a project maintainer, but it seems strange, it's not a breaking change or even a new feature.

Amxx
Amxx previously approved these changes Jun 1, 2023
@Amxx
Copy link
Collaborator

Amxx commented Jun 1, 2023

BTW you've added this PR to the 5.0 milestone, does it mean that it won't be available in 4.9.1 and 4.10 if such versions ever exist? I'm not a project maintainer, but it seems strange, it's not a breaking change or even a new feature.

  • If there ever is a 4.9.1, it will be about bug fixes, not about new features and optimizations.
  • We don't plan a 4.10.
  • From now on, all features and optimizations are indeed planned to be in 5.0

Co-authored-by: Hadrien Croubois <hadrien.croubois@gmail.com>
Copy link
Member

@ernestognw ernestognw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nicee, thanks!

This was referenced Sep 10, 2024
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.

4 participants