Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

converting string representation of MRB_INT_MIN raises an exception #3048

Closed
wants to merge 2 commits into from

Conversation

tsahara
Copy link
Member

@tsahara tsahara commented Dec 16, 2015

Without this patch, Integer("-2147483648") raises an exception. But it can be conveted to a Fixnum.

Before:

% bin/mruby -e 'Integer("-2147483648")'
trace:
        [0] -e:1
-e:1: string (-2147483648) too big for integer (ArgumentError)

After:

% bin/mruby -e 'p Integer("-2147483648")'
-2147483648

@matz
Copy link
Member

@matz matz commented Dec 16, 2015

I will fix this with some code cleanup.

@matz matz closed this in f54a98f Dec 16, 2015
@tsahara tsahara deleted the pr-mrb-int-min-to-str branch Jun 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants