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

Removes glob import of AccountsHashVerificationError #34332

Conversation

brooksprumo
Copy link
Contributor

Problem

Well... today I learned about glob imports of enums and how they interact with match statements. Basically, glob imports of an enum that are used with a match can be a footgun. Refer to this playground:

https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=9f0ce5f074f7b4a71f487ae8c6a1902d

Summary of Changes

Removes glob import of AccountsHashVerificationError. (I know that there are no matches here, but glob imports are best avoided when possible.)

@brooksprumo brooksprumo self-assigned this Dec 6, 2023
@brooksprumo brooksprumo marked this pull request as ready for review December 6, 2023 06:09
Copy link

codecov bot commented Dec 6, 2023

Codecov Report

Merging #34332 (bcc1f8e) into master (5c00a33) will increase coverage by 0.0%.
Report is 2 commits behind head on master.
The diff coverage is 81.8%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #34332   +/-   ##
=======================================
  Coverage    81.9%    81.9%           
=======================================
  Files         819      819           
  Lines      220422   220425    +3     
=======================================
+ Hits       180652   180669   +17     
+ Misses      39770    39756   -14     

@brooksprumo brooksprumo requested a review from HaoranYi December 6, 2023 17:48
Copy link
Contributor

@HaoranYi HaoranYi left a comment

Choose a reason for hiding this comment

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

lgtm

@brooksprumo brooksprumo merged commit b32903a into solana-labs:master Dec 6, 2023
33 checks passed
@brooksprumo brooksprumo deleted the use-enum/accounts-hash-verification-error branch December 6, 2023 18:46
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