Skip to content

Commit 52e3189

Browse files
committed
Use hard tabs for accessibility.
1 parent 325f410 commit 52e3189

File tree

12 files changed

+558
-557
lines changed

12 files changed

+558
-557
lines changed

build.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
use cc;
22

33
fn main() {
4-
// Build our snprintf substitute (which has to be C as Rust doesn't do varargs)
5-
cc::Build::new()
6-
.warnings(true)
7-
.extra_warnings(true)
8-
.file("./src/snprintf.c")
9-
.compile("clocal");
4+
// Build our snprintf substitute (which has to be C as Rust doesn't do varargs)
5+
cc::Build::new()
6+
.warnings(true)
7+
.extra_warnings(true)
8+
.file("./src/snprintf.c")
9+
.compile("clocal");
1010
}

rustfmt.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
1-
hard_tabs = false
1+
hard_tabs = true
2+
23

src/atoi.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,12 @@ use crate::{strtol, CChar, CInt, CLong};
1616
/// ```
1717
#[no_mangle]
1818
pub unsafe extern "C" fn atoi(s: *const CChar) -> CInt {
19-
let result = strtol(s);
20-
if result > CInt::max_value() as CLong {
21-
CInt::max_value()
22-
} else if result < CInt::min_value() as CLong {
23-
CInt::min_value()
24-
} else {
25-
result as CInt
26-
}
19+
let result = strtol(s);
20+
if result > CInt::max_value() as CLong {
21+
CInt::max_value()
22+
} else if result < CInt::min_value() as CLong {
23+
CInt::min_value()
24+
} else {
25+
result as CInt
26+
}
2727
}

0 commit comments

Comments
 (0)