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

Clean up all but import warnings #28

Merged
merged 3 commits into from
Apr 15, 2024
Merged

Clean up all but import warnings #28

merged 3 commits into from
Apr 15, 2024

Conversation

erikreppel
Copy link
Contributor

Clean up a bunch of compiler warnings

@erikreppel erikreppel marked this pull request as ready for review April 15, 2024 14:17
@erikreppel erikreppel requested a review from ligustah April 15, 2024 14:17
@@ -27,23 +27,21 @@ where
.await
.map_err(|err| eyre::eyre!("Error calling contract: {:?}", err))
.and_then(|response| {
T::abi_decode_returns(&**response, false)
T::abi_decode_returns(&response, false)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Does this change the behavior? I saw it used in another context where the double ** was apparently required

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I thought it did but turns out its redundant, the compiler is gonna take a a copy of the reference automatically

@@ -25,7 +24,7 @@ pub struct Chains<N>(Vec<Chain>, Cache<String, Arc<ChainListProvider<N>>>)
where
N: Network;

pub static CHAINS: Lazy<Chains<Ethereum>> = Lazy::new(|| Chains::new());
pub static CHAINS: Lazy<Chains<Ethereum>> = Lazy::new(Chains::new);
Copy link
Collaborator

Choose a reason for hiding this comment

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

Oh, nice. Didn't know that worked!

@erikreppel erikreppel merged commit 04df4be into main Apr 15, 2024
2 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.

2 participants