Skip to content

Commit d1799d6

Browse files
committed
transpile: tests: out_of_range_int.c before #1266
1 parent e9d2c12 commit d1799d6

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

c2rust-transpile/tests/snapshots/snapshots__transpile@out_of_range_int.c.snap

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,18 @@ input_file: c2rust-transpile/tests/snapshots/out_of_range_int.c
55
---
66
#![allow(
77
dead_code,
8+
mutable_transmutes,
89
non_camel_case_types,
910
non_snake_case,
1011
non_upper_case_globals,
1112
unused_assignments,
1213
unused_mut
1314
)]
14-
pub type __int32_t = i32;
15+
pub type __int32_t = std::ffi::c_int;
1516
pub type int32_t = __int32_t;
1617
#[no_mangle]
1718
pub unsafe extern "C" fn f() {
18-
let mut a: int32_t = 0x80000000 as int32_t;
19-
let mut b: int32_t = 0x80000000 as int32_t;
20-
let mut c: int32_t = 0x8000000000000000 as int32_t;
19+
let mut a: int32_t = 0x80000000 as std::ffi::c_uint as int32_t;
20+
let mut b: int32_t = 0x80000000 as std::ffi::c_uint as int32_t;
21+
let mut c: int32_t = 0x8000000000000000 as std::ffi::c_ulong as int32_t;
2122
}

0 commit comments

Comments
 (0)