]> git.lizzy.rs Git - rust.git/commit
select obligations after `check_casts`
authorliudingming <liudingming@bytedance.com>
Mon, 9 Aug 2021 12:25:57 +0000 (20:25 +0800)
committerNiko Matsakis <niko@alum.mit.edu>
Mon, 23 Aug 2021 19:16:16 +0000 (19:16 +0000)
commite8910440a24ecb2ddb08b4dbe170488ddf61fc87
tree7b574ec36f695dd6346584fcb7850cafbbc98794
parentb6e334d87349502766be70d649e6fe4a73573482
select obligations after `check_casts`

Otherwise, we can get into a situation where you have
a subtype obligation `#1 <: #2` pending, #1 is constrained
by `check_casts`, but #2` is unaffected.

Co-authored-by: Niko Matsakis <niko@alum.mit.edu>
compiler/rustc_typeck/src/check/fallback.rs
compiler/rustc_typeck/src/check/mod.rs
compiler/rustc_typeck/src/expr_use_visitor.rs
src/test/ui/closures/2229_closure_analysis/issue_88118.rs [new file with mode: 0644]
src/test/ui/closures/issue-87814-1.rs [new file with mode: 0644]
src/test/ui/closures/issue-87814-2.rs [new file with mode: 0644]