]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_mir/interpret/memory.rs
Auto merge of #69586 - petrochenkov:unmerge, r=Centril
[rust.git] / src / librustc_mir / interpret / memory.rs
index f60307e468bd25c469add4d6af68dbc7abe62bbc..3c4a1857f9690e80fb69c60c4a91e33aa540e2be 100644 (file)
@@ -14,7 +14,7 @@
 use rustc::ty::{self, query::TyCtxtAt, Instance, ParamEnv};
 use rustc_data_structures::fx::{FxHashMap, FxHashSet};
 
-use syntax::ast::Mutability;
+use rustc_ast::ast::Mutability;
 
 use super::{
     AllocId, AllocMap, Allocation, AllocationExtra, CheckInAllocMsg, ErrorHandled, GlobalAlloc,
@@ -565,7 +565,7 @@ pub fn get_size_and_align(
 
         // # Function pointers
         // (both global from `alloc_map` and local from `extra_fn_ptr_map`)
-        if let Some(_) = self.get_fn_alloc(id) {
+        if self.get_fn_alloc(id).is_some() {
             return if let AllocCheck::Dereferenceable = liveness {
                 // The caller requested no function pointers.
                 throw_unsup!(DerefFunctionPointer)