should use mrb_type() for the sake of MRB_WORD_BOXING
fix overflow error like #2244 on MRB_WORD_BOXING