PragmaTwice commented on PR #2340: URL: https://github.com/apache/kvrocks/pull/2340#issuecomment-2141787853
> > Please just add a catch block. Try not to add any meaningless weird code. > > Simple catch doesn't seem to work, some overflow cases can return results that don't meet expectations without throwing exceptions For example, 9223372036854775806<std:: numericlimits:: max() +20 is a negative number and will not throw an exception It can be actually well defined. It follows the [two's complement](https://en.m.wikipedia.org/wiki/Two's_complement). So generally we can leave it as is until we make a big number implementation available. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
