mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-26 22:26:26 +03:00
04c0c8ddde
delegation: emit error when self type is not specified and accessed This PR adds error reporting when we create error self type if it was not specified. In most of the tests there were other errors, so this delayed bug was not triggered, but there are cases like `reuse Default::default;` (rust-lang/rust#156388) which does not emit other errors and those delayed bugs are triggered. Part of rust-lang/rust#118212. Fixes rust-lang/rust#156388. r? @petrochenkov
For high-level intro to how type checking works in rustc, see the hir typeck chapter of the rustc dev guide.