add fmod, fmodf, frexp, frexpf functions
This commit is contained in:
parent
4d62f5ddf0
commit
bff9ecdaed
10
src/lib.rs
10
src/lib.rs
|
@ -105,4 +105,12 @@ pub mod fmaxf;
|
|||
#[path = "math/fmin.rs"]
|
||||
pub mod fmin;
|
||||
#[path = "math/fminf.rs"]
|
||||
pub mod fminf;
|
||||
pub mod fminf;
|
||||
#[path = "math/fmod.rs"]
|
||||
pub mod fmod;
|
||||
#[path = "math/fmodf.rs"]
|
||||
pub mod fmodf;
|
||||
#[path = "math/frexp.rs"]
|
||||
pub mod frexp;
|
||||
#[path = "math/frexpf.rs"]
|
||||
pub mod frexpf;
|
14
src/math/fmod.rs
Normal file
14
src/math/fmod.rs
Normal file
|
@ -0,0 +1,14 @@
|
|||
// SPDX-License-Identifier: MPL-2.0
|
||||
/*
|
||||
* File: src/math/fmod.rs
|
||||
*
|
||||
* The fmod function.
|
||||
*
|
||||
* Author: HTG-YT
|
||||
* Copyright (c) 2021 The LibM Team of the HaruxOS Project
|
||||
*/
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn fmod(x: f64, y: f64) -> f64 {
|
||||
libm::fmod(x, y)
|
||||
}
|
14
src/math/fmodf.rs
Normal file
14
src/math/fmodf.rs
Normal file
|
@ -0,0 +1,14 @@
|
|||
// SPDX-License-Identifier: MPL-2.0
|
||||
/*
|
||||
* File: src/math/fmodf.rs
|
||||
*
|
||||
* The fmodf function.
|
||||
*
|
||||
* Author: HTG-YT
|
||||
* Copyright (c) 2021 The LibM Team of the HaruxOS Project
|
||||
*/
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn fmodf(x: f32, y: f32) -> f32 {
|
||||
libm::fmodf(x, y)
|
||||
}
|
14
src/math/frexp.rs
Normal file
14
src/math/frexp.rs
Normal file
|
@ -0,0 +1,14 @@
|
|||
// SPDX-License-Identifier: MPL-2.0
|
||||
/*
|
||||
* File: src/math/frexp.rs
|
||||
*
|
||||
* The frexp function.
|
||||
*
|
||||
* Author: HTG-YT
|
||||
* Copyright (c) 2021 The LibM Team of the HaruxOS Project
|
||||
*/
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn frexp(x: f64) -> (f64, i32) {
|
||||
libm::frexp(x)
|
||||
}
|
14
src/math/frexpf.rs
Normal file
14
src/math/frexpf.rs
Normal file
|
@ -0,0 +1,14 @@
|
|||
// SPDX-License-Identifier: MPL-2.0
|
||||
/*
|
||||
* File: src/math/frexpf.rs
|
||||
*
|
||||
* The frexpf function.
|
||||
*
|
||||
* Author: HTG-YT
|
||||
* Copyright (c) 2021 The LibM Team of the HaruxOS Project
|
||||
*/
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn frexpf(x: f32) -> (f32, i32) {
|
||||
libm::frexpf(x)
|
||||
}
|
Loading…
Reference in a new issue