1{ 2 "description": "Decimal128", 3 "bson_type": "0x13", 4 "test_key": "d", 5 "valid": [ 6 { 7 "description": "[basx023] conform to rules and exponent will be in permitted range).", 8 "canonical_bson": "1800000013640001000000000000000000000000003EB000", 9 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"-0.1\"}}" 10 }, 11 12 { 13 "description": "[basx045] strings without E cannot generate E in result", 14 "canonical_bson": "1800000013640003000000000000000000000000003A3000", 15 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \"+0.003\"}}", 16 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.003\"}}" 17 }, 18 { 19 "description": "[basx610] Zeros", 20 "canonical_bson": "1800000013640000000000000000000000000000003E3000", 21 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \".0\"}}", 22 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.0\"}}" 23 }, 24 { 25 "description": "[basx612] Zeros", 26 "canonical_bson": "1800000013640000000000000000000000000000003EB000", 27 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \"-.0\"}}", 28 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"-0.0\"}}" 29 }, 30 { 31 "description": "[basx043] strings without E cannot generate E in result", 32 "canonical_bson": "18000000136400FC040000000000000000000000003C3000", 33 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \"+12.76\"}}", 34 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"12.76\"}}" 35 }, 36 { 37 "description": "[basx055] strings without E cannot generate E in result", 38 "canonical_bson": "180000001364000500000000000000000000000000303000", 39 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.00000005\"}}", 40 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"5E-8\"}}" 41 }, 42 { 43 "description": "[basx054] strings without E cannot generate E in result", 44 "canonical_bson": "180000001364000500000000000000000000000000323000", 45 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.0000005\"}}", 46 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"5E-7\"}}" 47 }, 48 { 49 "description": "[basx052] strings without E cannot generate E in result", 50 "canonical_bson": "180000001364000500000000000000000000000000343000", 51 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.000005\"}}" 52 }, 53 { 54 "description": "[basx051] strings without E cannot generate E in result", 55 "canonical_bson": "180000001364000500000000000000000000000000363000", 56 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \"00.00005\"}}", 57 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.00005\"}}" 58 }, 59 { 60 "description": "[basx050] strings without E cannot generate E in result", 61 "canonical_bson": "180000001364000500000000000000000000000000383000", 62 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.0005\"}}" 63 }, 64 { 65 "description": "[basx047] strings without E cannot generate E in result", 66 "canonical_bson": "1800000013640005000000000000000000000000003E3000", 67 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \".5\"}}", 68 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.5\"}}" 69 }, 70 { 71 "description": "[dqbsr431] check rounding modes heeded (Rounded)", 72 "canonical_bson": "1800000013640099761CC7B548F377DC80A131C836FE2F00", 73 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \"1.1111111111111111111111111111123450\"}}", 74 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"1.111111111111111111111111111112345\"}}" 75 }, 76 { 77 "description": "OK2", 78 "canonical_bson": "18000000136400000000000A5BC138938D44C64D31FC2F00", 79 "degenerate_extjson": "{\"d\" : {\"$numberDecimal\" : \".100000000000000000000000000000000000000000000000000000000000\"}}", 80 "canonical_extjson": "{\"d\" : {\"$numberDecimal\" : \"0.1000000000000000000000000000000000\"}}" 81 } 82 ], 83 "parseErrors": [ 84 { 85 "description": "[basx564] Near-specials (Conversion_syntax)", 86 "string": "Infi" 87 }, 88 { 89 "description": "[basx565] Near-specials (Conversion_syntax)", 90 "string": "Infin" 91 }, 92 { 93 "description": "[basx566] Near-specials (Conversion_syntax)", 94 "string": "Infini" 95 }, 96 { 97 "description": "[basx567] Near-specials (Conversion_syntax)", 98 "string": "Infinit" 99 }, 100 { 101 "description": "[basx568] Near-specials (Conversion_syntax)", 102 "string": "-Infinit" 103 }, 104 { 105 "description": "[basx590] some baddies with dots and Es and dots and specials (Conversion_syntax)", 106 "string": ".Infinity" 107 }, 108 { 109 "description": "[basx562] Near-specials (Conversion_syntax)", 110 "string": "NaNq" 111 }, 112 { 113 "description": "[basx563] Near-specials (Conversion_syntax)", 114 "string": "NaNs" 115 }, 116 { 117 "description": "[dqbas939] overflow results at different rounding modes (Overflow & Inexact & Rounded)", 118 "string": "-7e10000" 119 }, 120 { 121 "description": "[dqbsr534] negatives (Rounded & Inexact)", 122 "string": "-1.11111111111111111111111111111234650" 123 }, 124 { 125 "description": "[dqbsr535] negatives (Rounded & Inexact)", 126 "string": "-1.11111111111111111111111111111234551" 127 }, 128 { 129 "description": "[dqbsr533] negatives (Rounded & Inexact)", 130 "string": "-1.11111111111111111111111111111234550" 131 }, 132 { 133 "description": "[dqbsr532] negatives (Rounded & Inexact)", 134 "string": "-1.11111111111111111111111111111234549" 135 }, 136 { 137 "description": "[dqbsr432] check rounding modes heeded (Rounded & Inexact)", 138 "string": "1.11111111111111111111111111111234549" 139 }, 140 { 141 "description": "[dqbsr433] check rounding modes heeded (Rounded & Inexact)", 142 "string": "1.11111111111111111111111111111234550" 143 }, 144 { 145 "description": "[dqbsr435] check rounding modes heeded (Rounded & Inexact)", 146 "string": "1.11111111111111111111111111111234551" 147 }, 148 { 149 "description": "[dqbsr434] check rounding modes heeded (Rounded & Inexact)", 150 "string": "1.11111111111111111111111111111234650" 151 }, 152 { 153 "description": "[dqbas938] overflow results at different rounding modes (Overflow & Inexact & Rounded)", 154 "string": "7e10000" 155 }, 156 { 157 "description": "Inexact rounding#1", 158 "string": "100000000000000000000000000000000000000000000000000000000001" 159 }, 160 { 161 "description": "Inexact rounding#2", 162 "string": "1E-6177" 163 } 164 ] 165} 166