Fix rustc hanging

This commit is contained in:
Noah committed 2020-10-09 22:24:10 -05:00
1 parent 11222fd16f
commit ced4b3e361
1 file changed
+5 -5
+5 -5
View File
@@ -267,13 +267,13 @@ mod _struct {
Ok(codes)
}
#[rustfmt::skip] // rustfmt makes it way too long
#[allow(clippy::match_like_matches_macro)] // if we change it to matches!() rustc hangs forever
fn is_supported_format_character(c: char) -> bool {
matches!(
c,
match c {
'x' | 'c' | 'b' | 'B' | '?' | 'h' | 'H' | 'i' | 'I' | 'l' | 'L' | 'q' | 'Q' | 'n'
| 'N' | 'f' | 'd' | 's' | 'p' | 'P'
)
| 'N' | 'f' | 'd' | 's' | 'p' | 'P' => true,
_ => false,
}
}
fn get_int_or_index<T>(vm: &VirtualMachine, arg: &PyObjectRef) -> PyResult<T>