You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A minimal reproduction I could come up with, where the incorrect message shows:
use std::marker::PhantomData;structMyStruct<A,B>{_pd:PhantomData<*const(A,B)>,}traitTraitA{}impl<A,B>MyStruct<A,B>whereA:TraitA,{fncall(&self,_arg:()){}}impl<B>MyStruct<(),B>{fncall(&self){}}fnmain(){let my_struct:MyStruct<(),()> = MyStruct{_pd:PhantomData};
my_struct.call();}
In main's my_struct.call(), rust-analyzer complains that: expected 1 argument, found 0.
My understanding is that it is only looking at the first call implementation, but my_struct concrete type actually matches the second impl block.
Cargo check and build work fine with the sample.
Not sure how this relates to #8479, if at all, I found it to be considerably different to open a new issue.
A minimal reproduction I could come up with, where the incorrect message shows:
In main's
my_struct.call()
, rust-analyzer complains that:expected 1 argument, found 0
.My understanding is that it is only looking at the first
call
implementation, butmy_struct
concrete type actually matches the secondimpl
block.Cargo check and build work fine with the sample.
Not sure how this relates to #8479, if at all, I found it to be considerably different to open a new issue.
rust-analyzer version: 3898387 2021-06-21 stable
ty.
The text was updated successfully, but these errors were encountered: