Re: Maybe bug - string representation of a literal mininteger
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: Maybe bug - string representation of a literal mininteger
- From: pocomane <pocomane_7a@...>
- Date: 2018年11月27日 14:16:51 +0100
On Tue, Nov 27, 2018 at 12:52 PM Muh Muhten <muh.muhten@gmail.com> wrote:
> It seems to me that making this particular case work would be rather
> involved, and essentially require negative numbers to be first-class
> citizens in the grammar, rather than cobbled together through unary
> minus and constant folding. I also don't see a satisfying solution
> for, e.g. "- 9223372036854775808", "- --[[]]9223372036854775808",
> "-(9223372036854775808)", though arguably those are *explicitly* the
> negation of positive 9223372036854775808, which doesn't fit, and
> really should be an integer.
I am just using - 9223372036854775807-1 in my code (in test suites, I
prefer explicit number over math.mininteger). If it is complex to fix,
I think it could stay as it is. Maybe just a warning in the manual
could be useful.