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
editor or extension: NeoVim with LSP, RustRover, and VSCode all have the same issue.
More Info: RA seems to 'know' what the type is, but just doesn't display it. Because when I explicitly set the type of the variable to the wrong option (see example), it complains...
code snippet to reproduce:
pubtraitConditional<constCONDITION:bool>{typeType;}impl<T,F>Conditional<true>for(T,F){typeType = T;}impl<T,F>Conditional<false>for(T,F){typeType = F;}pubtypeIf<constC:bool,T,F> = <(T,F)asConditional<C>>::Type;structFoo;#[derive(Default)]structBar;#[derive(Default)]structBaz;traitTrait{typeOut;fnfoo() -> Self::Out;}implTraitforFoo{typeOut = If<{1 < 0},Bar,Baz>;fnfoo() -> Self::Out{Default::default()}}fnmain(){let _foo = Foo::foo();// Unknown, according to RA, but rustc knows whats up.let _foo:Bar = Foo::foo();// Both rustc and RA error here: "mismatched types"}
The text was updated successfully, but these errors were encountered:
rust-analyzer version: rust-analyzer 1.79.0 (129f3b99 2024-06-10)
rustc version: rustc 1.79.0 (129f3b996 2024-06-10)
editor or extension: NeoVim with LSP, RustRover, and VSCode all have the same issue.
More Info: RA seems to 'know' what the type is, but just doesn't display it. Because when I explicitly set the type of the variable to the wrong option (see example), it complains...
code snippet to reproduce:
The text was updated successfully, but these errors were encountered: