summaryrefslogtreecommitdiff
path: root/ext/bigdecimal/bigdecimal.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-05-07 02:03:28 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-05-07 02:03:28 +0000
commit0fce0545b607e1ac92457cc8523645c294c2d411 (patch)
tree9fc13c4b1c9f0b5fd05110a50f5056b2294822ac /ext/bigdecimal/bigdecimal.c
parentcc3f33073dc1c475f59a14753a4203c193f9fbfc (diff)
* ext/bigdecimal/bigdecimal.c (Init_bigdecimal): define IDs before
they are used. [ruby-core:44900] [Bug #6406] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35555 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/bigdecimal/bigdecimal.c')
-rw-r--r--ext/bigdecimal/bigdecimal.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/bigdecimal/bigdecimal.c b/ext/bigdecimal/bigdecimal.c
index 041d33f..a2d705c 100644
--- a/ext/bigdecimal/bigdecimal.c
+++ b/ext/bigdecimal/bigdecimal.c
@@ -2858,6 +2858,10 @@ Init_bigdecimal(void)
{
VALUE arg;
+ id_BigDecimal_exception_mode = rb_intern_const("BigDecimal.exception_mode");
+ id_BigDecimal_rounding_mode = rb_intern_const("BigDecimal.rounding_mode");
+ id_BigDecimal_precision_limit = rb_intern_const("BigDecimal.precision_limit");
+
/* Initialize VP routines */
VpInit(0UL);
@@ -3053,10 +3057,6 @@ Init_bigdecimal(void)
rb_define_singleton_method(rb_mBigMath, "exp", BigMath_s_exp, 2);
rb_define_singleton_method(rb_mBigMath, "log", BigMath_s_log, 2);
- id_BigDecimal_exception_mode = rb_intern_const("BigDecimal.exception_mode");
- id_BigDecimal_rounding_mode = rb_intern_const("BigDecimal.rounding_mode");
- id_BigDecimal_precision_limit = rb_intern_const("BigDecimal.precision_limit");
-
id_up = rb_intern_const("up");
id_down = rb_intern_const("down");
id_truncate = rb_intern_const("truncate");