Changeset 84929b0 in mainline for uspace/lib/math/generic/fmod.c
- Timestamp:
- 2018-08-29T20:06:00Z (6 years ago)
- Children:
- ed9043f7
- Parents:
- 184ff675
- git-author:
- Jiří Zárevúcky <jiri.zarevucky@…> (2018-08-29 19:44:33)
- git-committer:
- Jiří Zárevúcky <jiri.zarevucky@…> (2018-08-29 20:06:00)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/math/generic/fmod.c
r184ff675 r84929b0 33 33 */ 34 34 35 #include <fmod.h>36 35 #include <math.h> 37 36 … … 52 51 * 53 52 */ 54 float 32_t float32_fmod(float32_t dividend, float32_t divisor)53 float fmodf(float dividend, float divisor) 55 54 { 56 55 // FIXME: replace with exact arithmetics 57 56 58 float 32_t quotient = trunc_f32(dividend / divisor);57 float quotient = truncf(dividend / divisor); 59 58 60 59 return (dividend - quotient * divisor); … … 77 76 * 78 77 */ 79 float64_t float64_fmod(float64_t dividend, float64_tdivisor)78 double fmod(double dividend, double divisor) 80 79 { 81 80 // FIXME: replace with exact arithmetics 82 81 83 float64_t quotient = trunc_f64(dividend / divisor);82 double quotient = trunc(dividend / divisor); 84 83 85 84 return (dividend - quotient * divisor);
Note:
See TracChangeset
for help on using the changeset viewer.