math: add (obsolete) bsd drem and finite functions

This commit is contained in:
Szabolcs Nagy 2013-11-21 01:16:49 +00:00
commit 5d01ab4ac6
5 changed files with 26 additions and 0 deletions

7
src/math/finite.c Normal file
View file

@ -0,0 +1,7 @@
#define _GNU_SOURCE
#include <math.h>
int finite(double x)
{
return isfinite(x);
}

7
src/math/finitef.c Normal file
View file

@ -0,0 +1,7 @@
#define _GNU_SOURCE
#include <math.h>
int finitef(float x)
{
return isfinite(x);
}

View file

@ -1,7 +1,10 @@
#include <math.h>
#include "libc.h"
double remainder(double x, double y)
{
int q;
return remquo(x, y, &q);
}
weak_alias(remainder, drem);

View file

@ -1,7 +1,10 @@
#include <math.h>
#include "libc.h"
float remainderf(float x, float y)
{
int q;
return remquof(x, y, &q);
}
weak_alias(remainderf, dremf);