Skip to content

Commit c99cb0c

Browse files
committed
Rustfmt fixes
1 parent 8ded37d commit c99cb0c

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

vm/src/obj/objlist.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,13 +272,15 @@ fn list_insert(vm: &mut VirtualMachine, args: PyFuncArgs) -> PyResult {
272272
vm,
273273
args,
274274
required = [
275-
(list, Some(vm.ctx.list_type())),
275+
(list, Some(vm.ctx.list_type())),
276276
(insert_position, Some(vm.ctx.int_type())),
277277
(element, None)
278278
]
279279
);
280280
if objint::get_value(insert_position) > std::usize::MAX.into() {
281-
return Err(vm.new_overflow_error("Python int too large to convert to Rust usize".to_string()));
281+
return Err(
282+
vm.new_overflow_error("Python int too large to convert to Rust usize".to_string())
283+
);
282284
}
283285
let mut vec = get_mut_elements(list);
284286
let position = match objint::get_value(insert_position) {

vm/src/vm.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ impl VirtualMachine {
153153
self.new_exception(zero_division_error, msg)
154154
}
155155

156-
pub fn new_overflow_error (&mut self, msg: String) -> PyObjectRef {
156+
pub fn new_overflow_error(&mut self, msg: String) -> PyObjectRef {
157157
let overflow_error = self.ctx.exceptions.overflow_error.clone();
158158
self.new_exception(overflow_error, msg)
159159
}

0 commit comments

Comments
 (0)