Fix assertion failure in type inference (#13352) Fixes https://github.com/rust-lang/rust-analyzer/issues/13352