Skip to content

Commit b96cd47

Browse files
committed
Add missing license and inline anotations
1 parent a7aa398 commit b96cd47

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/math.rs

+6
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,24 @@
1+
/* This Source Code Form is subject to the terms of the Mozilla Public
2+
* License, v. 2.0. If a copy of the MPL was not distributed with this
3+
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
14

5+
#[inline]
26
pub(crate) fn f32_trunc(val: f32) -> f32 {
37
#[cfg(feature = "std")]
48
{ val.round() }
59
#[cfg(not(feature = "std"))]
610
{ libm::roundf(val) }
711
}
812

13+
#[inline]
914
pub(crate) fn f32_round(val: f32) -> f32 {
1015
#[cfg(feature = "std")]
1116
{ val.round() }
1217
#[cfg(not(feature = "std"))]
1318
{ libm::roundf(val) }
1419
}
1520

21+
#[inline]
1622
pub(crate) fn f64_pow(a: f64, b: f64) -> f64 {
1723
#[cfg(feature = "std")]
1824
{ f64::powf(a, b) }

0 commit comments

Comments
 (0)