mirror of
https://github.com/rust-lang/rust.git
synced 2026-04-28 11:17:26 +03:00
b31dc4ab49
Avoid an ICE for:
struct A;
impl A<B> {}
The compiler no longer panics and can proceed to emit existing diagnostics.
Adds `tests/ui/missing/undeclared-generic-parameter.rs`.
Signed-off-by: Usman Akinyemi <usmanakinyemi202@gmail.com>
6 lines
162 B
Rust
6 lines
162 B
Rust
struct A;
|
|
impl A<B> {}
|
|
//~^ ERROR cannot find type `B` in this scope
|
|
//~| ERROR struct takes 0 generic arguments but 1 generic argument was supplied
|
|
fn main() {}
|