summaryrefslogtreecommitdiff
path: root/ext/bigdecimal/util/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'ext/bigdecimal/util/util.c')
-rw-r--r--ext/bigdecimal/util/util.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/ext/bigdecimal/util/util.c b/ext/bigdecimal/util/util.c
new file mode 100644
index 00000000000..8d38d87852d
--- /dev/null
+++ b/ext/bigdecimal/util/util.c
@@ -0,0 +1,9 @@
+#include "ruby.h"
+
+RUBY_EXTERN VALUE rmpd_util_str_to_d(VALUE str);
+
+void
+Init_util(void)
+{
+ rb_define_method(rb_cString, "to_d", rmpd_util_str_to_d, 0);
+}