aboutsummaryrefslogtreecommitdiffstats
path: root/template/sizes.c.tmpl
diff options
context:
space:
mode:
authorshyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-01-30 10:12:18 +0000
committershyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-01-30 10:12:18 +0000
commit89c862faff2f0b87bd37b8ece9339705e2f893ac (patch)
tree5952761bd69f8b1c17462aca1bf582b040d13df2 /template/sizes.c.tmpl
parentb5a6739adffc87b9d296ef4c3704bf3b74c750c2 (diff)
downloadruby-89c862faff2f0b87bd37b8ece9339705e2f893ac.tar.gz
make FIXNUM_MAX visible from Ruby
Because our tests now have several places where FIXNUM_MAX is needed, we decided to provide it along with several other constants. * template/limits.c.tmpl: new file, defining RbConfig::Limits * ext/rbconfig/sizeof/depend (limits.c): rule to generate limits.c * test/-ext-/num2int/test_num2int.rb: use RbConfig::Limits * bootstraptest/test_insns.rb: ditto. * .gitignore: ignore new generated file. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57465 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'template/sizes.c.tmpl')
-rw-r--r--template/sizes.c.tmpl2
1 files changed, 2 insertions, 0 deletions
diff --git a/template/sizes.c.tmpl b/template/sizes.c.tmpl
index 2d23cacace..75c1ff22c9 100644
--- a/template/sizes.c.tmpl
+++ b/template/sizes.c.tmpl
@@ -28,6 +28,7 @@ conditions = {
void
Init_sizeof(void)
{
+ extern void Init_limits();
VALUE s = rb_hash_new();
rb_define_const(rb_define_module("RbConfig"), "SIZEOF", s);
@@ -48,4 +49,5 @@ Init_sizeof(void)
% end
#undef DEFINE
+ Init_limits();
}