-
Notifications
You must be signed in to change notification settings - Fork 288
Open
Labels
bugSomething isn't workingSomething isn't workingmistranslationTranslating a well-behaved program changes its behaviorTranslating a well-behaved program changes its behavior
Description
Original C Code:
int main(void) {
assert(check_add()); // once
assert(check_sub()); // once
return 0;
}C2rust Output:
unsafe fn main_0() -> core::ffi::c_int {
// first
if check_add() {} else {
__assert_fail(...);
}
// π΄ second !!!
'c_1569: {
if check_add() {} else {
__assert_fail(...);
}
};
// first
if check_sub() {} else {
__assert_fail(...);
}
// π΄ second !!!
'c_1529: {
if check_sub() {} else {
__assert_fail(...);
}
};
return 0 as core::ffi::c_int;
}Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingmistranslationTranslating a well-behaved program changes its behaviorTranslating a well-behaved program changes its behavior