/tinycbor-2.7.6/tests/parser/ |
D | tst_parser.cpp | 253 QTest::newRow("-2") << raw("\x21") << "-2"; in addFixedData() 274 QTest::newRow("0*2") << raw("\x19\x00\x00") << "0_1"; in addFixedData() 278 QTest::newRow("-1*2") << raw("\x39\x00\x00") << "-1_1"; in addFixedData() 308 QTest::newRow("2.f16^11-1") << raw("\xf9\x67\xff") << "2047.f16"; in addFixedData() 309 QTest::newRow("2.f^24-1") << raw("\xfa\x4b\x7f\xff\xff") << "16777215.f"; in addFixedData() 310 … QTest::newRow("2.^53-1") << raw("\xfb\x43\x3f\xff\xff""\xff\xff\xff\xff") << "9007199254740991."; in addFixedData() 311 QTest::newRow("2.f^64-epsilon") << raw("\xfa\x5f\x7f\xff\xff") << "18446742974197923840.f"; in addFixedData() 312 …QTest::newRow("2.^64-epsilon") << raw("\xfb\x43\xef\xff\xff""\xff\xff\xff\xff") << "18446744073709… in addFixedData() 313 QTest::newRow("2.f^64") << raw("\xfa\x5f\x80\0\0") << "1.8446744073709552e+19f"; in addFixedData() 314 QTest::newRow("2.^64") << raw("\xfb\x43\xf0\0\0\0\0\0\0") << "1.8446744073709552e+19"; in addFixedData() [all …]
|
/tinycbor-2.7.6/tests/tojson/ |
D | tst_tojson.cpp | 95 QTest::newRow("2^53-1") << raw("\x1b\0\x1f\xff\xff""\xff\xff\xff\xff") << "9007199254740991"; in addFixedData() 96 …QTest::newRow("2^64-epsilon") << raw("\x1b\xff\xff\xff\xff""\xff\xff\xf8\x00") << "184467440737095… in addFixedData() 100 QTest::newRow("-2") << raw("\x21") << "-2"; in addFixedData() 101 QTest::newRow("-2^53+1") << raw("\x3b\0\x1f\xff\xff""\xff\xff\xff\xfe") << "-9007199254740991"; in addFixedData() 102 …QTest::newRow("-2^64+epsilon") << raw("\x3b\xff\xff\xff\xff""\xff\xff\xf8\x00") << "-1844674407370… in addFixedData() 122 QTest::newRow("2.f^24-1") << raw("\xfa\x4b\x7f\xff\xff") << "16777215"; in addFixedData() 123 QTest::newRow("2.^53-1") << raw("\xfb\x43\x3f\xff\xff""\xff\xff\xff\xff") << "9007199254740991"; in addFixedData() 124 QTest::newRow("2.f^64-epsilon") << raw("\xfa\x5f\x7f\xff\xff") << "18446742974197923840"; in addFixedData() 125 …QTest::newRow("2.^64-epsilon") << raw("\xfb\x43\xef\xff\xff""\xff\xff\xff\xff") << "18446744073709… in addFixedData() 126 QTest::newRow("2.f^64") << raw("\xfa\x5f\x80\0\0") << "1.8446744073709552e+19"; in addFixedData() [all …]
|
/tinycbor-2.7.6/tests/encoder/ |
D | tst_encoder.cpp | 329 QTest::newRow("-2") << raw("\x21") << QVariant(-2); in addFixedData() 342 QTest::newRow("negative2") << raw("\x21") << neg(2); in addFixedData() 437 …QTest::newRow("map-array2") << raw("\xa1\x62oc\x84\0\1\2\3") << make_map({{"oc", make_list(0, 1, 2… in addArraysAndMaps() 438 …est::newRow("map-array3") << raw("\xa2\x62oc\x82\0\1\2\3") << make_map({{"oc", make_list(0, 1)}, {… in addArraysAndMaps() 465 …t::newRow("_map-array2") << raw("\xbf\x62oc\x84\0\1\2\3\xff") << make_ilmap({{"oc", make_list(0, 1… in addArraysAndMaps() 466 …wRow("_map-_array2") << raw("\xbf\x62oc\x9f\0\1\2\3\xff\xff") << make_ilmap({{"oc", make_ilarray({… in addArraysAndMaps() 467 …:newRow("_map-array3") << raw("\xbf\x62oc\x82\0\1\2\3\xff") << make_ilmap({{"oc", make_list(0, 1)}… in addArraysAndMaps() 468 …("_map-_array3") << raw("\xbf\x62oc\x9f\0\1\xff\2\3\xff") << make_ilmap({{"oc", make_ilarray({0, 1… in addArraysAndMaps() 473 …QTest::newRow("map-1(2):3(4)") << raw("\xa1\xc1\2\xc3\4") << make_map({{QVariant::fromValue(Tag{1,… in addArraysAndMaps() 629 compare(make_map({{1, make_map({{2, input}})}}), "\xa1\1\xa1\2" + output); in maps() [all …]
|
/tinycbor-2.7.6/tools/json2cbor/ |
D | json2cbor.c | 74 if (in[2] == '=' || in[2] == '\0') { in decode_base64_generic() 75 if (in[2] == '=' && (in[3] != '=' || in[4] != '\0')) in decode_base64_generic() 83 val |= reverse_alphabet[in[2]]; in decode_base64_generic() 86 val |= reverse_alphabet[in[2]] << 6; in decode_base64_generic() 111 -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, in decode_base64() 134 -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, in decode_base64url() 153 *len = strlen(string) / 2; in decode_base16() 159 char c = string[i * 2]; in decode_base16() 169 c = string[i * 2 + 1]; in decode_base16() 466 /* 2. parse as JSON */ in main()
|
/tinycbor-2.7.6/ |
D | maketag.pl | 75 print VERSION "#define TINYCBOR_VERSION_PATCH ", $v[2], "\n"; 80 s/^version:.*/version: $v[0].$v[1].$v[2]-build-{build}/; 91 print "Don't forget to create the docs.\n" if $v[2] == 1;
|
D | Makefile.configure | 20 @echo >&2 Please run from the top-level Makefile. 27 $(CC) -xc $($(subst check-,CCFLAGS-,$@)) -o /dev/null - $(if $(V),,>/dev/null 2>&1); \
|
D | Makefile | 43 BUILD_SHARED = $(shell file -L /bin/sh 2>/dev/null | grep -q ELF && echo 1) 72 GIT_DIR := $(strip $(shell git -C $(SRCDIR). rev-parse --git-dir 2> /dev/null)) 86 check_qmake = $(strip $(shell $(1) -query QT_VERSION 2>/dev/null | cut -b1)) 92 QMAKE := @echo >&2 $(MAKEFILE): Cannot find a Qt 5 qmake; false
|
D | .travis.yml | 60 TESTRUNNER=`which valgrind 2>/dev/null`
|
D | Doxyfile | 64 # directories (in 2 levels) under the output directory of each output format and 392 # cache size is given by this formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range 393 # is 0..9, the default is 0, corresponding to a cache size of 2^16=65536 2276 # or 2 may greatly reduce the computation time needed for large code bases. Also
|
/tinycbor-2.7.6/src/ |
D | cbortojson.c | 100 * representing integers numbers outside the range [-(2<sup>53</sup>)+1, 101 * 2<sup>53</sup>-1] and is not capable of representing NaN or infinite. If the 186 buffer = (uint8_t *)malloc(n * 2 + 1); in dump_bytestring_base16() 196 buffer[2*i] = characters[byte >> 4]; in dump_bytestring_base16() 197 buffer[2*i + 1] = characters[byte & 0xf]; in dump_bytestring_base16() 234 val = (in[i] << 16) | (in[i + 1] << 8) | in[i + 2]; in generic_dump_base64() 244 /* maybe 1 or 2 bytes left */ in generic_dump_base64() 260 if (n - i == 2) { in generic_dump_base64() 262 out[2] = alphabet[(val >> 6) & 0x3f]; in generic_dump_base64() 264 out[2] = alphabet[64]; /* filler */ in generic_dump_base64()
|
D | cborpretty.c | 123 return 0; /* should be n * 2, but we don't have the original n anymore */ in hexDump() 177 charsNeeded = 2; in utf8EscapedDump() 204 if (charsNeeded > 2) { in utf8EscapedDump() 314 * (that is, -1 is stored as 0, -2 as 1 and so forth) */ in value_to_pretty() 321 * 0x1`0000`0000`0000`0000 = 18446744073709551616 (2^64) */ in value_to_pretty()
|
D | tags.txt | 4 2;PositiveBignum;ByteString;Positive bignum
|
D | cborencoder.c | 260 uint64_t buf[2]; in encode_number_no_update() 360 unsigned size = 2U << (fpType - CborHalfFloatType); in cbor_encode_floating_point() 512 * \b{Implementation limitation:} TinyCBOR cannot encode more than SIZE_MAX/2 520 if (length != CborIndefiniteLength && length > SIZE_MAX / 2) in cbor_encoder_create_map()
|
D | cborparser.c | 144 * \li extra: partially decoded integer value (0, 1 or 2 bytes) 541 /* maps have keys and values, so we need to multiply by 2 */ in cbor_value_enter_container() 542 if (recursed->remaining > UINT32_MAX / 2) { in cbor_value_enter_container() 547 recursed->remaining *= 2; in cbor_value_enter_container() 762 * The range for int64_t is -2^63 to 2^63-1 (int64_t is required to be in cbor_value_get_int64_checked() 801 * But we can convert from signed to unsigned without fault (paragraph 2). in cbor_value_get_int_checked()
|
D | open_memstream.c | 71 size_t newalloc = newsize + newsize / 2 + 1; // give 50% more room in write_to_buffer()
|
D | cborvalidation.c | 141 <td>2</td> 247 { 2, (uint8_t)CborByteStringType }, 317 bytesNeeded += 2; in validate_number()
|
D | parsetags.pl | 52 $tags{$1}{id} = $2;
|
/tinycbor-2.7.6/include/tinycbor/ |
D | utf8_p.h | 52 charsNeeded = 2; in get_utf8() 79 if (charsNeeded > 2) { in get_utf8()
|
D | cborconstants_p.h | 35 ByteStringType = 2U,
|
D | cborjson.h | 38 CborConvertTagsToObjects = 2,
|
D | cborinternal_p.h | 46 ByteStringType = 2U,
|
D | extract_number_p.h | 70 } else if (bytesNeeded == 2) { in extract_number()
|
D | cbor.h | 100 CborPositiveBignumTag = 2, 156 CborErrorOutOfMemory = ~0U / 2 + 1,
|
D | compilersupport_p.h | 64 # define cbor_static_assert(x) ((void)sizeof(char[2*!!(x) - 1]))
|