Large reorganization of headers (WIP)
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
sys_includes = ["sys/types.h", "bits/float.h"]
|
||||
include_guard = "_FLOAT_H"
|
||||
language = "C"
|
||||
style = "Tag"
|
||||
|
||||
[enum]
|
||||
prefix_with_name = true
|
||||
@@ -0,0 +1,16 @@
|
||||
//! float.h implementation for Redox, following
|
||||
//! http://pubs.opengroup.org/onlinepubs/7908799/xsh/float.h.html
|
||||
|
||||
use header::fenv::{fegetround, FE_TONEAREST};
|
||||
use platform;
|
||||
use platform::types::*;
|
||||
|
||||
pub const FLT_RADIX: c_int = 2;
|
||||
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn flt_rounds() -> c_int {
|
||||
match fegetround() {
|
||||
FE_TONEAREST => 1,
|
||||
_ => -1,
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user