From 65b87de350e36eaba77ab2db30b5cfbaf19f61b0 Mon Sep 17 00:00:00 2001 From: nobu Date: Thu, 7 Sep 2017 03:24:08 +0000 Subject: ruby.h: unnormalized Fixnum value * include/ruby/ruby.h (ST2FIX): fix unnormalized Fixnum value bug on mingw/mswin. [ruby-core:82687] [Bug #13877] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@59765 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- include/ruby/ruby.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include') diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h index 43a5f6fdeb..ff1c463a29 100644 --- a/include/ruby/ruby.h +++ b/include/ruby/ruby.h @@ -1575,6 +1575,9 @@ rb_num2char_inline(VALUE x) #define NUM2CHR(x) RB_NUM2CHR(x) #define CHR2FIX(x) RB_CHR2FIX(x) +#define RB_ST2FIX(h) RB_LONG2FIX((long)(h)) +#define ST2FIX(h) RB_ST2FIX(h) + #define RB_ALLOC_N(type,n) ((type*)ruby_xmalloc2((size_t)(n),sizeof(type))) #define RB_ALLOC(type) ((type*)ruby_xmalloc(sizeof(type))) #define RB_ZALLOC_N(type,n) ((type*)ruby_xcalloc((size_t)(n),sizeof(type))) -- cgit v1.2.3