Ruby  2.4.2p198(2017-09-14revision59899)
bigdecimal.h
Go to the documentation of this file.
1 /*
2  *
3  * Ruby BigDecimal(Variable decimal precision) extension library.
4  *
5  * Copyright(C) 2002 by Shigeo Kobayashi(shigeo@tinyforest.gr.jp)
6  *
7  */
8 
9 #ifndef RUBY_BIG_DECIMAL_H
10 #define RUBY_BIG_DECIMAL_H 1
11 
12 #include "ruby/ruby.h"
13 #include <float.h>
14 
15 #ifndef RB_UNUSED_VAR
16 # ifdef __GNUC__
17 # define RB_UNUSED_VAR(x) x __attribute__ ((unused))
18 # else
19 # define RB_UNUSED_VAR(x) x
20 # endif
21 #endif
22 
23 #ifndef UNREACHABLE
24 # define UNREACHABLE /* unreachable */
25 #endif
26 
27 #undef BDIGIT
28 #undef SIZEOF_BDIGITS
29 #undef BDIGIT_DBL
30 #undef BDIGIT_DBL_SIGNED
31 #undef PRI_BDIGIT_PREFIX
32 #undef PRI_BDIGIT_DBL_PREFIX
33 
34 #ifdef HAVE_INT64_T
35 # define BDIGIT uint32_t
36 # define BDIGIT_DBL uint64_t
37 # define BDIGIT_DBL_SIGNED int64_t
38 # define SIZEOF_BDIGITS 4
39 # define PRI_BDIGIT_PREFIX ""
40 # ifdef PRI_LL_PREFIX
41 # define PRI_BDIGIT_DBL_PREFIX PRI_LL_PREFIX
42 # else
43 # define PRI_BDIGIT_DBL_PREFIX "l"
44 # endif
45 #else
46 # define BDIGIT uint16_t
47 # define BDIGIT_DBL uint32_t
48 # define BDIGIT_DBL_SIGNED int32_t
49 # define SIZEOF_BDIGITS 2
50 # define PRI_BDIGIT_PREFIX "h"
51 # define PRI_BDIGIT_DBL_PREFIX ""
52 #endif
53 
54 #define PRIdBDIGIT PRI_BDIGIT_PREFIX"d"
55 #define PRIiBDIGIT PRI_BDIGIT_PREFIX"i"
56 #define PRIoBDIGIT PRI_BDIGIT_PREFIX"o"
57 #define PRIuBDIGIT PRI_BDIGIT_PREFIX"u"
58 #define PRIxBDIGIT PRI_BDIGIT_PREFIX"x"
59 #define PRIXBDIGIT PRI_BDIGIT_PREFIX"X"
60 
61 #define PRIdBDIGIT_DBL PRI_BDIGIT_DBL_PREFIX"d"
62 #define PRIiBDIGIT_DBL PRI_BDIGIT_DBL_PREFIX"i"
63 #define PRIoBDIGIT_DBL PRI_BDIGIT_DBL_PREFIX"o"
64 #define PRIuBDIGIT_DBL PRI_BDIGIT_DBL_PREFIX"u"
65 #define PRIxBDIGIT_DBL PRI_BDIGIT_DBL_PREFIX"x"
66 #define PRIXBDIGIT_DBL PRI_BDIGIT_DBL_PREFIX"X"
67 
68 #if defined(__cplusplus)
69 extern "C" {
70 #if 0
71 } /* satisfy cc-mode */
72 #endif
73 #endif
74 
75 #ifndef HAVE_LABS
76 static inline long
77 labs(long const x)
78 {
79  if (x < 0) return -x;
80  return x;
81 }
82 #endif
83 
84 #ifndef HAVE_LLABS
85 static inline LONG_LONG
86 llabs(LONG_LONG const x)
87 {
88  if (x < 0) return -x;
89  return x;
90 }
91 #endif
92 
93 #ifndef HAVE_FINITE
94 static int
95 finite(double)
96 {
97  return !isnan(n) && !isinf(n);
98 }
99 #endif
100 
101 #ifndef isfinite
102 # ifndef HAVE_ISFINITE
103 # define HAVE_ISFINITE 1
104 # define isfinite(x) finite(x)
105 # endif
106 #endif
107 
108 #ifndef FIX_CONST_VALUE_PTR
109 # if defined(__fcc__) || defined(__fcc_version) || \
110  defined(__FCC__) || defined(__FCC_VERSION)
111 /* workaround for old version of Fujitsu C Compiler (fcc) */
112 # define FIX_CONST_VALUE_PTR(x) ((const VALUE *)(x))
113 # else
114 # define FIX_CONST_VALUE_PTR(x) (x)
115 # endif
116 #endif
117 
118 #ifndef HAVE_RB_ARRAY_CONST_PTR
119 static inline const VALUE *
121 {
122  return FIX_CONST_VALUE_PTR((RBASIC(a)->flags & RARRAY_EMBED_FLAG) ?
123  RARRAY(a)->as.ary : RARRAY(a)->as.heap.ptr);
124 }
125 #endif
126 
127 #ifndef RARRAY_CONST_PTR
128 # define RARRAY_CONST_PTR(a) rb_array_const_ptr(a)
129 #endif
130 
131 #ifndef RARRAY_AREF
132 # define RARRAY_AREF(a, i) (RARRAY_CONST_PTR(a)[i])
133 #endif
134 
135 #ifndef HAVE_RB_SYM2STR
136 static inline VALUE
138 {
139  return rb_id2str(SYM2ID(sym));
140 }
141 #endif
142 
143 #ifdef vabs
144 # undef vabs
145 #endif
146 #if SIZEOF_VALUE <= SIZEOF_INT
147 # define vabs abs
148 #elif SIZEOF_VALUE <= SIZEOF_LONG
149 # define vabs labs
150 #elif SIZEOF_VALUE <= SIZEOF_LONG_LONG
151 # define vabs llabs
152 #endif
153 
154 extern VALUE rb_cBigDecimal;
155 
156 #if 0 || SIZEOF_BDIGITS >= 16
157 # define RMPD_COMPONENT_FIGURES 38
158 # define RMPD_BASE ((BDIGIT)100000000000000000000000000000000000000U)
159 #elif SIZEOF_BDIGITS >= 8
160 # define RMPD_COMPONENT_FIGURES 19
161 # define RMPD_BASE ((BDIGIT)10000000000000000000U)
162 #elif SIZEOF_BDIGITS >= 4
163 # define RMPD_COMPONENT_FIGURES 9
164 # define RMPD_BASE ((BDIGIT)1000000000U)
165 #elif SIZEOF_BDIGITS >= 2
166 # define RMPD_COMPONENT_FIGURES 4
167 # define RMPD_BASE ((BDIGIT)10000U)
168 #else
169 # define RMPD_COMPONENT_FIGURES 2
170 # define RMPD_BASE ((BDIGIT)100U)
171 #endif
172 
173 
174 /*
175  * NaN & Infinity
176  */
177 #define SZ_NaN "NaN"
178 #define SZ_INF "Infinity"
179 #define SZ_PINF "+Infinity"
180 #define SZ_NINF "-Infinity"
181 
182 /*
183  * #define VP_EXPORT other than static to let VP_ routines
184  * be called from outside of this module.
185  */
186 #define VP_EXPORT static
187 
188 /* Exception codes */
189 #define VP_EXCEPTION_ALL ((unsigned short)0x00FF)
190 #define VP_EXCEPTION_INFINITY ((unsigned short)0x0001)
191 #define VP_EXCEPTION_NaN ((unsigned short)0x0002)
192 #define VP_EXCEPTION_UNDERFLOW ((unsigned short)0x0004)
193 #define VP_EXCEPTION_OVERFLOW ((unsigned short)0x0001) /* 0x0008) */
194 #define VP_EXCEPTION_ZERODIVIDE ((unsigned short)0x0010)
195 
196 /* Following 2 exceptions can't controlled by user */
197 #define VP_EXCEPTION_OP ((unsigned short)0x0020)
198 #define VP_EXCEPTION_MEMORY ((unsigned short)0x0040)
199 
200 #define RMPD_EXCEPTION_MODE_DEFAULT 0U
201 
202 /* Computation mode */
203 #define VP_ROUND_MODE ((unsigned short)0x0100)
204 #define VP_ROUND_UP 1
205 #define VP_ROUND_DOWN 2
206 #define VP_ROUND_HALF_UP 3
207 #define VP_ROUND_HALF_DOWN 4
208 #define VP_ROUND_CEIL 5
209 #define VP_ROUND_FLOOR 6
210 #define VP_ROUND_HALF_EVEN 7
211 
212 #define RMPD_ROUNDING_MODE_DEFAULT VP_ROUND_HALF_UP
213 
214 #define VP_SIGN_NaN 0 /* NaN */
215 #define VP_SIGN_POSITIVE_ZERO 1 /* Positive zero */
216 #define VP_SIGN_NEGATIVE_ZERO -1 /* Negative zero */
217 #define VP_SIGN_POSITIVE_FINITE 2 /* Positive finite number */
218 #define VP_SIGN_NEGATIVE_FINITE -2 /* Negative finite number */
219 #define VP_SIGN_POSITIVE_INFINITE 3 /* Positive infinite number */
220 #define VP_SIGN_NEGATIVE_INFINITE -3 /* Negative infinite number */
221 
222 #ifdef __GNUC__
223 #define FLEXIBLE_ARRAY_SIZE 0
224 #else
225 #define FLEXIBLE_ARRAY_SIZE 1
226 #endif
227 
228 /*
229  * VP representation
230  * r = 0.xxxxxxxxx *BASE**exponent
231  */
232 typedef struct {
233  VALUE obj; /* Back pointer(VALUE) for Ruby object. */
234  size_t MaxPrec; /* Maximum precision size */
235  /* This is the actual size of frac[] */
236  /*(frac[0] to frac[MaxPrec] are available). */
237  size_t Prec; /* Current precision size. */
238  /* This indicates how much the */
239  /* array frac[] is actually used. */
240  SIGNED_VALUE exponent; /* Exponent part. */
241  short sign; /* Attributes of the value. */
242  /*
243  * ==0 : NaN
244  * 1 : Positive zero
245  * -1 : Negative zero
246  * 2 : Positive number
247  * -2 : Negative number
248  * 3 : Positive infinite number
249  * -3 : Negative infinite number
250  */
251  short flag; /* Not used in vp_routines,space for user. */
252  BDIGIT frac[FLEXIBLE_ARRAY_SIZE]; /* Array of fraction part. */
253 } Real;
254 
255 /*
256  * ------------------
257  * EXPORTables.
258  * ------------------
259  */
260 
261 VP_EXPORT Real *
262 VpNewRbClass(size_t mx, char const *str, VALUE klass);
263 
264 VP_EXPORT Real *VpCreateRbObject(size_t mx,const char *str);
265 
266 static inline BDIGIT
267 rmpd_base_value(void) { return RMPD_BASE; }
268 static inline size_t
270 static inline size_t
271 rmpd_double_figures(void) { return 1+DBL_DIG; }
272 
273 #define VpBaseFig() rmpd_component_figures()
274 #define VpDblFig() rmpd_double_figures()
275 #define VpBaseVal() rmpd_base_value()
276 
277 /* Zero,Inf,NaN (isinf(),isnan() used to check) */
278 VP_EXPORT double VpGetDoubleNaN(void);
279 VP_EXPORT double VpGetDoublePosInf(void);
280 VP_EXPORT double VpGetDoubleNegInf(void);
281 VP_EXPORT double VpGetDoubleNegZero(void);
282 
283 /* These 2 functions added at v1.1.7 */
284 VP_EXPORT size_t VpGetPrecLimit(void);
285 VP_EXPORT size_t VpSetPrecLimit(size_t n);
286 
287 /* Round mode */
288 VP_EXPORT int VpIsRoundMode(unsigned short n);
289 VP_EXPORT unsigned short VpGetRoundMode(void);
290 VP_EXPORT unsigned short VpSetRoundMode(unsigned short n);
291 
292 VP_EXPORT int VpException(unsigned short f,const char *str,int always);
293 #if 0 /* unused */
294 VP_EXPORT int VpIsNegDoubleZero(double v);
295 #endif
296 VP_EXPORT size_t VpNumOfChars(Real *vp,const char *pszFmt);
297 VP_EXPORT size_t VpInit(BDIGIT BaseVal);
298 VP_EXPORT void *VpMemAlloc(size_t mb);
299 VP_EXPORT void *VpMemRealloc(void *ptr, size_t mb);
300 VP_EXPORT void VpFree(Real *pv);
301 VP_EXPORT Real *VpAlloc(size_t mx, const char *szVal);
302 VP_EXPORT size_t VpAsgn(Real *c, Real *a, int isw);
303 VP_EXPORT size_t VpAddSub(Real *c,Real *a,Real *b,int operation);
304 VP_EXPORT size_t VpMult(Real *c,Real *a,Real *b);
305 VP_EXPORT size_t VpDivd(Real *c,Real *r,Real *a,Real *b);
306 VP_EXPORT int VpComp(Real *a,Real *b);
307 VP_EXPORT ssize_t VpExponent10(Real *a);
308 VP_EXPORT void VpSzMantissa(Real *a,char *psz);
309 VP_EXPORT int VpToSpecialString(Real *a,char *psz,int fPlus);
310 VP_EXPORT void VpToString(Real *a, char *psz, size_t fFmt, int fPlus);
311 VP_EXPORT void VpToFString(Real *a, char *psz, size_t fFmt, int fPlus);
312 VP_EXPORT int VpCtoV(Real *a, const char *int_chr, size_t ni, const char *frac, size_t nf, const char *exp_chr, size_t ne);
313 VP_EXPORT int VpVtoD(double *d, SIGNED_VALUE *e, Real *m);
314 VP_EXPORT void VpDtoV(Real *m,double d);
315 #if 0 /* unused */
316 VP_EXPORT void VpItoV(Real *m,S_INT ival);
317 #endif
318 VP_EXPORT int VpSqrt(Real *y,Real *x);
319 VP_EXPORT int VpActiveRound(Real *y, Real *x, unsigned short f, ssize_t il);
320 VP_EXPORT int VpMidRound(Real *y, unsigned short f, ssize_t nf);
321 VP_EXPORT int VpLeftRound(Real *y, unsigned short f, ssize_t nf);
322 VP_EXPORT void VpFrac(Real *y, Real *x);
323 VP_EXPORT int VpPower(Real *y, Real *x, SIGNED_VALUE n);
324 
325 /* VP constants */
326 VP_EXPORT Real *VpOne(void);
327 
328 /*
329  * ------------------
330  * MACRO definitions.
331  * ------------------
332  */
333 #define Abs(a) (((a)>= 0)?(a):(-(a)))
334 #define Max(a, b) (((a)>(b))?(a):(b))
335 #define Min(a, b) (((a)>(b))?(b):(a))
336 
337 #define VpMaxPrec(a) ((a)->MaxPrec)
338 #define VpPrec(a) ((a)->Prec)
339 #define VpGetFlag(a) ((a)->flag)
340 
341 /* Sign */
342 
343 /* VpGetSign(a) returns 1,-1 if a>0,a<0 respectively */
344 #define VpGetSign(a) (((a)->sign>0)?1:(-1))
345 /* Change sign of a to a>0,a<0 if s = 1,-1 respectively */
346 #define VpChangeSign(a,s) {if((s)>0) (a)->sign=(short)Abs((ssize_t)(a)->sign);else (a)->sign=-(short)Abs((ssize_t)(a)->sign);}
347 /* Sets sign of a to a>0,a<0 if s = 1,-1 respectively */
348 #define VpSetSign(a,s) {if((s)>0) (a)->sign=(short)VP_SIGN_POSITIVE_FINITE;else (a)->sign=(short)VP_SIGN_NEGATIVE_FINITE;}
349 
350 /* 1 */
351 #define VpSetOne(a) {(a)->Prec=(a)->exponent=(a)->frac[0]=1;(a)->sign=VP_SIGN_POSITIVE_FINITE;}
352 
353 /* ZEROs */
354 #define VpIsPosZero(a) ((a)->sign==VP_SIGN_POSITIVE_ZERO)
355 #define VpIsNegZero(a) ((a)->sign==VP_SIGN_NEGATIVE_ZERO)
356 #define VpIsZero(a) (VpIsPosZero(a) || VpIsNegZero(a))
357 #define VpSetPosZero(a) ((a)->frac[0]=0,(a)->Prec=1,(a)->sign=VP_SIGN_POSITIVE_ZERO)
358 #define VpSetNegZero(a) ((a)->frac[0]=0,(a)->Prec=1,(a)->sign=VP_SIGN_NEGATIVE_ZERO)
359 #define VpSetZero(a,s) (void)(((s)>0)?VpSetPosZero(a):VpSetNegZero(a))
360 
361 /* NaN */
362 #define VpIsNaN(a) ((a)->sign==VP_SIGN_NaN)
363 #define VpSetNaN(a) ((a)->frac[0]=0,(a)->Prec=1,(a)->sign=VP_SIGN_NaN)
364 
365 /* Infinity */
366 #define VpIsPosInf(a) ((a)->sign==VP_SIGN_POSITIVE_INFINITE)
367 #define VpIsNegInf(a) ((a)->sign==VP_SIGN_NEGATIVE_INFINITE)
368 #define VpIsInf(a) (VpIsPosInf(a) || VpIsNegInf(a))
369 #define VpIsDef(a) ( !(VpIsNaN(a)||VpIsInf(a)) )
370 #define VpSetPosInf(a) ((a)->frac[0]=0,(a)->Prec=1,(a)->sign=VP_SIGN_POSITIVE_INFINITE)
371 #define VpSetNegInf(a) ((a)->frac[0]=0,(a)->Prec=1,(a)->sign=VP_SIGN_NEGATIVE_INFINITE)
372 #define VpSetInf(a,s) (void)(((s)>0)?VpSetPosInf(a):VpSetNegInf(a))
373 #define VpHasVal(a) (a->frac[0])
374 #define VpIsOne(a) ((a->Prec==1)&&(a->frac[0]==1)&&(a->exponent==1))
375 #define VpExponent(a) (a->exponent)
376 #ifdef BIGDECIMAL_DEBUG
377 int VpVarCheck(Real * v);
378 #endif /* BIGDECIMAL_DEBUG */
379 
380 #if defined(__cplusplus)
381 #if 0
382 { /* satisfy cc-mode */
383 #endif
384 } /* extern "C" { */
385 #endif
386 #endif /* RUBY_BIG_DECIMAL_H */
VP_EXPORT void * VpMemRealloc(void *ptr, size_t mb)
Definition: bigdecimal.c:3487
VP_EXPORT int VpActiveRound(Real *y, Real *x, unsigned short f, ssize_t il)
Definition: bigdecimal.c:6110
VP_EXPORT ssize_t VpExponent10(Real *a)
Definition: bigdecimal.c:5250
SIGNED_VALUE exponent
Definition: bigdecimal.h:240
VP_EXPORT double VpGetDoubleNaN(void)
Definition: bigdecimal.c:3678
#define FIX_CONST_VALUE_PTR(x)
Definition: ruby.h:2038
#define DBL_DIG
Definition: numeric.c:54
VALUE obj
Definition: bigdecimal.h:233
#define rb_id2str(id)
Definition: vm_backtrace.c:29
size_t Prec
Definition: bigdecimal.h:237
#define SYM2ID(x)
Definition: ruby.h:384
static long labs(long const x)
Definition: bigdecimal.h:77
VP_EXPORT size_t VpGetPrecLimit(void)
Definition: bigdecimal.c:3562
VP_EXPORT size_t VpDivd(Real *c, Real *r, Real *a, Real *b)
Definition: bigdecimal.c:4772
VP_EXPORT size_t VpMult(Real *c, Real *a, Real *b)
Definition: bigdecimal.c:4643
VP_EXPORT int VpComp(Real *a, Real *b)
Definition: bigdecimal.c:5025
VP_EXPORT int VpVtoD(double *d, SIGNED_VALUE *e, Real *m)
Definition: bigdecimal.c:5623
#define sym(x)
Definition: date_core.c:3721
static LONG_LONG llabs(LONG_LONG const x)
Definition: bigdecimal.h:86
VP_EXPORT void VpFrac(Real *y, Real *x)
Definition: bigdecimal.c:6205
static size_t rmpd_component_figures(void)
Definition: bigdecimal.h:269
VP_EXPORT size_t VpAddSub(Real *c, Real *a, Real *b, int operation)
Definition: bigdecimal.c:4188
VP_EXPORT void VpToFString(Real *a, char *psz, size_t fFmt, int fPlus)
Definition: bigdecimal.c:5397
VP_EXPORT int VpMidRound(Real *y, unsigned short f, ssize_t nf)
Definition: bigdecimal.c:5928
static const VALUE * rb_array_const_ptr(VALUE a)
Definition: bigdecimal.h:120
VP_EXPORT Real * VpNewRbClass(size_t mx, char const *str, VALUE klass)
Definition: bigdecimal.c:657
#define RARRAY(obj)
Definition: ruby.h:1210
#define RMPD_COMPONENT_FIGURES
Definition: bigdecimal.h:166
VP_EXPORT void * VpMemAlloc(size_t mb)
Definition: bigdecimal.c:3473
#define ne(x, y)
Definition: time.c:69
VP_EXPORT void VpToString(Real *a, char *psz, size_t fFmt, int fPlus)
Definition: bigdecimal.c:5349
#define VP_EXPORT
Definition: bigdecimal.h:186
static int finite(double)
Definition: bigdecimal.h:95
#define RMPD_BASE
Definition: bigdecimal.h:167
VP_EXPORT size_t VpNumOfChars(Real *vp, const char *pszFmt)
Definition: bigdecimal.c:3846
VALUE rb_cBigDecimal
Definition: bigdecimal.c:45
VP_EXPORT void VpFree(Real *pv)
Definition: bigdecimal.c:3497
VP_EXPORT Real * VpCreateRbObject(size_t mx, const char *str)
Definition: bigdecimal.c:667
RUBY_EXTERN int isinf(double)
Definition: isinf.c:56
VP_EXPORT double VpGetDoubleNegZero(void)
Definition: bigdecimal.c:3702
VP_EXPORT int VpIsRoundMode(unsigned short n)
Definition: bigdecimal.c:3613
static VALUE int_chr(int argc, VALUE *argv, VALUE num)
Definition: numeric.c:3290
short flag
Definition: bigdecimal.h:251
VP_EXPORT int VpSqrt(Real *y, Real *x)
Definition: bigdecimal.c:5819
VP_EXPORT void VpDtoV(Real *m, double d)
Definition: bigdecimal.c:5687
VP_EXPORT int VpToSpecialString(Real *a, char *psz, int fPlus)
Definition: bigdecimal.c:5314
unsigned long VALUE
Definition: ruby.h:85
static BDIGIT rmpd_base_value(void)
Definition: bigdecimal.h:267
VP_EXPORT double VpGetDoubleNegInf(void)
Definition: bigdecimal.c:3694
#define RBASIC(obj)
Definition: ruby.h:1204
VP_EXPORT size_t VpSetPrecLimit(size_t n)
Definition: bigdecimal.c:3578
VP_EXPORT size_t VpAsgn(Real *c, Real *a, int isw)
Definition: bigdecimal.c:4144
#define isnan(x)
Definition: win32.h:346
short sign
Definition: bigdecimal.h:241
static size_t rmpd_double_figures(void)
Definition: bigdecimal.h:271
VP_EXPORT int VpCtoV(Real *a, const char *int_chr, size_t ni, const char *frac, size_t nf, const char *exp_chr, size_t ne)
Definition: bigdecimal.c:5463
#define f
VP_EXPORT void VpSzMantissa(Real *a, char *psz)
Definition: bigdecimal.c:5267
static VALUE rb_sym2str(VALUE sym)
Definition: bigdecimal.h:137
VP_EXPORT int VpPower(Real *y, Real *x, SIGNED_VALUE n)
Definition: bigdecimal.c:6253
VP_EXPORT unsigned short VpGetRoundMode(void)
Definition: bigdecimal.c:3597
VP_EXPORT int VpLeftRound(Real *y, unsigned short f, ssize_t nf)
Definition: bigdecimal.c:6095
VP_EXPORT Real * VpAlloc(size_t mx, const char *szVal)
Definition: bigdecimal.c:3978
#define FLEXIBLE_ARRAY_SIZE
Definition: bigdecimal.h:225
VP_EXPORT size_t VpInit(BDIGIT BaseVal)
Definition: bigdecimal.c:3890
VP_EXPORT double VpGetDoublePosInf(void)
Definition: bigdecimal.c:3686
VP_EXPORT int VpException(unsigned short f, const char *str, int always)
Definition: bigdecimal.c:3719
VP_EXPORT Real * VpOne(void)
Definition: bigdecimal.c:3921
VP_EXPORT unsigned short VpSetRoundMode(unsigned short n)
Definition: bigdecimal.c:3631
#define BDIGIT
Definition: bigdecimal.h:46
size_t MaxPrec
Definition: bigdecimal.h:234
#define SIGNED_VALUE
Definition: ruby.h:87