fix: mrbgems\mruby-string-ext\src\string.c(38): warning C4244: '=': conversion from 'mrb_int' to 'char', possible loss of data

This commit is contained in:
Tomasz Dąbrowski
2017-09-25 17:09:33 +02:00
committed by Tomasz Dabrowski
parent a94525d4ea
commit d3819620ce
+1 -1
View File
@@ -35,7 +35,7 @@ mrb_str_setbyte(mrb_state *mrb, mrb_value str)
mrb_str_modify(mrb, mrb_str_ptr(str));
byte &= 0xff;
RSTRING_PTR(str)[pos] = byte;
RSTRING_PTR(str)[pos] = (unsigned char)byte;
return mrb_fixnum_value((unsigned char)byte);
}