[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Format Question
- From: Daurnimator <quae@...>
- Date: Wed, 29 Aug 2012 23:48:27 +1000
On 29 August 2012 17:28, Patrick Rapin <toupie300@gmail.com> wrote:
>> Why 5.1 support negative and 5.2 do not support negative operating it?
>
> Only Lua authors can really answer this question. I can just make a guess.
> IMHO, Lua 5.1 _tolerates_ negative values for format %X rather that
> _supports_ them.
> You have to realize that the result of string.format("%X",-1) is not
> defined : is it 0xFF, 0xFFFF, 0xFFFFFFFF, 0xFFFFFFFFFFFFFFFF, ... ?
> Lua 5.2 is more strict concerning range of accepted numerical values.
>
"-1" would be a smart result ;)