On Thu, Apr 15, 2021 at 04:05:27PM +0200, Aleksandar Lazic wrote:
> Well I don't think so because 4 is still bigger then -9007199254740991 ;-)

This is because *you* think it is -9007199254740991 but the reality
is that it's not this.due to ULL:

  #define JSON_INT_MAX ((1ULL << 53) - 1)
  #define JSON_INT_MIN (-JSON_INT_MAX)

=> it's -9007199254740991ULL hence 18437736874454810625 so 4 is
   definitely not larger than this.


> Never the less I have changed the defines and rerun the tests.
> Btw, this vtest is a great enhancement to haproxy ;-)

Yes I totally agree. And you can't imagine how many times I'm angry
at it when it detects an error after a tiny change I make, just to
realize that I did really break something and that it was right :-)
Like all tools it just needs to be reasonably used, not excessively
trusted but used as a good hint that something unexpected changed,
and it helps a lot!


> ```
> #define JSON_INT_MAX ((1ULL << 53) - 1)
                          ^
Sorry I was not clear, please drop that 'U' here.

Willy

Reply via email to