Removed trailing spaces
This commit is contained in:
parent
d1f3c81258
commit
ee85745c61
@ -186,7 +186,7 @@ static void fbuffer_append_long(FBuffer *fb, long number)
|
|||||||
* the number of resulting characters.
|
* the number of resulting characters.
|
||||||
*
|
*
|
||||||
* We do know, however, that the `number` argument is always in the
|
* We do know, however, that the `number` argument is always in the
|
||||||
* range 0xc000000000000000 to 0x3fffffffffffffff, or, in decimal,
|
* range 0xc000000000000000 to 0x3fffffffffffffff, or, in decimal,
|
||||||
* -4611686018427387904 to 4611686018427387903. The max number of chars
|
* -4611686018427387904 to 4611686018427387903. The max number of chars
|
||||||
* generated is therefore 20 (including a potential sign character).
|
* generated is therefore 20 (including a potential sign character).
|
||||||
*/
|
*/
|
||||||
@ -198,7 +198,7 @@ static void fbuffer_append_long(FBuffer *fb, long number)
|
|||||||
if (number < 0) {
|
if (number < 0) {
|
||||||
fbuffer_append_reserved_char(fb, '-');
|
fbuffer_append_reserved_char(fb, '-');
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Since number is always > LONG_MIN, `-number` will not overflow
|
* Since number is always > LONG_MIN, `-number` will not overflow
|
||||||
* and is always the positive abs() value.
|
* and is always the positive abs() value.
|
||||||
*/
|
*/
|
||||||
|
3
ext/json/vendor/jeaiii-ltoa.h
vendored
3
ext/json/vendor/jeaiii-ltoa.h
vendored
@ -87,7 +87,7 @@ static u64_t mask24 = (u64(1) << 24) - 1;
|
|||||||
static u64_t mask32 = (u64(1) << 32) - 1;
|
static u64_t mask32 = (u64(1) << 32) - 1;
|
||||||
static u64_t mask57 = (u64(1) << 57) - 1;
|
static u64_t mask57 = (u64(1) << 57) - 1;
|
||||||
|
|
||||||
static
|
static
|
||||||
char* to_text_from_ulong(char* b, u64_t n) {
|
char* to_text_from_ulong(char* b, u64_t n) {
|
||||||
if (n < u32(1e2))
|
if (n < u32(1e2))
|
||||||
{
|
{
|
||||||
@ -254,4 +254,3 @@ char* to_text_from_ulong(char* b, u64_t n) {
|
|||||||
#pragma GCC diagnostic pop
|
#pragma GCC diagnostic pop
|
||||||
|
|
||||||
#endif // JEAIII_TO_TEXT_H_
|
#endif // JEAIII_TO_TEXT_H_
|
||||||
|
|
||||||
|
@ -707,7 +707,7 @@ class JSONGeneratorTest < Test::Unit::TestCase
|
|||||||
assert_equal expected, value.to_json
|
assert_equal expected, value.to_json
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_numbers_of_various_sizes
|
def test_numbers_of_various_sizes
|
||||||
numbers = [
|
numbers = [
|
||||||
0, 1, -1, 9, -9, 13, -13, 91, -91, 513, -513, 7513, -7513,
|
0, 1, -1, 9, -9, 13, -13, 91, -91, 513, -513, 7513, -7513,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user