Upgrade to rustfmt 0.6.0
This commit is contained in:
@@ -42,11 +42,7 @@ impl EntityRef for Ebb {
|
|||||||
impl Ebb {
|
impl Ebb {
|
||||||
/// Create a new EBB reference from its number. This corresponds to the ebbNN representation.
|
/// Create a new EBB reference from its number. This corresponds to the ebbNN representation.
|
||||||
pub fn with_number(n: u32) -> Option<Ebb> {
|
pub fn with_number(n: u32) -> Option<Ebb> {
|
||||||
if n < u32::MAX {
|
if n < u32::MAX { Some(Ebb(n)) } else { None }
|
||||||
Some(Ebb(n))
|
|
||||||
} else {
|
|
||||||
None
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -56,11 +56,7 @@ impl FromStr for Imm64 {
|
|||||||
let mut value: u64 = 0;
|
let mut value: u64 = 0;
|
||||||
let mut digits = 0;
|
let mut digits = 0;
|
||||||
let negative = s.starts_with('-');
|
let negative = s.starts_with('-');
|
||||||
let s2 = if negative {
|
let s2 = if negative { &s[1..] } else { s };
|
||||||
&s[1..]
|
|
||||||
} else {
|
|
||||||
s
|
|
||||||
};
|
|
||||||
|
|
||||||
if s2.starts_with("0x") {
|
if s2.starts_with("0x") {
|
||||||
// Hexadecimal.
|
// Hexadecimal.
|
||||||
|
|||||||
@@ -95,10 +95,7 @@ impl FromStr for Opcode {
|
|||||||
/// `Box<AuxData>` to store the additional information out of line.
|
/// `Box<AuxData>` to store the additional information out of line.
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
pub enum InstructionData {
|
pub enum InstructionData {
|
||||||
Nullary {
|
Nullary { opcode: Opcode, ty: Type },
|
||||||
opcode: Opcode,
|
|
||||||
ty: Type,
|
|
||||||
},
|
|
||||||
Unary {
|
Unary {
|
||||||
opcode: Opcode,
|
opcode: Opcode,
|
||||||
ty: Type,
|
ty: Type,
|
||||||
|
|||||||
@@ -17,4 +17,5 @@ pub mod settings;
|
|||||||
|
|
||||||
mod constant_hash;
|
mod constant_hash;
|
||||||
|
|
||||||
#[cfg(test)]pub mod test_utils;
|
#[cfg(test)]
|
||||||
|
pub mod test_utils;
|
||||||
|
|||||||
@@ -227,9 +227,7 @@ pub mod detail {
|
|||||||
#[derive(Clone, Copy)]
|
#[derive(Clone, Copy)]
|
||||||
pub enum Detail {
|
pub enum Detail {
|
||||||
/// A boolean setting only uses one bit, numbered from LSB.
|
/// A boolean setting only uses one bit, numbered from LSB.
|
||||||
Bool {
|
Bool { bit: u8 },
|
||||||
bit: u8,
|
|
||||||
},
|
|
||||||
|
|
||||||
/// A numerical setting uses the whole byte.
|
/// A numerical setting uses the whole byte.
|
||||||
Num,
|
Num,
|
||||||
|
|||||||
Reference in New Issue
Block a user