Skip to content

Commit

Permalink
Mark Sleef_rempitabq* constants as static (#536)
Browse files Browse the repository at this point in the history
* Mark Sleef_rempitabq* constants as static

Without marking it static, it fails to compile when including multiple
sleefinline_*.h into the same compilation unit.

* also mark Sleef_rempitabsp as static const
  • Loading branch information
luhenry authored Apr 24, 2024
1 parent 60e76d2 commit 945a7ef
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/libm/sleefinline_header.h.org
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

#ifndef __SLEEF_REMPITAB__
#define __SLEEF_REMPITAB__
const double Sleef_rempitabdp[] = {
static const double Sleef_rempitabdp[] = {
0.15915494309189531785, 1.7916237278037667488e-17, 2.5454160968749269937e-33, 2.1132476107887107169e-49,
0.03415494309189533173, 4.0384494702232122736e-18, 1.0046721413651383112e-33, 2.1132476107887107169e-49,
0.03415494309189533173, 4.0384494702232122736e-18, 1.0046721413651383112e-33, 2.1132476107887107169e-49,
Expand Down Expand Up @@ -1006,7 +1006,7 @@ const double Sleef_rempitabdp[] = {
2.8687869620228451614e-274, -1.9537812801257956865e-290, 1.0380272777574237546e-306, 6.4228533959362050743e-323,
};

const float Sleef_rempitabsp[] = {
static const float Sleef_rempitabsp[] = {
0.159154892, 5.112411827e-08, 3.626141271e-15, -2.036222915e-22,
0.03415493667, 6.420638243e-09, 7.342738037e-17, 8.135951656e-24,
0.03415493667, 6.420638243e-09, 7.342738037e-17, 8.135951656e-24,
Expand Down
2 changes: 1 addition & 1 deletion src/quad/sleefquadinline_header.h.org
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

#ifndef __SLEEF_QREMPITAB__
#define __SLEEF_QREMPITAB__
const double Sleef_rempitabqp[] = {
static const double Sleef_rempitabqp[] = {
0.15915494308865163475, 114.12758349655632628, 87.820147804392036051, 27.423136899138626177,
14.254027919272630243, 85.935026329207175877, 114.27691102886092267, 37.750191829592949944,
2.4546589403216785286, 111.34725244651053799, 62.908236858707823558, 87.408456635555921821,
Expand Down

0 comments on commit 945a7ef

Please sign in to comment.