bigdecimal 2.0.3 → 3.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bigdecimal.gemspec +1 -1
- data/ext/bigdecimal/bigdecimal.c +12 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1b3519c64aa42c80e19107fc6d5d78d81385d7d71b9c09abef67c4e4c6a0bcef
|
4
|
+
data.tar.gz: 4ab9cb50f0a24014262635c07ecb42e6891326b49de50f262550e22d00c586ed
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8e4aa6023012625b46f68a9e58d79a5ea0aa2c579ddb4245e0753a01118d62bd75fa5a708535346ab295619aa2ad9974a929189a83a00d56321c295a1ec8498c
|
7
|
+
data.tar.gz: 5717f808a7a56ae06b5060a3752fcaf3a9b47dca9dceb8e6822e603ec20f0296b711df04d1454a309ac6720d4af60e9b4e58f3477133f7a66e20eab75207a70e
|
data/bigdecimal.gemspec
CHANGED
data/ext/bigdecimal/bigdecimal.c
CHANGED
@@ -189,11 +189,16 @@ BigDecimal_memsize(const void *ptr)
|
|
189
189
|
return (sizeof(*pv) + pv->MaxPrec * sizeof(BDIGIT));
|
190
190
|
}
|
191
191
|
|
192
|
+
#ifndef HAVE_RB_EXT_RACTOR_SAFE
|
193
|
+
# undef RUBY_TYPED_FROZEN_SHAREABLE
|
194
|
+
# define RUBY_TYPED_FROZEN_SHAREABLE 0
|
195
|
+
#endif
|
196
|
+
|
192
197
|
static const rb_data_type_t BigDecimal_data_type = {
|
193
198
|
"BigDecimal",
|
194
199
|
{ 0, BigDecimal_delete, BigDecimal_memsize, },
|
195
200
|
#ifdef RUBY_TYPED_FREE_IMMEDIATELY
|
196
|
-
0, 0, RUBY_TYPED_FREE_IMMEDIATELY
|
201
|
+
0, 0, RUBY_TYPED_FREE_IMMEDIATELY | RUBY_TYPED_FROZEN_SHAREABLE
|
197
202
|
#endif
|
198
203
|
};
|
199
204
|
|
@@ -3450,6 +3455,9 @@ get_vp_value:
|
|
3450
3455
|
void
|
3451
3456
|
Init_bigdecimal(void)
|
3452
3457
|
{
|
3458
|
+
#ifdef HAVE_RB_EXT_RACTOR_SAFE
|
3459
|
+
rb_ext_ractor_safe(true);
|
3460
|
+
#endif
|
3453
3461
|
VALUE arg;
|
3454
3462
|
|
3455
3463
|
id_BigDecimal_exception_mode = rb_intern_const("BigDecimal.exception_mode");
|
@@ -3718,6 +3726,9 @@ static void VpFormatSt(char *psz, size_t fFmt);
|
|
3718
3726
|
static int VpRdup(Real *m, size_t ind_m);
|
3719
3727
|
|
3720
3728
|
#ifdef BIGDECIMAL_DEBUG
|
3729
|
+
# ifdef HAVE_RB_EXT_RACTOR_SAFE
|
3730
|
+
# error Need to make rewiting gnAlloc atomic
|
3731
|
+
# endif
|
3721
3732
|
static int gnAlloc = 0; /* Memory allocation counter */
|
3722
3733
|
#endif /* BIGDECIMAL_DEBUG */
|
3723
3734
|
|