@fireproof/vendor 1.0.0 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (141) hide show
  1. package/package.json +12 -8
  2. package/src/@ipld/car/README.md +229 -175
  3. package/src/@ipld/car/dist/src/reader.d.ts.map +1 -1
  4. package/src/@ipld/car/src/reader.js +19 -2
  5. package/src/cborg/.github/dependabot.yml +16 -0
  6. package/src/cborg/.github/workflows/test-and-release.yml +52 -0
  7. package/src/cborg/{lib → cborg}/bin.js +2 -2
  8. package/src/cborg/cborg/common.js +28 -0
  9. package/src/cborg/{lib → cborg}/decode.js +24 -22
  10. package/src/cborg/{lib → cborg}/diagnostic.js +6 -4
  11. package/src/cborg/{lib → cborg}/diagnostic_test.js +1 -1
  12. package/src/cborg/{lib → cborg}/encode.js +23 -21
  13. package/src/cborg/{cborg.js → cborg/index.js} +12 -10
  14. package/src/cborg/{lib → cborg}/length.js +3 -2
  15. package/src/cborg/interface.ts +7 -4
  16. package/src/cborg/{lib/json → json}/decode.js +25 -25
  17. package/src/cborg/{lib/json → json}/encode.js +19 -16
  18. package/src/cborg/taglib.js +3 -1
  19. package/src/cborg/test/common.js +1 -1
  20. package/src/cborg/test/noop-bin-test.js +1 -1
  21. package/src/cborg/test/test-0uint.js +2 -2
  22. package/src/cborg/test/test-1negint.js +2 -2
  23. package/src/cborg/test/test-2bytes.js +2 -2
  24. package/src/cborg/test/test-3string.js +2 -2
  25. package/src/cborg/test/test-4array.js +2 -2
  26. package/src/cborg/test/test-5map.js +2 -2
  27. package/src/cborg/test/test-6tag.js +2 -3
  28. package/src/cborg/test/test-7float.js +2 -2
  29. package/src/cborg/test/test-bl.js +1 -1
  30. package/src/cborg/test/test-cbor-vectors.js +2 -2
  31. package/src/cborg/test/test-decode-errors.js +2 -2
  32. package/src/cborg/test/test-fuzz.js +1 -1
  33. package/src/cborg/test/test-json.js +25 -25
  34. package/src/cborg/test/test-length.js +3 -3
  35. package/src/cborg/test/test-partial.js +2 -2
  36. package/src/cborg/tsconfig.json +5 -2
  37. package/src/cborg/types/{lib → cborg}/decode.d.ts +5 -3
  38. package/src/cborg/types/cborg/decode.d.ts.map +1 -0
  39. package/src/cborg/types/{lib → cborg}/encode.d.ts +4 -3
  40. package/src/cborg/types/cborg/encode.d.ts.map +1 -0
  41. package/src/cborg/types/cborg/index.d.ts +26 -0
  42. package/src/cborg/types/cborg/index.d.ts.map +1 -0
  43. package/src/cborg/types/cborg/is.d.ts.map +1 -0
  44. package/src/cborg/types/interface.d.ts +6 -4
  45. package/src/cborg/types/interface.d.ts.map +1 -1
  46. package/src/cborg/types/{lib/json → json}/decode.d.ts +7 -7
  47. package/src/cborg/types/json/decode.d.ts.map +1 -0
  48. package/src/cborg/types/json/encode.d.ts +11 -0
  49. package/src/cborg/types/json/encode.d.ts.map +1 -0
  50. package/src/cborg/types/json/json.d.ts.map +1 -0
  51. package/src/cborg/types/taglib.d.ts +1 -1
  52. package/src/cborg/types/taglib.d.ts.map +1 -1
  53. package/src/cborg/types/tsconfig.tsbuildinfo +1 -1
  54. package/src/cborg/types/{lib → utils}/0uint.d.ts +6 -4
  55. package/src/cborg/types/utils/0uint.d.ts.map +1 -0
  56. package/src/cborg/types/{lib → utils}/1negint.d.ts +4 -3
  57. package/src/cborg/types/utils/1negint.d.ts.map +1 -0
  58. package/src/cborg/types/{lib → utils}/2bytes.d.ts +5 -4
  59. package/src/cborg/types/utils/2bytes.d.ts.map +1 -0
  60. package/src/cborg/types/{lib → utils}/3string.d.ts +1 -1
  61. package/src/cborg/types/utils/3string.d.ts.map +1 -0
  62. package/src/cborg/types/{lib → utils}/4array.d.ts +3 -2
  63. package/src/cborg/types/utils/4array.d.ts.map +1 -0
  64. package/src/cborg/types/{lib → utils}/5map.d.ts +3 -2
  65. package/src/cborg/types/utils/5map.d.ts.map +1 -0
  66. package/src/cborg/types/{lib → utils}/6tag.d.ts +4 -3
  67. package/src/cborg/types/utils/6tag.d.ts.map +1 -0
  68. package/src/cborg/types/{lib → utils}/7float.d.ts +2 -2
  69. package/src/cborg/types/utils/7float.d.ts.map +1 -0
  70. package/src/cborg/types/utils/bl.d.ts.map +1 -0
  71. package/src/cborg/types/utils/byte-utils.d.ts.map +1 -0
  72. package/src/cborg/types/utils/common.d.ts +8 -0
  73. package/src/cborg/types/utils/common.d.ts.map +1 -0
  74. package/src/cborg/types/utils/index.d.ts +13 -0
  75. package/src/cborg/types/utils/index.d.ts.map +1 -0
  76. package/src/cborg/types/utils/jump.d.ts +16 -0
  77. package/src/cborg/types/utils/jump.d.ts.map +1 -0
  78. package/src/cborg/types/utils/token.d.ts.map +1 -0
  79. package/src/cborg/{lib → utils}/0uint.js +16 -14
  80. package/src/cborg/{lib → utils}/1negint.js +5 -5
  81. package/src/cborg/{lib → utils}/2bytes.js +16 -14
  82. package/src/cborg/{lib → utils}/3string.js +4 -4
  83. package/src/cborg/{lib → utils}/4array.js +7 -6
  84. package/src/cborg/{lib → utils}/5map.js +6 -6
  85. package/src/cborg/{lib → utils}/6tag.js +4 -3
  86. package/src/cborg/{lib → utils}/7float.js +23 -21
  87. package/src/cborg/{lib → utils}/bl.js +1 -1
  88. package/src/cborg/utils/common.js +11 -0
  89. package/src/cborg/utils/index.js +12 -0
  90. package/src/cborg/utils/jump.js +222 -0
  91. package/src/@ipld/car/package.json +0 -235
  92. package/src/@ipld/dag-cbor/package.json +0 -171
  93. package/src/@ipld/dag-json/package.json +0 -173
  94. package/src/@web3-storage/pail/package.json +0 -173
  95. package/src/cborg/lib/common.js +0 -27
  96. package/src/cborg/lib/jump.js +0 -209
  97. package/src/cborg/package.json +0 -168
  98. package/src/cborg/types/cborg.d.ts +0 -28
  99. package/src/cborg/types/cborg.d.ts.map +0 -1
  100. package/src/cborg/types/lib/0uint.d.ts.map +0 -1
  101. package/src/cborg/types/lib/1negint.d.ts.map +0 -1
  102. package/src/cborg/types/lib/2bytes.d.ts.map +0 -1
  103. package/src/cborg/types/lib/3string.d.ts.map +0 -1
  104. package/src/cborg/types/lib/4array.d.ts.map +0 -1
  105. package/src/cborg/types/lib/5map.d.ts.map +0 -1
  106. package/src/cborg/types/lib/6tag.d.ts.map +0 -1
  107. package/src/cborg/types/lib/7float.d.ts.map +0 -1
  108. package/src/cborg/types/lib/bin.d.ts +0 -4
  109. package/src/cborg/types/lib/bin.d.ts.map +0 -1
  110. package/src/cborg/types/lib/bl.d.ts.map +0 -1
  111. package/src/cborg/types/lib/byte-utils.d.ts.map +0 -1
  112. package/src/cborg/types/lib/common.d.ts +0 -10
  113. package/src/cborg/types/lib/common.d.ts.map +0 -1
  114. package/src/cborg/types/lib/decode.d.ts.map +0 -1
  115. package/src/cborg/types/lib/diagnostic.d.ts +0 -12
  116. package/src/cborg/types/lib/diagnostic.d.ts.map +0 -1
  117. package/src/cborg/types/lib/diagnostic_test.d.ts +0 -2
  118. package/src/cborg/types/lib/diagnostic_test.d.ts.map +0 -1
  119. package/src/cborg/types/lib/encode.d.ts.map +0 -1
  120. package/src/cborg/types/lib/is.d.ts.map +0 -1
  121. package/src/cborg/types/lib/json/decode.d.ts.map +0 -1
  122. package/src/cborg/types/lib/json/encode.d.ts +0 -11
  123. package/src/cborg/types/lib/json/encode.d.ts.map +0 -1
  124. package/src/cborg/types/lib/json/forward-cborg.d.ts +0 -6
  125. package/src/cborg/types/lib/json/forward-cborg.d.ts.map +0 -1
  126. package/src/cborg/types/lib/json/json.d.ts.map +0 -1
  127. package/src/cborg/types/lib/jump.d.ts +0 -12
  128. package/src/cborg/types/lib/jump.d.ts.map +0 -1
  129. package/src/cborg/types/lib/length.d.ts +0 -27
  130. package/src/cborg/types/lib/length.d.ts.map +0 -1
  131. package/src/cborg/types/lib/token.d.ts.map +0 -1
  132. package/src/ipfs-unixfs-exporter/package.json +0 -180
  133. /package/src/cborg/{lib → cborg}/is.js +0 -0
  134. /package/src/cborg/{lib/json → json}/json.js +0 -0
  135. /package/src/cborg/types/{lib → cborg}/is.d.ts +0 -0
  136. /package/src/cborg/types/{lib/json → json}/json.d.ts +0 -0
  137. /package/src/cborg/types/{lib → utils}/bl.d.ts +0 -0
  138. /package/src/cborg/types/{lib → utils}/byte-utils.d.ts +0 -0
  139. /package/src/cborg/types/{lib → utils}/token.d.ts +0 -0
  140. /package/src/cborg/{lib → utils}/byte-utils.js +0 -0
  141. /package/src/cborg/{lib → utils}/token.js +0 -0
@@ -1,173 +0,0 @@
1
- {
2
- "name": "@web3-storage/pail",
3
- "version": "0.6.0",
4
- "description": "DAG based key value store.",
5
- "main": "src/index.js",
6
- "type": "module",
7
- "types": "./dist/src/index.d.ts",
8
- "typesVersions": {
9
- "*": {
10
- "*": [
11
- "dist/*"
12
- ],
13
- "dist/src/index.d.ts": [
14
- "dist/src/index.d.ts"
15
- ],
16
- "api": [
17
- "dist/src/api.d.ts"
18
- ],
19
- "batch": [
20
- "dist/src/batch/index.d.ts"
21
- ],
22
- "batch/api": [
23
- "dist/src/batch/api.d.ts"
24
- ],
25
- "block": [
26
- "dist/src/block.d.ts"
27
- ],
28
- "clock": [
29
- "dist/src/clock/index.d.ts"
30
- ],
31
- "clock/api": [
32
- "dist/src/clock/api.d.ts"
33
- ],
34
- "crdt": [
35
- "dist/src/crdt/index.d.ts"
36
- ],
37
- "crdt/api": [
38
- "dist/src/crdt/api.d.ts"
39
- ],
40
- "crdt/batch": [
41
- "dist/src/crdt/batch/index.d.ts"
42
- ],
43
- "crdt/batch/api": [
44
- "dist/src/crdt/batch/api.d.ts"
45
- ],
46
- "diff": [
47
- "dist/src/diff.d.ts"
48
- ],
49
- "link": [
50
- "dist/src/link.d.ts"
51
- ],
52
- "merge": [
53
- "dist/src/merge.d.ts"
54
- ],
55
- "shard": [
56
- "dist/src/shard.d.ts"
57
- ]
58
- }
59
- },
60
- "exports": {
61
- ".": {
62
- "types": "./dist/src/index.d.ts",
63
- "import": "./src/index.js"
64
- },
65
- "./api": {
66
- "types": "./dist/src/api.d.ts",
67
- "import": "./src/api.js"
68
- },
69
- "./batch": {
70
- "types": "./dist/src/batch/index.d.ts",
71
- "import": "./src/batch/index.js"
72
- },
73
- "./batch/api": {
74
- "types": "./dist/src/batch/api.d.ts",
75
- "import": "./src/batch/api.js"
76
- },
77
- "./block": {
78
- "types": "./dist/src/block.d.ts",
79
- "import": "./src/block.js"
80
- },
81
- "./clock": {
82
- "types": "./dist/src/clock/index.d.ts",
83
- "import": "./src/clock/index.js"
84
- },
85
- "./clock/api": {
86
- "types": "./dist/src/clock/api.d.ts",
87
- "import": "./src/clock/api.js"
88
- },
89
- "./crdt": {
90
- "types": "./dist/src/crdt/index.d.ts",
91
- "import": "./src/crdt/index.js"
92
- },
93
- "./crdt/api": {
94
- "types": "./dist/src/crdt/api.d.ts",
95
- "import": "./src/crdt/api.js"
96
- },
97
- "./crdt/batch": {
98
- "types": "./dist/src/crdt/batch/index.d.ts",
99
- "import": "./src/crdt/batch/index.js"
100
- },
101
- "./crdt/batch/api": {
102
- "types": "./dist/src/crdt/batch/api.d.ts",
103
- "import": "./src/crdt/batch/api.js"
104
- },
105
- "./diff": {
106
- "types": "./dist/src/diff.d.ts",
107
- "import": "./src/diff.js"
108
- },
109
- "./link": {
110
- "types": "./dist/src/link.d.ts",
111
- "import": "./src/link.js"
112
- },
113
- "./merge": {
114
- "types": "./dist/src/merge.d.ts",
115
- "import": "./src/merge.js"
116
- },
117
- "./shard": {
118
- "types": "./dist/src/shard.d.ts",
119
- "import": "./src/shard.js"
120
- }
121
- },
122
- "bin": {
123
- "pail": "./cli.js"
124
- },
125
- "scripts": {
126
- "build": "tsc --build",
127
- "test": "mocha test/*.test.js",
128
- "coverage": "c8 -r html -r text npm test",
129
- "lint": "standard"
130
- },
131
- "keywords": [
132
- "bucket",
133
- "KV",
134
- "DAG",
135
- "IPLD",
136
- "CID",
137
- "IPFS"
138
- ],
139
- "author": "Alan Shaw",
140
- "license": "Apache-2.0 OR MIT",
141
- "files": [
142
- "src",
143
- "dist"
144
- ],
145
- "dependencies": {
146
- "@ipld/dag-cbor": "^9.2.0",
147
- "multiformats": "^13.1.0"
148
- },
149
- "devDependencies": {
150
- "archy": "^1.0.0",
151
- "c8": "^8.0.1",
152
- "carstream": "^2.0.0",
153
- "cli-color": "^2.0.3",
154
- "mocha": "^10.2.0",
155
- "nanoid": "^4.0.0",
156
- "sade": "^1.8.1",
157
- "standard": "^17.0.0",
158
- "typescript": "^5.0.2"
159
- },
160
- "repository": {
161
- "type": "git",
162
- "url": "git+https://github.com/web3-storage/pail.git"
163
- },
164
- "bugs": {
165
- "url": "https://github.com/web3-storage/pail/issues"
166
- },
167
- "homepage": "https://github.com/web3-storage/pail#readme",
168
- "standard": {
169
- "ignore": [
170
- "*.ts"
171
- ]
172
- }
173
- }
@@ -1,27 +0,0 @@
1
- const decodeErrPrefix = 'CBOR decode error:'
2
- const encodeErrPrefix = 'CBOR encode error:'
3
-
4
- const uintMinorPrefixBytes = []
5
- uintMinorPrefixBytes[23] = 1
6
- uintMinorPrefixBytes[24] = 2
7
- uintMinorPrefixBytes[25] = 3
8
- uintMinorPrefixBytes[26] = 5
9
- uintMinorPrefixBytes[27] = 9
10
-
11
- /**
12
- * @param {Uint8Array} data
13
- * @param {number} pos
14
- * @param {number} need
15
- */
16
- function assertEnoughData (data, pos, need) {
17
- if (data.length - pos < need) {
18
- throw new Error(`${decodeErrPrefix} not enough data for type`)
19
- }
20
- }
21
-
22
- export {
23
- decodeErrPrefix,
24
- encodeErrPrefix,
25
- uintMinorPrefixBytes,
26
- assertEnoughData
27
- }
@@ -1,209 +0,0 @@
1
- import { Token, Type } from './token.js'
2
- import * as uint from './0uint.js'
3
- import * as negint from './1negint.js'
4
- import * as bytes from './2bytes.js'
5
- import * as string from './3string.js'
6
- import * as array from './4array.js'
7
- import * as map from './5map.js'
8
- import * as tag from './6tag.js'
9
- import * as float from './7float.js'
10
- import { decodeErrPrefix } from './common.js'
11
- import { fromArray } from './byte-utils.js'
12
-
13
- /**
14
- * @typedef {import('../interface').DecodeOptions} DecodeOptions
15
- */
16
-
17
- /**
18
- * @param {Uint8Array} data
19
- * @param {number} pos
20
- * @param {number} minor
21
- */
22
- function invalidMinor (data, pos, minor) {
23
- throw new Error(`${decodeErrPrefix} encountered invalid minor (${minor}) for major ${data[pos] >>> 5}`)
24
- }
25
-
26
- /**
27
- * @param {string} msg
28
- * @returns {()=>any}
29
- */
30
- function errorer (msg) {
31
- return () => { throw new Error(`${decodeErrPrefix} ${msg}`) }
32
- }
33
-
34
- /** @type {((data:Uint8Array, pos:number, minor:number, options?:DecodeOptions) => any)[]} */
35
- export const jump = []
36
-
37
- // unsigned integer, 0x00..0x17 (0..23)
38
- for (let i = 0; i <= 0x17; i++) {
39
- jump[i] = invalidMinor // uint.decodeUintCompact, handled by quick[]
40
- }
41
- jump[0x18] = uint.decodeUint8 // unsigned integer, one-byte uint8_t follows
42
- jump[0x19] = uint.decodeUint16 // unsigned integer, two-byte uint16_t follows
43
- jump[0x1a] = uint.decodeUint32 // unsigned integer, four-byte uint32_t follows
44
- jump[0x1b] = uint.decodeUint64 // unsigned integer, eight-byte uint64_t follows
45
- jump[0x1c] = invalidMinor
46
- jump[0x1d] = invalidMinor
47
- jump[0x1e] = invalidMinor
48
- jump[0x1f] = invalidMinor
49
- // negative integer, -1-0x00..-1-0x17 (-1..-24)
50
- for (let i = 0x20; i <= 0x37; i++) {
51
- jump[i] = invalidMinor // negintDecode, handled by quick[]
52
- }
53
- jump[0x38] = negint.decodeNegint8 // negative integer, -1-n one-byte uint8_t for n follows
54
- jump[0x39] = negint.decodeNegint16 // negative integer, -1-n two-byte uint16_t for n follows
55
- jump[0x3a] = negint.decodeNegint32 // negative integer, -1-n four-byte uint32_t for follows
56
- jump[0x3b] = negint.decodeNegint64 // negative integer, -1-n eight-byte uint64_t for follows
57
- jump[0x3c] = invalidMinor
58
- jump[0x3d] = invalidMinor
59
- jump[0x3e] = invalidMinor
60
- jump[0x3f] = invalidMinor
61
- // byte string, 0x00..0x17 bytes follow
62
- for (let i = 0x40; i <= 0x57; i++) {
63
- jump[i] = bytes.decodeBytesCompact
64
- }
65
- jump[0x58] = bytes.decodeBytes8 // byte string, one-byte uint8_t for n, and then n bytes follow
66
- jump[0x59] = bytes.decodeBytes16 // byte string, two-byte uint16_t for n, and then n bytes follow
67
- jump[0x5a] = bytes.decodeBytes32 // byte string, four-byte uint32_t for n, and then n bytes follow
68
- jump[0x5b] = bytes.decodeBytes64 // byte string, eight-byte uint64_t for n, and then n bytes follow
69
- jump[0x5c] = invalidMinor
70
- jump[0x5d] = invalidMinor
71
- jump[0x5e] = invalidMinor
72
- jump[0x5f] = errorer('indefinite length bytes/strings are not supported') // byte string, byte strings follow, terminated by "break"
73
- // UTF-8 string 0x00..0x17 bytes follow
74
- for (let i = 0x60; i <= 0x77; i++) {
75
- jump[i] = string.decodeStringCompact
76
- }
77
- jump[0x78] = string.decodeString8 // UTF-8 string, one-byte uint8_t for n, and then n bytes follow
78
- jump[0x79] = string.decodeString16 // UTF-8 string, two-byte uint16_t for n, and then n bytes follow
79
- jump[0x7a] = string.decodeString32 // UTF-8 string, four-byte uint32_t for n, and then n bytes follow
80
- jump[0x7b] = string.decodeString64 // UTF-8 string, eight-byte uint64_t for n, and then n bytes follow
81
- jump[0x7c] = invalidMinor
82
- jump[0x7d] = invalidMinor
83
- jump[0x7e] = invalidMinor
84
- jump[0x7f] = errorer('indefinite length bytes/strings are not supported') // UTF-8 strings follow, terminated by "break"
85
- // array, 0x00..0x17 data items follow
86
- for (let i = 0x80; i <= 0x97; i++) {
87
- jump[i] = array.decodeArrayCompact
88
- }
89
- jump[0x98] = array.decodeArray8 // array, one-byte uint8_t for n, and then n data items follow
90
- jump[0x99] = array.decodeArray16 // array, two-byte uint16_t for n, and then n data items follow
91
- jump[0x9a] = array.decodeArray32 // array, four-byte uint32_t for n, and then n data items follow
92
- jump[0x9b] = array.decodeArray64 // array, eight-byte uint64_t for n, and then n data items follow
93
- jump[0x9c] = invalidMinor
94
- jump[0x9d] = invalidMinor
95
- jump[0x9e] = invalidMinor
96
- jump[0x9f] = array.decodeArrayIndefinite // array, data items follow, terminated by "break"
97
- // map, 0x00..0x17 pairs of data items follow
98
- for (let i = 0xa0; i <= 0xb7; i++) {
99
- jump[i] = map.decodeMapCompact
100
- }
101
- jump[0xb8] = map.decodeMap8 // map, one-byte uint8_t for n, and then n pairs of data items follow
102
- jump[0xb9] = map.decodeMap16 // map, two-byte uint16_t for n, and then n pairs of data items follow
103
- jump[0xba] = map.decodeMap32 // map, four-byte uint32_t for n, and then n pairs of data items follow
104
- jump[0xbb] = map.decodeMap64 // map, eight-byte uint64_t for n, and then n pairs of data items follow
105
- jump[0xbc] = invalidMinor
106
- jump[0xbd] = invalidMinor
107
- jump[0xbe] = invalidMinor
108
- jump[0xbf] = map.decodeMapIndefinite // map, pairs of data items follow, terminated by "break"
109
- // tags
110
- for (let i = 0xc0; i <= 0xd7; i++) {
111
- jump[i] = tag.decodeTagCompact
112
- }
113
- jump[0xd8] = tag.decodeTag8
114
- jump[0xd9] = tag.decodeTag16
115
- jump[0xda] = tag.decodeTag32
116
- jump[0xdb] = tag.decodeTag64
117
- jump[0xdc] = invalidMinor
118
- jump[0xdd] = invalidMinor
119
- jump[0xde] = invalidMinor
120
- jump[0xdf] = invalidMinor
121
- // 0xe0..0xf3 simple values, unsupported
122
- for (let i = 0xe0; i <= 0xf3; i++) {
123
- jump[i] = errorer('simple values are not supported')
124
- }
125
- jump[0xf4] = invalidMinor // false, handled by quick[]
126
- jump[0xf5] = invalidMinor // true, handled by quick[]
127
- jump[0xf6] = invalidMinor // null, handled by quick[]
128
- jump[0xf7] = float.decodeUndefined // undefined
129
- jump[0xf8] = errorer('simple values are not supported') // simple value, one byte follows, unsupported
130
- jump[0xf9] = float.decodeFloat16 // half-precision float (two-byte IEEE 754)
131
- jump[0xfa] = float.decodeFloat32 // single-precision float (four-byte IEEE 754)
132
- jump[0xfb] = float.decodeFloat64 // double-precision float (eight-byte IEEE 754)
133
- jump[0xfc] = invalidMinor
134
- jump[0xfd] = invalidMinor
135
- jump[0xfe] = invalidMinor
136
- jump[0xff] = float.decodeBreak // "break" stop code
137
-
138
- /** @type {Token[]} */
139
- export const quick = []
140
- // ints <24
141
- for (let i = 0; i < 24; i++) {
142
- quick[i] = new Token(Type.uint, i, 1)
143
- }
144
- // negints >= -24
145
- for (let i = -1; i >= -24; i--) {
146
- quick[31 - i] = new Token(Type.negint, i, 1)
147
- }
148
- // empty bytes
149
- quick[0x40] = new Token(Type.bytes, new Uint8Array(0), 1)
150
- // empty string
151
- quick[0x60] = new Token(Type.string, '', 1)
152
- // empty list
153
- quick[0x80] = new Token(Type.array, 0, 1)
154
- // empty map
155
- quick[0xa0] = new Token(Type.map, 0, 1)
156
- // false
157
- quick[0xf4] = new Token(Type.false, false, 1)
158
- // true
159
- quick[0xf5] = new Token(Type.true, true, 1)
160
- // null
161
- quick[0xf6] = new Token(Type.null, null, 1)
162
-
163
- /**
164
- * @param {Token} token
165
- * @returns {Uint8Array|undefined}
166
- */
167
- export function quickEncodeToken (token) {
168
- switch (token.type) {
169
- case Type.false:
170
- return fromArray([0xf4])
171
- case Type.true:
172
- return fromArray([0xf5])
173
- case Type.null:
174
- return fromArray([0xf6])
175
- case Type.bytes:
176
- if (!token.value.length) {
177
- return fromArray([0x40])
178
- }
179
- return
180
- case Type.string:
181
- if (token.value === '') {
182
- return fromArray([0x60])
183
- }
184
- return
185
- case Type.array:
186
- if (token.value === 0) {
187
- return fromArray([0x80])
188
- }
189
- /* c8 ignore next 2 */
190
- // shouldn't be possible if this were called when there was only one token
191
- return
192
- case Type.map:
193
- if (token.value === 0) {
194
- return fromArray([0xa0])
195
- }
196
- /* c8 ignore next 2 */
197
- // shouldn't be possible if this were called when there was only one token
198
- return
199
- case Type.uint:
200
- if (token.value < 24) {
201
- return fromArray([Number(token.value)])
202
- }
203
- return
204
- case Type.negint:
205
- if (token.value >= -24) {
206
- return fromArray([31 - Number(token.value)])
207
- }
208
- }
209
- }
@@ -1,168 +0,0 @@
1
- {
2
- "name": "cborg",
3
- "version": "4.2.7",
4
- "description": "Fast CBOR with a focus on strictness",
5
- "main": "cborg.js",
6
- "type": "module",
7
- "bin": {
8
- "cborg": "lib/bin.js"
9
- },
10
- "repository": {
11
- "type": "git",
12
- "url": "git@github.com:rvagg/cborg.git"
13
- },
14
- "keywords": [
15
- "cbor"
16
- ],
17
- "author": "Rod <rod@vagg.org> (http://r.va.gg/)",
18
- "license": "Apache-2.0",
19
- "devDependencies": {
20
- "@semantic-release/changelog": "^6.0.3",
21
- "@semantic-release/commit-analyzer": "^13.0.0",
22
- "@semantic-release/git": "^10.0.1",
23
- "@semantic-release/github": "^11.0.0",
24
- "@semantic-release/npm": "^12.0.1",
25
- "@semantic-release/release-notes-generator": "^14.0.1",
26
- "@types/chai": "^5.0.0",
27
- "@types/mocha": "^10.0.8",
28
- "@types/node": "^22.7.0",
29
- "c8": "^10.1.2",
30
- "chai": "^5.1.1",
31
- "conventional-changelog-conventionalcommits": "^8.0.0",
32
- "ipld-garbage": "^5.0.0",
33
- "mocha": "^11.0.1",
34
- "polendina": "^3.2.2",
35
- "semantic-release": "^24.1.1",
36
- "standard": "^17.1.2",
37
- "typescript": "^5.6.2"
38
- },
39
- "exports": {
40
- ".": {
41
- "import": "./cborg.js",
42
- "types": "./types/cborg.d.ts"
43
- },
44
- "./length": {
45
- "import": "./lib/length.js",
46
- "types": "./types/lib/length.d.ts"
47
- },
48
- "./taglib": {
49
- "import": "./taglib.js",
50
- "types": "./types/taglib.d.ts"
51
- },
52
- "./json": {
53
- "import": "./lib/json/json.js",
54
- "types": "./types/lib/json/json.d.ts"
55
- },
56
- "./interface": {
57
- "types": "./types/interface.d.ts"
58
- }
59
- },
60
- "types": "cborg.d.ts",
61
- "typesVersions": {
62
- "*": {
63
- "json": [
64
- "types/lib/json/json.d.ts"
65
- ],
66
- "length": [
67
- "types/lib/length.d.ts"
68
- ],
69
- "*": [
70
- "types/*"
71
- ],
72
- "types/*": [
73
- "types/*"
74
- ]
75
- }
76
- },
77
- "release": {
78
- "branches": [
79
- "master"
80
- ],
81
- "plugins": [
82
- [
83
- "@semantic-release/commit-analyzer",
84
- {
85
- "preset": "conventionalcommits",
86
- "releaseRules": [
87
- {
88
- "breaking": true,
89
- "release": "major"
90
- },
91
- {
92
- "revert": true,
93
- "release": "patch"
94
- },
95
- {
96
- "type": "feat",
97
- "release": "minor"
98
- },
99
- {
100
- "type": "fix",
101
- "release": "patch"
102
- },
103
- {
104
- "type": "chore",
105
- "release": "patch"
106
- },
107
- {
108
- "type": "docs",
109
- "release": "patch"
110
- },
111
- {
112
- "type": "test",
113
- "release": "patch"
114
- },
115
- {
116
- "scope": "no-release",
117
- "release": false
118
- }
119
- ]
120
- }
121
- ],
122
- [
123
- "@semantic-release/release-notes-generator",
124
- {
125
- "preset": "conventionalcommits",
126
- "presetConfig": {
127
- "types": [
128
- {
129
- "type": "feat",
130
- "section": "Features"
131
- },
132
- {
133
- "type": "fix",
134
- "section": "Bug Fixes"
135
- },
136
- {
137
- "type": "chore",
138
- "section": "Trivial Changes"
139
- },
140
- {
141
- "type": "docs",
142
- "section": "Trivial Changes"
143
- },
144
- {
145
- "type": "test",
146
- "section": "Tests"
147
- }
148
- ]
149
- }
150
- }
151
- ],
152
- "@semantic-release/changelog",
153
- "@semantic-release/npm",
154
- "@semantic-release/github",
155
- "@semantic-release/git"
156
- ]
157
- },
158
- "scripts": {
159
- "lint": "standard *.js lib/*.js test/*.js",
160
- "build": "npm run build:types",
161
- "build:types": "tsc --build",
162
- "test:node": "c8 --check-coverage --exclude=test/** mocha test/test-*.js",
163
- "test:browser": "polendina --cleanup test/test-*.js",
164
- "test": "npm run lint && npm run build && npm run test:node && npm run test:browser",
165
- "test:ci": "npm run test",
166
- "coverage": "c8 --reporter=html --reporter=text mocha test/test-*.js && npx st -d coverage -p 8888"
167
- }
168
- }
@@ -1,28 +0,0 @@
1
- export { encodeCustom } from "./lib/encode.js";
2
- /**
3
- * There was originally just `TypeEncoder` so don't break types by renaming or not exporting
4
- */
5
- export type TagDecoder = import("./interface").TagDecoder;
6
- /**
7
- * Export the types that were present in the original manual cborg.d.ts
8
- */
9
- export type TypeEncoder = import("./interface").OptionalTypeEncoder;
10
- /**
11
- * Export the types that were present in the original manual cborg.d.ts
12
- */
13
- export type DecodeOptions = import("./interface").DecodeOptions;
14
- /**
15
- * Export the types that were present in the original manual cborg.d.ts
16
- */
17
- export type EncodeOptions = import("./interface").EncodeOptions;
18
- import { decode } from './lib/decode.js';
19
- import { decodeFirst } from './lib/decode.js';
20
- import { Tokeniser } from './lib/decode.js';
21
- import { tokensToObject } from './lib/decode.js';
22
- import { encode } from './lib/encode.js';
23
- import { Token } from './lib/token.js';
24
- import { Type } from './lib/token.js';
25
- export { decode, decodeFirst, Tokeniser as Tokenizer, tokensToObject, encode, Token, Type };
26
- export { encodeErrPrefix, decodeErrPrefix } from "./lib/common.js";
27
- export { asU8A, fromString, decodeCodePointsArray } from "./lib/byte-utils.js";
28
- //# sourceMappingURL=cborg.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"cborg.d.ts","sourceRoot":"","sources":["../cborg.js"],"names":[],"mappings":";;;;yBAWa,OAAO,aAAa,EAAE,UAAU;;;;0BAEhC,OAAO,aAAa,EAAE,mBAAmB;;;;4BACzC,OAAO,aAAa,EAAE,aAAa;;;;4BACnC,OAAO,aAAa,EAAE,aAAa;uBAde,iBAAiB;4BAAjB,iBAAiB;0BAAjB,iBAAiB;+BAAjB,iBAAiB;uBADzD,iBAAiB;sBAEZ,gBAAgB;qBAAhB,gBAAgB"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"0uint.d.ts","sourceRoot":"","sources":["../../lib/0uint.js"],"names":[],"mappings":"AAOA;;;GAGG;AAEH;;;;;GAKG;AACH,gCALW,UAAU,UACV,MAAM,WACN,aAAa,GACX,MAAM,CASlB;AAED;;;;;GAKG;AACH,iCALW,UAAU,UACV,MAAM,WACN,aAAa,GACX,MAAM,CASlB;AAED;;;;;GAKG;AACH,iCALW,UAAU,UACV,MAAM,WACN,aAAa,GACX,MAAM,CASlB;AAED;;;;;GAKG;AACH,iCALW,UAAU,UACV,MAAM,WACN,aAAa,GACX,MAAM,GAAC,MAAM,CAkBzB;AASD;;;;;;GAMG;AACH,kCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,mCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,mCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,mCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;GAGG;AACH,gCAHW,EAAE,SACF,KAAK,QAIf;;IAqDD;;;OAGG;IACH,4BAHW,KAAK,GACH,MAAM,CAIlB;IAsBD;;;;OAIG;IACH,6BAJW,KAAK,QACL,KAAK,GACH,MAAM,CAIlB;;AAtFD;;;;GAIG;AACH,qCAJW,EAAE,SACF,MAAM,QACN,MAAM,GAAC,MAAM,QA8CvB;;IAUD;;;OAGG;IACH,2BAHW,MAAM,GACJ,MAAM,CAgBlB;;AApND,iDAA0F;iBAG7E,OAAO,SAAS,EAAE,EAAE;4BACpB,OAAO,cAAc,EAAE,aAAa;sBAPrB,YAAY"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"1negint.d.ts","sourceRoot":"","sources":["../../lib/1negint.js"],"names":[],"mappings":"AAMA;;;GAGG;AAEH;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,qCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,qCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAKD;;;;;;GAMG;AACH,qCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAcjB;AAED;;;GAGG;AACH,kCAHW,EAAE,SACF,KAAK,QAMf;;IAED;;;OAGG;IACH,4BAHW,KAAK,GACH,MAAM,CAoBlB;IAED;;;;OAIG;IACH,6BAJW,KAAK,QACL,KAAK,GACH,MAAM,CAKlB;;iBAvGY,OAAO,SAAS,EAAE,EAAE;4BACpB,OAAO,cAAc,EAAE,aAAa;sBANrB,YAAY"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"2bytes.d.ts","sourceRoot":"","sources":["../../lib/2bytes.js"],"names":[],"mappings":"AAuBA;;;;;;GAMG;AACH,yCANW,UAAU,OACV,MAAM,SACN,MAAM,YACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,mCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAGD;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAQjB;AAgBD;;;GAGG;AACH,iCAHW,EAAE,SACF,KAAK,QAMf;;IAED;;;OAGG;IACH,4BAHW,KAAK,GACH,MAAM,CAKlB;IAED;;;;OAIG;IACH,6BAJW,KAAK,QACL,KAAK,GACH,MAAM,CAIlB;;AAED;;;;GAIG;AACH,iCAJW,UAAU,MACV,UAAU,GACR,MAAM,CAIlB;iBA9HY,OAAO,SAAS,EAAE,EAAE;4BACpB,OAAO,cAAc,EAAE,aAAa;sBAPrB,YAAY"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"3string.d.ts","sourceRoot":"","sources":["../../lib/3string.js"],"names":[],"mappings":"AA6BA;;;;;;GAMG;AACH,0CANW,UAAU,OACV,MAAM,SACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,qCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,qCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAGD;;;;;;GAMG;AACH,qCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAQjB;AAED,8CAAuC;iBAlF1B,OAAO,SAAS,EAAE,EAAE;4BACpB,OAAO,cAAc,EAAE,aAAa;sBARrB,YAAY;4BAGZ,aAAa"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"4array.d.ts","sourceRoot":"","sources":["../../lib/4array.js"],"names":[],"mappings":"AAoBA;;;;;;GAMG;AACH,yCANW,UAAU,OACV,MAAM,SACN,MAAM,YACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,mCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAGD;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAQjB;AAED;;;;;;GAMG;AACH,4CANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAOjB;AAED;;;GAGG;AACH,iCAHW,EAAE,SACF,KAAK,QAIf;;;IAMD;;;OAGG;IACH,4BAHW,KAAK,GACH,MAAM,CAIlB;;iBA3GY,OAAO,SAAS,EAAE,EAAE;4BACpB,OAAO,cAAc,EAAE,aAAa;sBANrB,YAAY"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"5map.d.ts","sourceRoot":"","sources":["../../lib/5map.js"],"names":[],"mappings":"AAoBA;;;;;;GAMG;AACH,uCANW,UAAU,OACV,MAAM,SACN,MAAM,YACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,iCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,kCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,kCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAGD;;;;;;GAMG;AACH,kCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAQjB;AAED;;;;;;GAMG;AACH,0CANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAOjB;AAED;;;GAGG;AACH,+BAHW,EAAE,SACF,KAAK,QAIf;;;IAMD;;;OAGG;IACH,4BAHW,KAAK,GACH,MAAM,CAIlB;;iBA3GY,OAAO,SAAS,EAAE,EAAE;4BACpB,OAAO,cAAc,EAAE,aAAa;sBANrB,YAAY"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"6tag.d.ts","sourceRoot":"","sources":["../../lib/6tag.js"],"names":[],"mappings":"AAGA;;;GAGG;AAEH;;;;;;GAMG;AACH,wCANW,UAAU,QACV,MAAM,SACN,MAAM,YACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,iCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,kCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,kCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,kCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;GAGG;AACH,+BAHW,EAAE,SACF,KAAK,QAIf;;;IAID;;;OAGG;IACH,4BAHW,KAAK,GACH,MAAM,CAIlB;;iBA3EY,OAAO,SAAS,EAAE,EAAE;4BACpB,OAAO,cAAc,EAAE,aAAa;sBALrB,YAAY"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"7float.d.ts","sourceRoot":"","sources":["../../lib/7float.js"],"names":[],"mappings":"AAkBA;;;;;;GAMG;AACH,uCANW,UAAU,QACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CASjB;AAED;;;;;;GAMG;AACH,mCANW,UAAU,QACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAOjB;AAoBD;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;;;GAMG;AACH,oCANW,UAAU,OACV,MAAM,UACN,MAAM,WACN,aAAa,GACX,KAAK,CAIjB;AAED;;;;GAIG;AACH,iCAJW,EAAE,SACF,KAAK,WACL,aAAa,QAwCvB;;IAED;;;;OAIG;IACH,4BAJW,KAAK,WACL,aAAa,GACX,MAAM,CAsBlB;;;iBAjKY,OAAO,SAAS,EAAE,EAAE;4BACpB,OAAO,cAAc,EAAE,aAAa;4BACpC,OAAO,cAAc,EAAE,aAAa;sBAPrB,YAAY"}
@@ -1,4 +0,0 @@
1
- #!/usr/bin/env node
2
- declare const _default: true;
3
- export default _default;
4
- //# sourceMappingURL=bin.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"bin.d.ts","sourceRoot":"","sources":["../../lib/bin.js"],"names":[],"mappings":";wBA4Le,IAAI"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"bl.d.ts","sourceRoot":"","sources":["../../lib/bl.js"],"names":[],"mappings":"AA0BA;IACE;;OAEG;IACH,wBAFW,MAAM,EAahB;IAVC,kBAA0B;IAC1B,qBAAqB;IACrB,QADW,MAAM,CACF;IACf,qBAAqB;IACrB,WADW,MAAM,CACE;IACnB,sCAAsC;IACtC,QADW,CAAC,UAAU,GAAC,MAAM,EAAE,CAAC,EAAE,CAClB;IAEhB,uCAAuC;IACvC,iBADW,UAAU,GAAC,MAAM,EAAE,GAAC,IAAI,CACR;IAG7B,cAUC;IAED;;OAEG;IACH,YAFW,UAAU,GAAC,MAAM,EAAE,QAsC7B;IAED;;;OAGG;IACH,gBAHW,OAAO,GACL,UAAU,CAwBtB;CACF"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"byte-utils.d.ts","sourceRoot":"","sources":["../../lib/byte-utils.js"],"names":[],"mappings":"AAwBA;;;GAGG;AACH,2BAHW,UAAU,GAAC,MAAM,EAAE,GACjB,UAAU,CAQtB;AA8ND;;;;GAIG;AACH,4BAJW,UAAU,MACV,UAAU,GACR,MAAM,CAgBlB;AAyHD;;;GAGG;AACH,kDAHW,MAAM,EAAE,GACN,MAAM,CAkBlB;AA5ZD,gCAMkD;AA4B9C;;;;GAIG;AACH,gCAJW,UAAU,SACV,MAAM,OACN,MAAM,UAQhB;AAcL,mCAGe,MAAM,iDAYN,MAAM,6CAIhB;AAOE,+BAHI,MAAM,EAAE,GACN,UAAU,CAItB;AAIG;;;;GAIG;AACH,6BAJW,UAAU,SACV,MAAM,OACN,MAAM,2BAOhB;AAcD;;;;GAIG;AACH,+BAJW,UAAU,EAAE,UACZ,MAAM,GACJ,UAAU,CActB;AAwBD;;;GAGG;AACH,4BAHW,MAAM,GACJ,UAAU,CAMtB;AAaD;;;GAGG;AACH,yBAHW,UAAU,GACR,MAAM,CAQlB;AAiBH;;;GAGG;AACD,6BAHS,MAAM,GAAC,UAAU,GACf,UAAU,CAQpB"}
@@ -1,10 +0,0 @@
1
- export const decodeErrPrefix: "CBOR decode error:";
2
- export const encodeErrPrefix: "CBOR encode error:";
3
- export const uintMinorPrefixBytes: any[];
4
- /**
5
- * @param {Uint8Array} data
6
- * @param {number} pos
7
- * @param {number} need
8
- */
9
- export function assertEnoughData(data: Uint8Array, pos: number, need: number): void;
10
- //# sourceMappingURL=common.d.ts.map