-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Labels
A-tytype system / type inference / traits / method resolutiontype system / type inference / traits / method resolutionC-bugCategory: bugCategory: bugS-unactionableIssue requires feedback, design decisions or is blocked on other workIssue requires feedback, design decisions or is blocked on other work
Description
rust-analyzer version: rust-analyzer version: 0.3.1334-standalone (74ae2dd 2022-12-25)
rustc version: rustc 1.66.0 (69f9c33d7 2022-12-12)
relevant settings: in vscode's settings.json: "rust-analyzer.diagnostics.experimental.enable": true, "rust-analyzer.checkOnSave.enable": false
(to opt-in into type checking diagnostics)
This code:
struct Foo<T: ?Sized> {
leading: u32,
trailing: T,
}
fn unsize(x: Box<Foo<[u32; 4]>>) -> Box<Foo<[u32]>> {
x
}
compiles fine with rustc, but vscode shows type error from rust-analyzer:
Metadata
Metadata
Assignees
Labels
A-tytype system / type inference / traits / method resolutiontype system / type inference / traits / method resolutionC-bugCategory: bugCategory: bugS-unactionableIssue requires feedback, design decisions or is blocked on other workIssue requires feedback, design decisions or is blocked on other work