clippy
This commit is contained in:
parent
4c258d1ed2
commit
613d15c672
3 changed files with 10 additions and 7 deletions
|
@ -198,18 +198,18 @@ impl<'a, 'tcx> EvalContext<'a, 'tcx> {
|
|||
Integral(ConstInt::InferSigned(_)) => unreachable!(),
|
||||
Integral(ConstInt::I8(i)) => i2p!(i, 1),
|
||||
Integral(ConstInt::U8(i)) => i2p!(i, 1),
|
||||
Integral(ConstInt::Isize(ConstIsize::Is16(i))) |
|
||||
Integral(ConstInt::I16(i)) => i2p!(i, 2),
|
||||
Integral(ConstInt::Usize(ConstUsize::Us16(i))) |
|
||||
Integral(ConstInt::U16(i)) => i2p!(i, 2),
|
||||
Integral(ConstInt::Isize(ConstIsize::Is32(i))) |
|
||||
Integral(ConstInt::I32(i)) => i2p!(i, 4),
|
||||
Integral(ConstInt::Usize(ConstUsize::Us32(i))) |
|
||||
Integral(ConstInt::U32(i)) => i2p!(i, 4),
|
||||
Integral(ConstInt::Isize(ConstIsize::Is64(i))) |
|
||||
Integral(ConstInt::I64(i)) => i2p!(i, 8),
|
||||
Integral(ConstInt::Usize(ConstUsize::Us64(i))) |
|
||||
Integral(ConstInt::U64(i)) => i2p!(i, 8),
|
||||
Integral(ConstInt::Isize(ConstIsize::Is16(i))) => i2p!(i, 2),
|
||||
Integral(ConstInt::Isize(ConstIsize::Is32(i))) => i2p!(i, 4),
|
||||
Integral(ConstInt::Isize(ConstIsize::Is64(i))) => i2p!(i, 8),
|
||||
Integral(ConstInt::Usize(ConstUsize::Us16(i))) => i2p!(i, 2),
|
||||
Integral(ConstInt::Usize(ConstUsize::Us32(i))) => i2p!(i, 4),
|
||||
Integral(ConstInt::Usize(ConstUsize::Us64(i))) => i2p!(i, 8),
|
||||
Str(ref s) => {
|
||||
let psize = self.memory.pointer_size();
|
||||
let static_ptr = self.memory.allocate(s.len(), 1)?;
|
||||
|
|
|
@ -127,7 +127,7 @@ impl<'a, 'tcx> Memory<'a, 'tcx> {
|
|||
mem
|
||||
}
|
||||
|
||||
pub fn allocations<'b>(&'b self) -> ::std::collections::hash_map::Iter<'b, AllocId, Allocation> {
|
||||
pub fn allocations(&self) -> ::std::collections::hash_map::Iter<AllocId, Allocation> {
|
||||
self.alloc_map.iter()
|
||||
}
|
||||
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
#![allow(unknown_lints)]
|
||||
#![allow(float_cmp)]
|
||||
|
||||
use rustc::mir::repr as mir;
|
||||
|
||||
use error::{EvalError, EvalResult};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue