projects
/
oweals
/
musl.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
add legacy sys/ttydefaults.h header
[oweals/musl.git]
/
src
/
math
/
copysign.c
1
#include "libm.h"
2
3
double copysign(double x, double y) {
4
union dshape ux, uy;
5
6
ux.value = x;
7
uy.value = y;
8
ux.bits &= (uint64_t)-1>>1;
9
ux.bits |= uy.bits & (uint64_t)1<<63;
10
return ux.value;
11
}