diff options
| author | Ellen <supbscripter@gmail.com> | 2021-06-10 14:53:38 +0100 |
|---|---|---|
| committer | Ellen <supbscripter@gmail.com> | 2021-06-10 14:53:44 +0100 |
| commit | 17cd79090efdc8e41ee7535839b6ea0f6909c1d6 (patch) | |
| tree | 1188e3e5645a13662f0b91f9e082d5095eaef15a /compiler/rustc_trait_selection | |
| parent | c318364d485a5673015678b3ad0037eff71d6a8e (diff) | |
| download | rust-17cd79090efdc8e41ee7535839b6ea0f6909c1d6.tar.gz rust-17cd79090efdc8e41ee7535839b6ea0f6909c1d6.zip | |
support `as _` and add tests
Diffstat (limited to 'compiler/rustc_trait_selection')
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/const_evaluatable.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs b/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs index 8094b01b380..b1a938836b7 100644 --- a/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs +++ b/compiler/rustc_trait_selection/src/traits/const_evaluatable.rs @@ -431,7 +431,9 @@ impl<'a, 'tcx> AbstractConstBuilder<'a, 'tcx> { } } // These are not actually relevant for us here, so we can ignore them. - StatementKind::StorageLive(_) | StatementKind::StorageDead(_) => Ok(()), + StatementKind::AscribeUserType(..) + | StatementKind::StorageLive(_) + | StatementKind::StorageDead(_) => Ok(()), _ => self.error(Some(stmt.source_info.span), "unsupported statement")?, } } |
