firefly-compiler 0.4.6 → 0.4.8
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.
- package/compiler/Compiler.ff +2 -0
- package/compiler/Deriver.ff +7 -0
- package/core/Array.ff +17 -4
- package/core/AssetSystem.ff +1 -1
- package/core/BrowserSystem.ff +27 -0
- package/core/List.ff +4 -0
- package/core/Lock.ff +2 -2
- package/core/Random.ff +148 -0
- package/core/SourceLocation.ff +27 -0
- package/core/Task.ff +3 -0
- package/core/WebSocket.ff +127 -0
- package/httpserver/HttpServer.ff +1 -1
- package/lux/Css.ff +648 -0
- package/lux/CssTest.ff +48 -0
- package/lux/Lux.ff +33 -18
- package/lux/Main.ff +4 -1
- package/output/js/ff/compiler/Builder.mjs +448 -444
- package/output/js/ff/compiler/Compiler.mjs +420 -416
- package/output/js/ff/compiler/Dependencies.mjs +393 -389
- package/output/js/ff/compiler/Deriver.mjs +1178 -1170
- package/output/js/ff/compiler/Dictionaries.mjs +1315 -1309
- package/output/js/ff/compiler/Environment.mjs +1025 -1015
- package/output/js/ff/compiler/Inference.mjs +4272 -4268
- package/output/js/ff/compiler/JsEmitter.mjs +5405 -5391
- package/output/js/ff/compiler/JsImporter.mjs +270 -266
- package/output/js/ff/compiler/LspHook.mjs +799 -793
- package/output/js/ff/compiler/Main.mjs +1691 -1675
- package/output/js/ff/compiler/Parser.mjs +4016 -4008
- package/output/js/ff/compiler/Patterns.mjs +935 -927
- package/output/js/ff/compiler/Resolver.mjs +2311 -2307
- package/output/js/ff/compiler/Substitution.mjs +1154 -1150
- package/output/js/ff/compiler/Syntax.mjs +12566 -12434
- package/output/js/ff/compiler/Token.mjs +3152 -3096
- package/output/js/ff/compiler/Tokenizer.mjs +597 -593
- package/output/js/ff/compiler/Unification.mjs +1762 -1752
- package/output/js/ff/compiler/Wildcards.mjs +612 -608
- package/output/js/ff/compiler/Workspace.mjs +695 -687
- package/output/js/ff/core/Any.mjs +147 -143
- package/output/js/ff/core/Array.mjs +573 -547
- package/output/js/ff/core/AssetSystem.mjs +278 -274
- package/output/js/ff/core/Atomic.mjs +158 -154
- package/output/js/ff/core/Bool.mjs +156 -152
- package/output/js/ff/core/Box.mjs +116 -112
- package/output/js/ff/core/BrowserSystem.mjs +181 -126
- package/output/js/ff/core/Buffer.mjs +399 -395
- package/output/js/ff/core/BuildSystem.mjs +300 -296
- package/output/js/ff/core/Channel.mjs +193 -189
- package/output/js/ff/core/Char.mjs +153 -149
- package/output/js/ff/core/Core.mjs +304 -300
- package/output/js/ff/core/Duration.mjs +120 -116
- package/output/js/ff/core/Equal.mjs +183 -179
- package/output/js/ff/core/Error.mjs +146 -142
- package/output/js/ff/core/FileHandle.mjs +154 -150
- package/output/js/ff/core/Float.mjs +229 -225
- package/output/js/ff/core/HttpClient.mjs +195 -191
- package/output/js/ff/core/Instant.mjs +113 -109
- package/output/js/ff/core/Int.mjs +269 -265
- package/output/js/ff/core/IntMap.mjs +284 -280
- package/output/js/ff/core/JsSystem.mjs +242 -238
- package/output/js/ff/core/JsValue.mjs +712 -708
- package/output/js/ff/core/List.mjs +2346 -2334
- package/output/js/ff/core/Lock.mjs +235 -231
- package/output/js/ff/core/Log.mjs +167 -163
- package/output/js/ff/core/Map.mjs +366 -362
- package/output/js/ff/core/NodeSystem.mjs +298 -294
- package/output/js/ff/core/Nothing.mjs +108 -104
- package/output/js/ff/core/Option.mjs +1023 -1015
- package/output/js/ff/core/Ordering.mjs +734 -730
- package/output/js/ff/core/Pair.mjs +337 -331
- package/output/js/ff/core/Path.mjs +549 -545
- package/output/js/ff/core/Random.mjs +340 -0
- package/output/js/ff/core/RbMap.mjs +1944 -1940
- package/output/js/ff/core/Serializable.mjs +432 -428
- package/output/js/ff/core/Set.mjs +258 -254
- package/output/js/ff/core/Show.mjs +209 -205
- package/output/js/ff/core/SourceLocation.mjs +273 -229
- package/output/js/ff/core/Stack.mjs +533 -529
- package/output/js/ff/core/Stream.mjs +1308 -1304
- package/output/js/ff/core/String.mjs +369 -365
- package/output/js/ff/core/StringMap.mjs +284 -280
- package/output/js/ff/core/Task.mjs +325 -319
- package/output/js/ff/core/Try.mjs +511 -507
- package/output/js/ff/core/Unit.mjs +155 -151
- package/output/js/ff/core/WebSocket.mjs +198 -0
- package/package.json +1 -1
- package/vscode/package.json +1 -1
- package/webserver/.firefly/include/package-lock.json +16 -0
- package/webserver/.firefly/include/package.json +5 -0
- package/webserver/.firefly/package.ff +2 -0
- package/webserver/WebServer.ff +608 -0
|
@@ -1,107 +1,111 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
import * as ff_core_Any from "../../ff/core/Any.mjs"
|
|
4
|
-
|
|
5
|
-
import * as ff_core_Array from "../../ff/core/Array.mjs"
|
|
6
|
-
|
|
7
|
-
import * as ff_core_AssetSystem from "../../ff/core/AssetSystem.mjs"
|
|
8
|
-
|
|
9
|
-
import * as ff_core_Atomic from "../../ff/core/Atomic.mjs"
|
|
10
|
-
|
|
11
|
-
import * as ff_core_Bool from "../../ff/core/Bool.mjs"
|
|
12
|
-
|
|
13
|
-
import * as ff_core_Box from "../../ff/core/Box.mjs"
|
|
14
|
-
|
|
15
|
-
import * as ff_core_BrowserSystem from "../../ff/core/BrowserSystem.mjs"
|
|
16
|
-
|
|
17
|
-
import * as ff_core_Buffer from "../../ff/core/Buffer.mjs"
|
|
18
|
-
|
|
19
|
-
import * as ff_core_BuildSystem from "../../ff/core/BuildSystem.mjs"
|
|
20
|
-
|
|
21
|
-
import * as ff_core_Channel from "../../ff/core/Channel.mjs"
|
|
22
|
-
|
|
23
|
-
import * as ff_core_Char from "../../ff/core/Char.mjs"
|
|
24
|
-
|
|
25
|
-
import * as ff_core_Core from "../../ff/core/Core.mjs"
|
|
26
|
-
|
|
27
|
-
import * as ff_core_Duration from "../../ff/core/Duration.mjs"
|
|
28
|
-
|
|
29
|
-
import * as ff_core_Equal from "../../ff/core/Equal.mjs"
|
|
30
|
-
|
|
31
|
-
import * as ff_core_Error from "../../ff/core/Error.mjs"
|
|
32
|
-
|
|
33
|
-
import * as ff_core_FileHandle from "../../ff/core/FileHandle.mjs"
|
|
34
|
-
|
|
35
|
-
import * as ff_core_Float from "../../ff/core/Float.mjs"
|
|
36
|
-
|
|
37
|
-
import * as ff_core_HttpClient from "../../ff/core/HttpClient.mjs"
|
|
38
|
-
|
|
39
|
-
import * as ff_core_Instant from "../../ff/core/Instant.mjs"
|
|
40
|
-
|
|
41
|
-
import * as ff_core_Int from "../../ff/core/Int.mjs"
|
|
42
|
-
|
|
43
|
-
import * as ff_core_IntMap from "../../ff/core/IntMap.mjs"
|
|
44
|
-
|
|
45
|
-
import * as ff_core_JsSystem from "../../ff/core/JsSystem.mjs"
|
|
46
|
-
|
|
47
|
-
import * as ff_core_JsValue from "../../ff/core/JsValue.mjs"
|
|
48
|
-
|
|
49
|
-
import * as ff_core_List from "../../ff/core/List.mjs"
|
|
50
|
-
|
|
51
|
-
import * as ff_core_Lock from "../../ff/core/Lock.mjs"
|
|
52
|
-
|
|
53
|
-
import * as ff_core_Log from "../../ff/core/Log.mjs"
|
|
54
|
-
|
|
55
|
-
import * as ff_core_Map from "../../ff/core/Map.mjs"
|
|
56
|
-
|
|
57
|
-
import * as ff_core_NodeSystem from "../../ff/core/NodeSystem.mjs"
|
|
58
|
-
|
|
59
|
-
import * as ff_core_Nothing from "../../ff/core/Nothing.mjs"
|
|
60
|
-
|
|
61
|
-
import * as ff_core_Option from "../../ff/core/Option.mjs"
|
|
62
|
-
|
|
63
|
-
import * as ff_core_Ordering from "../../ff/core/Ordering.mjs"
|
|
64
|
-
|
|
65
|
-
import * as ff_core_Pair from "../../ff/core/Pair.mjs"
|
|
66
|
-
|
|
67
|
-
import * as ff_core_Path from "../../ff/core/Path.mjs"
|
|
68
|
-
|
|
69
|
-
import * as
|
|
70
|
-
|
|
71
|
-
import * as
|
|
72
|
-
|
|
73
|
-
import * as
|
|
74
|
-
|
|
75
|
-
import * as
|
|
76
|
-
|
|
77
|
-
import * as
|
|
78
|
-
|
|
79
|
-
import * as
|
|
80
|
-
|
|
81
|
-
import * as
|
|
82
|
-
|
|
83
|
-
import * as
|
|
84
|
-
|
|
85
|
-
import * as
|
|
86
|
-
|
|
87
|
-
import * as
|
|
88
|
-
|
|
89
|
-
import * as
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
export function
|
|
101
|
-
return new DataView(new
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
export function
|
|
1
|
+
|
|
2
|
+
|
|
3
|
+
import * as ff_core_Any from "../../ff/core/Any.mjs"
|
|
4
|
+
|
|
5
|
+
import * as ff_core_Array from "../../ff/core/Array.mjs"
|
|
6
|
+
|
|
7
|
+
import * as ff_core_AssetSystem from "../../ff/core/AssetSystem.mjs"
|
|
8
|
+
|
|
9
|
+
import * as ff_core_Atomic from "../../ff/core/Atomic.mjs"
|
|
10
|
+
|
|
11
|
+
import * as ff_core_Bool from "../../ff/core/Bool.mjs"
|
|
12
|
+
|
|
13
|
+
import * as ff_core_Box from "../../ff/core/Box.mjs"
|
|
14
|
+
|
|
15
|
+
import * as ff_core_BrowserSystem from "../../ff/core/BrowserSystem.mjs"
|
|
16
|
+
|
|
17
|
+
import * as ff_core_Buffer from "../../ff/core/Buffer.mjs"
|
|
18
|
+
|
|
19
|
+
import * as ff_core_BuildSystem from "../../ff/core/BuildSystem.mjs"
|
|
20
|
+
|
|
21
|
+
import * as ff_core_Channel from "../../ff/core/Channel.mjs"
|
|
22
|
+
|
|
23
|
+
import * as ff_core_Char from "../../ff/core/Char.mjs"
|
|
24
|
+
|
|
25
|
+
import * as ff_core_Core from "../../ff/core/Core.mjs"
|
|
26
|
+
|
|
27
|
+
import * as ff_core_Duration from "../../ff/core/Duration.mjs"
|
|
28
|
+
|
|
29
|
+
import * as ff_core_Equal from "../../ff/core/Equal.mjs"
|
|
30
|
+
|
|
31
|
+
import * as ff_core_Error from "../../ff/core/Error.mjs"
|
|
32
|
+
|
|
33
|
+
import * as ff_core_FileHandle from "../../ff/core/FileHandle.mjs"
|
|
34
|
+
|
|
35
|
+
import * as ff_core_Float from "../../ff/core/Float.mjs"
|
|
36
|
+
|
|
37
|
+
import * as ff_core_HttpClient from "../../ff/core/HttpClient.mjs"
|
|
38
|
+
|
|
39
|
+
import * as ff_core_Instant from "../../ff/core/Instant.mjs"
|
|
40
|
+
|
|
41
|
+
import * as ff_core_Int from "../../ff/core/Int.mjs"
|
|
42
|
+
|
|
43
|
+
import * as ff_core_IntMap from "../../ff/core/IntMap.mjs"
|
|
44
|
+
|
|
45
|
+
import * as ff_core_JsSystem from "../../ff/core/JsSystem.mjs"
|
|
46
|
+
|
|
47
|
+
import * as ff_core_JsValue from "../../ff/core/JsValue.mjs"
|
|
48
|
+
|
|
49
|
+
import * as ff_core_List from "../../ff/core/List.mjs"
|
|
50
|
+
|
|
51
|
+
import * as ff_core_Lock from "../../ff/core/Lock.mjs"
|
|
52
|
+
|
|
53
|
+
import * as ff_core_Log from "../../ff/core/Log.mjs"
|
|
54
|
+
|
|
55
|
+
import * as ff_core_Map from "../../ff/core/Map.mjs"
|
|
56
|
+
|
|
57
|
+
import * as ff_core_NodeSystem from "../../ff/core/NodeSystem.mjs"
|
|
58
|
+
|
|
59
|
+
import * as ff_core_Nothing from "../../ff/core/Nothing.mjs"
|
|
60
|
+
|
|
61
|
+
import * as ff_core_Option from "../../ff/core/Option.mjs"
|
|
62
|
+
|
|
63
|
+
import * as ff_core_Ordering from "../../ff/core/Ordering.mjs"
|
|
64
|
+
|
|
65
|
+
import * as ff_core_Pair from "../../ff/core/Pair.mjs"
|
|
66
|
+
|
|
67
|
+
import * as ff_core_Path from "../../ff/core/Path.mjs"
|
|
68
|
+
|
|
69
|
+
import * as ff_core_Random from "../../ff/core/Random.mjs"
|
|
70
|
+
|
|
71
|
+
import * as ff_core_Serializable from "../../ff/core/Serializable.mjs"
|
|
72
|
+
|
|
73
|
+
import * as ff_core_Set from "../../ff/core/Set.mjs"
|
|
74
|
+
|
|
75
|
+
import * as ff_core_Show from "../../ff/core/Show.mjs"
|
|
76
|
+
|
|
77
|
+
import * as ff_core_SourceLocation from "../../ff/core/SourceLocation.mjs"
|
|
78
|
+
|
|
79
|
+
import * as ff_core_Stack from "../../ff/core/Stack.mjs"
|
|
80
|
+
|
|
81
|
+
import * as ff_core_Stream from "../../ff/core/Stream.mjs"
|
|
82
|
+
|
|
83
|
+
import * as ff_core_String from "../../ff/core/String.mjs"
|
|
84
|
+
|
|
85
|
+
import * as ff_core_StringMap from "../../ff/core/StringMap.mjs"
|
|
86
|
+
|
|
87
|
+
import * as ff_core_Task from "../../ff/core/Task.mjs"
|
|
88
|
+
|
|
89
|
+
import * as ff_core_Try from "../../ff/core/Try.mjs"
|
|
90
|
+
|
|
91
|
+
import * as ff_core_Unit from "../../ff/core/Unit.mjs"
|
|
92
|
+
|
|
93
|
+
import * as ff_core_WebSocket from "../../ff/core/WebSocket.mjs"
|
|
94
|
+
|
|
95
|
+
// type Buffer
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
export function make_(size_, shared_ = false) {
|
|
101
|
+
return new DataView(shared_ ? new SharedArrayBuffer(size_) : new ArrayBuffer(size_))
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export function fromByteArray_(array_) {
|
|
105
|
+
return new DataView(new Uint8Array(array_).buffer)
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
export function fromBufferArray_(array_) {
|
|
105
109
|
|
|
106
110
|
let length = 0
|
|
107
111
|
for(let b of array_) length += b.byteLength
|
|
@@ -113,326 +117,326 @@ export function fromBufferArray_(array_) {
|
|
|
113
117
|
offset += b.byteLength
|
|
114
118
|
}
|
|
115
119
|
return new DataView(arrayBuffer)
|
|
116
|
-
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
export function fromHex_(hex_) {
|
|
120
|
+
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export function fromHex_(hex_) {
|
|
120
124
|
|
|
121
125
|
const hexValues = hexString.match(/.{1,2}/g) || []
|
|
122
126
|
const numbers = hexValues.map(value => parseInt(value, 16))
|
|
123
127
|
return new DataView(new Uint8Array(numbers).buffer)
|
|
124
|
-
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
export function fromBase64_(base64_) {
|
|
128
|
+
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
export function fromBase64_(base64_) {
|
|
128
132
|
|
|
129
133
|
const binaryString = atob(base64_)
|
|
130
134
|
const dataView = new DataView(new ArrayBuffer(binaryString.length))
|
|
131
135
|
dataView.setUint8(binaryString.split('').map(char => char.charCodeAt(0)))
|
|
132
136
|
return dataView
|
|
133
|
-
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
export async function make_$(size_, shared_ = false, $task) {
|
|
137
|
-
throw new Error('Function make is missing on this target in async context.');
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
export async function fromByteArray_$(array_, $task) {
|
|
141
|
-
throw new Error('Function fromByteArray is missing on this target in async context.');
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
export async function fromBufferArray_$(array_, $task) {
|
|
145
|
-
throw new Error('Function fromBufferArray is missing on this target in async context.');
|
|
146
|
-
}
|
|
147
|
-
|
|
148
|
-
export async function fromHex_$(hex_, $task) {
|
|
149
|
-
throw new Error('Function fromHex is missing on this target in async context.');
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
export async function fromBase64_$(base64_, $task) {
|
|
153
|
-
throw new Error('Function fromBase64 is missing on this target in async context.');
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
export function Buffer_grabUint64(self_, byteOffset_, littleEndian_ = true) {
|
|
137
|
+
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
export async function make_$(size_, shared_ = false, $task) {
|
|
141
|
+
throw new Error('Function make is missing on this target in async context.');
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
export async function fromByteArray_$(array_, $task) {
|
|
145
|
+
throw new Error('Function fromByteArray is missing on this target in async context.');
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
export async function fromBufferArray_$(array_, $task) {
|
|
149
|
+
throw new Error('Function fromBufferArray is missing on this target in async context.');
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
export async function fromHex_$(hex_, $task) {
|
|
153
|
+
throw new Error('Function fromHex is missing on this target in async context.');
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
export async function fromBase64_$(base64_, $task) {
|
|
157
|
+
throw new Error('Function fromBase64 is missing on this target in async context.');
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export function Buffer_grabUint64(self_, byteOffset_, littleEndian_ = true) {
|
|
157
161
|
|
|
158
162
|
const high = self_.getUint32(byteOffset_ + (littleEndian_ ? 4 : 0), littleEndian_)
|
|
159
163
|
const low = self_.getUint32(byteOffset_ + (littleEndian_ ? 0 : 4), littleEndian_)
|
|
160
164
|
const result = (high * 0x100000000) + low
|
|
161
165
|
if(!Number.isSafeInteger(result)) throw 'grabUint64 out of range (consider grabBigUint64)'
|
|
162
166
|
return result
|
|
163
|
-
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
export function Buffer_grabInt64(self_, byteOffset_, littleEndian_ = true) {
|
|
167
|
+
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
export function Buffer_grabInt64(self_, byteOffset_, littleEndian_ = true) {
|
|
167
171
|
|
|
168
172
|
const high = self_.getInt32(byteOffset_ + (littleEndian_ ? 4 : 0), littleEndian_)
|
|
169
173
|
const low = self_.getUint32(byteOffset_ + (littleEndian_ ? 0 : 4), littleEndian_)
|
|
170
174
|
const result = (high * 0x100000000) + low
|
|
171
175
|
if(!Number.isSafeInteger(result)) throw 'grabInt64 out of range (consider grabBigInt64)'
|
|
172
176
|
return result
|
|
173
|
-
|
|
174
|
-
}
|
|
175
|
-
|
|
176
|
-
export function Buffer_grabFloat32(self_, byteOffset_, littleEndian_ = true) {
|
|
177
|
-
return self_.getFloat32(byteOffset_, littleEndian_)
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
export function Buffer_grabFloat64(self_, byteOffset_, littleEndian_ = true) {
|
|
181
|
-
return self_.getFloat64(byteOffset_, littleEndian_)
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
export function Buffer_grabInt16(self_, byteOffset_, littleEndian_ = true) {
|
|
185
|
-
return self_.getInt16(byteOffset_, littleEndian_)
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
export function Buffer_grabInt32(self_, byteOffset_, littleEndian_ = true) {
|
|
189
|
-
return self_.getInt32(byteOffset_, littleEndian_)
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
export function Buffer_grabInt8(self_, byteOffset_) {
|
|
193
|
-
return self_.getInt8(byteOffset_)
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
export function Buffer_grabUint16(self_, byteOffset_, littleEndian_ = true) {
|
|
197
|
-
return self_.getUint16(byteOffset_, littleEndian_)
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
export function Buffer_grabUint32(self_, byteOffset_, littleEndian_ = true) {
|
|
201
|
-
return self_.getUint32(byteOffset_, littleEndian_)
|
|
202
|
-
}
|
|
203
|
-
|
|
204
|
-
export function Buffer_grabUint8(self_, byteOffset_) {
|
|
205
|
-
return self_.getUint8(byteOffset_)
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
export function Buffer_setUint64(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
177
|
+
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
export function Buffer_grabFloat32(self_, byteOffset_, littleEndian_ = true) {
|
|
181
|
+
return self_.getFloat32(byteOffset_, littleEndian_)
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
export function Buffer_grabFloat64(self_, byteOffset_, littleEndian_ = true) {
|
|
185
|
+
return self_.getFloat64(byteOffset_, littleEndian_)
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
export function Buffer_grabInt16(self_, byteOffset_, littleEndian_ = true) {
|
|
189
|
+
return self_.getInt16(byteOffset_, littleEndian_)
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
export function Buffer_grabInt32(self_, byteOffset_, littleEndian_ = true) {
|
|
193
|
+
return self_.getInt32(byteOffset_, littleEndian_)
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
export function Buffer_grabInt8(self_, byteOffset_) {
|
|
197
|
+
return self_.getInt8(byteOffset_)
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
export function Buffer_grabUint16(self_, byteOffset_, littleEndian_ = true) {
|
|
201
|
+
return self_.getUint16(byteOffset_, littleEndian_)
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
export function Buffer_grabUint32(self_, byteOffset_, littleEndian_ = true) {
|
|
205
|
+
return self_.getUint32(byteOffset_, littleEndian_)
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
export function Buffer_grabUint8(self_, byteOffset_) {
|
|
209
|
+
return self_.getUint8(byteOffset_)
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
export function Buffer_setUint64(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
209
213
|
|
|
210
214
|
self_.setUint32(byteOffset_ + (littleEndian_ ? 4 : 0), (value_ >>> 16) >>> 16, littleEndian_)
|
|
211
215
|
self_.setUint32(byteOffset_ + (littleEndian_ ? 0 : 4), value_ & 0xffffffff, littleEndian_)
|
|
212
|
-
|
|
213
|
-
}
|
|
214
|
-
|
|
215
|
-
export function Buffer_setInt64(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
216
|
+
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
export function Buffer_setInt64(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
216
220
|
|
|
217
221
|
self_.setUint32(byteOffset_ + (littleEndian_ ? 4 : 0), (value_ >> 16) >> 16, littleEndian_)
|
|
218
222
|
self_.setUint32(byteOffset_ + (littleEndian_ ? 0 : 4), value_ & 0xffffffff, littleEndian_)
|
|
219
|
-
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
export function Buffer_setFloat32(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
223
|
-
self_.setFloat32(byteOffset_, value_, littleEndian_)
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
export function Buffer_setFloat64(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
227
|
-
self_.setFloat64(byteOffset_, value_, littleEndian_)
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
export function Buffer_setInt16(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
231
|
-
self_.setInt16(byteOffset_, value_, littleEndian_)
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
export function Buffer_setInt32(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
235
|
-
self_.setInt32(byteOffset_, value_, littleEndian_)
|
|
236
|
-
}
|
|
237
|
-
|
|
238
|
-
export function Buffer_setInt8(self_, byteOffset_, value_) {
|
|
239
|
-
self_.setInt8(byteOffset_, value_)
|
|
240
|
-
}
|
|
241
|
-
|
|
242
|
-
export function Buffer_setUint16(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
243
|
-
self_.setUint16(byteOffset_, value_, littleEndian_)
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
export function Buffer_setUint32(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
247
|
-
self_.setUint32(byteOffset_, value_, littleEndian_)
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
export function Buffer_setUint8(self_, byteOffset_, value_) {
|
|
251
|
-
self_.setUint8(byteOffset_, value_)
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
export function Buffer_setAll(self_, byteOffset_, buffer_) {
|
|
223
|
+
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
export function Buffer_setFloat32(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
227
|
+
self_.setFloat32(byteOffset_, value_, littleEndian_)
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
export function Buffer_setFloat64(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
231
|
+
self_.setFloat64(byteOffset_, value_, littleEndian_)
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
export function Buffer_setInt16(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
235
|
+
self_.setInt16(byteOffset_, value_, littleEndian_)
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
export function Buffer_setInt32(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
239
|
+
self_.setInt32(byteOffset_, value_, littleEndian_)
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
export function Buffer_setInt8(self_, byteOffset_, value_) {
|
|
243
|
+
self_.setInt8(byteOffset_, value_)
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
export function Buffer_setUint16(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
247
|
+
self_.setUint16(byteOffset_, value_, littleEndian_)
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
export function Buffer_setUint32(self_, byteOffset_, value_, littleEndian_ = true) {
|
|
251
|
+
self_.setUint32(byteOffset_, value_, littleEndian_)
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
export function Buffer_setUint8(self_, byteOffset_, value_) {
|
|
255
|
+
self_.setUint8(byteOffset_, value_)
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
export function Buffer_setAll(self_, byteOffset_, buffer_) {
|
|
255
259
|
|
|
256
260
|
const sourceBuffer = new Uint8Array(buffer_.buffer, buffer_.byteOffset, buffer_.byteLength)
|
|
257
261
|
const targetBuffer = new Uint8Array(self_.buffer, self_.byteOffset, self_.byteLength)
|
|
258
262
|
targetBuffer.set(sourceBuffer, byteOffset_)
|
|
259
|
-
|
|
260
|
-
}
|
|
261
|
-
|
|
262
|
-
export function Buffer_size(self_) {
|
|
263
|
-
return self_.byteLength
|
|
264
|
-
}
|
|
265
|
-
|
|
266
|
-
export function Buffer_shared(self_) {
|
|
267
|
-
return typeof SharedArrayBuffer !== 'undefined' && self_.buffer instanceof SharedArrayBuffer
|
|
268
|
-
}
|
|
269
|
-
|
|
270
|
-
export function Buffer_view(self_, begin_, end_) {
|
|
271
|
-
return new DataView(self_.buffer, self_.byteOffset + begin_, end_ - begin_)
|
|
272
|
-
}
|
|
273
|
-
|
|
274
|
-
export function Buffer_copy(self_) {
|
|
275
|
-
return new DataView(self_.buffer.slice(self_.byteOffset, self_.byteOffset + self_.byteLength))
|
|
276
|
-
}
|
|
277
|
-
|
|
278
|
-
export function Buffer_toString(self_, encoding_ = "utf8") {
|
|
263
|
+
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
export function Buffer_size(self_) {
|
|
267
|
+
return self_.byteLength
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
export function Buffer_shared(self_) {
|
|
271
|
+
return typeof SharedArrayBuffer !== 'undefined' && self_.buffer instanceof SharedArrayBuffer
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
export function Buffer_view(self_, begin_, end_) {
|
|
275
|
+
return new DataView(self_.buffer, self_.byteOffset + begin_, end_ - begin_)
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
export function Buffer_copy(self_) {
|
|
279
|
+
return new DataView(self_.buffer.slice(self_.byteOffset, self_.byteOffset + self_.byteLength))
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
export function Buffer_toString(self_, encoding_ = "utf8") {
|
|
279
283
|
|
|
280
284
|
if(encoding_ === "utf8") {
|
|
281
285
|
if(typeof TextDecoder.ffSingleton === 'undefined') TextDecoder.ffSingleton = new TextDecoder()
|
|
282
286
|
return TextDecoder.ffSingleton.decode(self_)
|
|
283
287
|
}
|
|
284
288
|
return new TextDecoder().decode(self_)
|
|
285
|
-
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
export function Buffer_toByteArray(self_) {
|
|
289
|
-
return [...new Uint8Array(self_.buffer, self_.byteOffset, self_.byteLength)]
|
|
290
|
-
}
|
|
291
|
-
|
|
292
|
-
export function Buffer_toHex(self_) {
|
|
289
|
+
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
export function Buffer_toByteArray(self_) {
|
|
293
|
+
return [...new Uint8Array(self_.buffer, self_.byteOffset, self_.byteLength)]
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
export function Buffer_toHex(self_) {
|
|
293
297
|
|
|
294
298
|
let hex = ''
|
|
295
299
|
for (let i = 0; i < self_.byteLength; i++) {
|
|
296
300
|
hex += self_.getUint8(i).toString(16).padStart(2, '0')
|
|
297
301
|
}
|
|
298
302
|
return hex
|
|
299
|
-
|
|
300
|
-
}
|
|
301
|
-
|
|
302
|
-
export function Buffer_toBase64(self_) {
|
|
303
|
+
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
export function Buffer_toBase64(self_) {
|
|
303
307
|
|
|
304
308
|
const view = new Uint8Array(self_.buffer, self_.byteOffset, self_.byteLength);
|
|
305
309
|
return btoa(String.fromCharCode(...view));
|
|
306
|
-
|
|
307
|
-
}
|
|
308
|
-
|
|
309
|
-
export async function Buffer_grabUint64$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
310
|
-
throw new Error('Function Buffer_grabUint64 is missing on this target in async context.');
|
|
311
|
-
}
|
|
312
|
-
|
|
313
|
-
export async function Buffer_grabInt64$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
314
|
-
throw new Error('Function Buffer_grabInt64 is missing on this target in async context.');
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
export async function Buffer_grabFloat32$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
318
|
-
throw new Error('Function Buffer_grabFloat32 is missing on this target in async context.');
|
|
319
|
-
}
|
|
320
|
-
|
|
321
|
-
export async function Buffer_grabFloat64$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
322
|
-
throw new Error('Function Buffer_grabFloat64 is missing on this target in async context.');
|
|
323
|
-
}
|
|
324
|
-
|
|
325
|
-
export async function Buffer_grabInt16$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
326
|
-
throw new Error('Function Buffer_grabInt16 is missing on this target in async context.');
|
|
327
|
-
}
|
|
328
|
-
|
|
329
|
-
export async function Buffer_grabInt32$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
330
|
-
throw new Error('Function Buffer_grabInt32 is missing on this target in async context.');
|
|
331
|
-
}
|
|
332
|
-
|
|
333
|
-
export async function Buffer_grabInt8$(self_, byteOffset_, $task) {
|
|
334
|
-
throw new Error('Function Buffer_grabInt8 is missing on this target in async context.');
|
|
335
|
-
}
|
|
336
|
-
|
|
337
|
-
export async function Buffer_grabUint16$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
338
|
-
throw new Error('Function Buffer_grabUint16 is missing on this target in async context.');
|
|
339
|
-
}
|
|
340
|
-
|
|
341
|
-
export async function Buffer_grabUint32$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
342
|
-
throw new Error('Function Buffer_grabUint32 is missing on this target in async context.');
|
|
343
|
-
}
|
|
344
|
-
|
|
345
|
-
export async function Buffer_grabUint8$(self_, byteOffset_, $task) {
|
|
346
|
-
throw new Error('Function Buffer_grabUint8 is missing on this target in async context.');
|
|
347
|
-
}
|
|
348
|
-
|
|
349
|
-
export async function Buffer_setUint64$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
350
|
-
throw new Error('Function Buffer_setUint64 is missing on this target in async context.');
|
|
351
|
-
}
|
|
352
|
-
|
|
353
|
-
export async function Buffer_setInt64$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
354
|
-
throw new Error('Function Buffer_setInt64 is missing on this target in async context.');
|
|
355
|
-
}
|
|
356
|
-
|
|
357
|
-
export async function Buffer_setFloat32$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
358
|
-
throw new Error('Function Buffer_setFloat32 is missing on this target in async context.');
|
|
359
|
-
}
|
|
360
|
-
|
|
361
|
-
export async function Buffer_setFloat64$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
362
|
-
throw new Error('Function Buffer_setFloat64 is missing on this target in async context.');
|
|
363
|
-
}
|
|
364
|
-
|
|
365
|
-
export async function Buffer_setInt16$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
366
|
-
throw new Error('Function Buffer_setInt16 is missing on this target in async context.');
|
|
367
|
-
}
|
|
368
|
-
|
|
369
|
-
export async function Buffer_setInt32$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
370
|
-
throw new Error('Function Buffer_setInt32 is missing on this target in async context.');
|
|
371
|
-
}
|
|
372
|
-
|
|
373
|
-
export async function Buffer_setInt8$(self_, byteOffset_, value_, $task) {
|
|
374
|
-
throw new Error('Function Buffer_setInt8 is missing on this target in async context.');
|
|
375
|
-
}
|
|
376
|
-
|
|
377
|
-
export async function Buffer_setUint16$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
378
|
-
throw new Error('Function Buffer_setUint16 is missing on this target in async context.');
|
|
379
|
-
}
|
|
380
|
-
|
|
381
|
-
export async function Buffer_setUint32$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
382
|
-
throw new Error('Function Buffer_setUint32 is missing on this target in async context.');
|
|
383
|
-
}
|
|
384
|
-
|
|
385
|
-
export async function Buffer_setUint8$(self_, byteOffset_, value_, $task) {
|
|
386
|
-
throw new Error('Function Buffer_setUint8 is missing on this target in async context.');
|
|
387
|
-
}
|
|
388
|
-
|
|
389
|
-
export async function Buffer_setAll$(self_, byteOffset_, buffer_, $task) {
|
|
390
|
-
throw new Error('Function Buffer_setAll is missing on this target in async context.');
|
|
391
|
-
}
|
|
392
|
-
|
|
393
|
-
export async function Buffer_size$(self_, $task) {
|
|
394
|
-
throw new Error('Function Buffer_size is missing on this target in async context.');
|
|
395
|
-
}
|
|
396
|
-
|
|
397
|
-
export async function Buffer_shared$(self_, $task) {
|
|
398
|
-
throw new Error('Function Buffer_shared is missing on this target in async context.');
|
|
399
|
-
}
|
|
400
|
-
|
|
401
|
-
export async function Buffer_view$(self_, begin_, end_, $task) {
|
|
402
|
-
throw new Error('Function Buffer_view is missing on this target in async context.');
|
|
403
|
-
}
|
|
404
|
-
|
|
405
|
-
export async function Buffer_copy$(self_, $task) {
|
|
406
|
-
throw new Error('Function Buffer_copy is missing on this target in async context.');
|
|
407
|
-
}
|
|
408
|
-
|
|
409
|
-
export async function Buffer_toString$(self_, encoding_ = "utf8", $task) {
|
|
410
|
-
throw new Error('Function Buffer_toString is missing on this target in async context.');
|
|
411
|
-
}
|
|
412
|
-
|
|
413
|
-
export async function Buffer_toByteArray$(self_, $task) {
|
|
414
|
-
throw new Error('Function Buffer_toByteArray is missing on this target in async context.');
|
|
415
|
-
}
|
|
416
|
-
|
|
417
|
-
export async function Buffer_toHex$(self_, $task) {
|
|
418
|
-
throw new Error('Function Buffer_toHex is missing on this target in async context.');
|
|
419
|
-
}
|
|
420
|
-
|
|
421
|
-
export async function Buffer_toBase64$(self_, $task) {
|
|
422
|
-
throw new Error('Function Buffer_toBase64 is missing on this target in async context.');
|
|
423
|
-
}
|
|
424
|
-
|
|
425
|
-
export const ff_core_Show_Show$ff_core_Buffer_Buffer = {
|
|
426
|
-
show_(value_) {
|
|
427
|
-
return ((`Buffer.fromHex("` + ff_core_Buffer.Buffer_toHex(value_)) + `")`)
|
|
428
|
-
},
|
|
429
|
-
async show_$(value_, $task) {
|
|
430
|
-
return ((`Buffer.fromHex("` + ff_core_Buffer.Buffer_toHex(value_)) + `")`)
|
|
431
|
-
}
|
|
432
|
-
};
|
|
433
|
-
|
|
434
|
-
export const ff_core_Equal_Equal$ff_core_Buffer_Buffer = {
|
|
435
|
-
equals_(x_, y_) {
|
|
310
|
+
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
export async function Buffer_grabUint64$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
314
|
+
throw new Error('Function Buffer_grabUint64 is missing on this target in async context.');
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
export async function Buffer_grabInt64$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
318
|
+
throw new Error('Function Buffer_grabInt64 is missing on this target in async context.');
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
export async function Buffer_grabFloat32$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
322
|
+
throw new Error('Function Buffer_grabFloat32 is missing on this target in async context.');
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
export async function Buffer_grabFloat64$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
326
|
+
throw new Error('Function Buffer_grabFloat64 is missing on this target in async context.');
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
export async function Buffer_grabInt16$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
330
|
+
throw new Error('Function Buffer_grabInt16 is missing on this target in async context.');
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
export async function Buffer_grabInt32$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
334
|
+
throw new Error('Function Buffer_grabInt32 is missing on this target in async context.');
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
export async function Buffer_grabInt8$(self_, byteOffset_, $task) {
|
|
338
|
+
throw new Error('Function Buffer_grabInt8 is missing on this target in async context.');
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
export async function Buffer_grabUint16$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
342
|
+
throw new Error('Function Buffer_grabUint16 is missing on this target in async context.');
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
export async function Buffer_grabUint32$(self_, byteOffset_, littleEndian_ = true, $task) {
|
|
346
|
+
throw new Error('Function Buffer_grabUint32 is missing on this target in async context.');
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
export async function Buffer_grabUint8$(self_, byteOffset_, $task) {
|
|
350
|
+
throw new Error('Function Buffer_grabUint8 is missing on this target in async context.');
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
export async function Buffer_setUint64$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
354
|
+
throw new Error('Function Buffer_setUint64 is missing on this target in async context.');
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
export async function Buffer_setInt64$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
358
|
+
throw new Error('Function Buffer_setInt64 is missing on this target in async context.');
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
export async function Buffer_setFloat32$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
362
|
+
throw new Error('Function Buffer_setFloat32 is missing on this target in async context.');
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
export async function Buffer_setFloat64$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
366
|
+
throw new Error('Function Buffer_setFloat64 is missing on this target in async context.');
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
export async function Buffer_setInt16$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
370
|
+
throw new Error('Function Buffer_setInt16 is missing on this target in async context.');
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
export async function Buffer_setInt32$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
374
|
+
throw new Error('Function Buffer_setInt32 is missing on this target in async context.');
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
export async function Buffer_setInt8$(self_, byteOffset_, value_, $task) {
|
|
378
|
+
throw new Error('Function Buffer_setInt8 is missing on this target in async context.');
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
export async function Buffer_setUint16$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
382
|
+
throw new Error('Function Buffer_setUint16 is missing on this target in async context.');
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
export async function Buffer_setUint32$(self_, byteOffset_, value_, littleEndian_ = true, $task) {
|
|
386
|
+
throw new Error('Function Buffer_setUint32 is missing on this target in async context.');
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
export async function Buffer_setUint8$(self_, byteOffset_, value_, $task) {
|
|
390
|
+
throw new Error('Function Buffer_setUint8 is missing on this target in async context.');
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
export async function Buffer_setAll$(self_, byteOffset_, buffer_, $task) {
|
|
394
|
+
throw new Error('Function Buffer_setAll is missing on this target in async context.');
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
export async function Buffer_size$(self_, $task) {
|
|
398
|
+
throw new Error('Function Buffer_size is missing on this target in async context.');
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
export async function Buffer_shared$(self_, $task) {
|
|
402
|
+
throw new Error('Function Buffer_shared is missing on this target in async context.');
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
export async function Buffer_view$(self_, begin_, end_, $task) {
|
|
406
|
+
throw new Error('Function Buffer_view is missing on this target in async context.');
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
export async function Buffer_copy$(self_, $task) {
|
|
410
|
+
throw new Error('Function Buffer_copy is missing on this target in async context.');
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
export async function Buffer_toString$(self_, encoding_ = "utf8", $task) {
|
|
414
|
+
throw new Error('Function Buffer_toString is missing on this target in async context.');
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
export async function Buffer_toByteArray$(self_, $task) {
|
|
418
|
+
throw new Error('Function Buffer_toByteArray is missing on this target in async context.');
|
|
419
|
+
}
|
|
420
|
+
|
|
421
|
+
export async function Buffer_toHex$(self_, $task) {
|
|
422
|
+
throw new Error('Function Buffer_toHex is missing on this target in async context.');
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
export async function Buffer_toBase64$(self_, $task) {
|
|
426
|
+
throw new Error('Function Buffer_toBase64 is missing on this target in async context.');
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
export const ff_core_Show_Show$ff_core_Buffer_Buffer = {
|
|
430
|
+
show_(value_) {
|
|
431
|
+
return ((`Buffer.fromHex("` + ff_core_Buffer.Buffer_toHex(value_)) + `")`)
|
|
432
|
+
},
|
|
433
|
+
async show_$(value_, $task) {
|
|
434
|
+
return ((`Buffer.fromHex("` + ff_core_Buffer.Buffer_toHex(value_)) + `")`)
|
|
435
|
+
}
|
|
436
|
+
};
|
|
437
|
+
|
|
438
|
+
export const ff_core_Equal_Equal$ff_core_Buffer_Buffer = {
|
|
439
|
+
equals_(x_, y_) {
|
|
436
440
|
|
|
437
441
|
if(x_.buffer.byteLength !== y_.buffer.byteLength) return false
|
|
438
442
|
if(x_.buffer === y_.buffer) return true
|
|
@@ -443,15 +447,15 @@ equals_(x_, y_) {
|
|
|
443
447
|
if(x_.getUint8(i) !== y_.getUint8(i)) return false
|
|
444
448
|
}
|
|
445
449
|
return true
|
|
446
|
-
|
|
447
|
-
},
|
|
448
|
-
async equals_$(x_, y_, $task) {
|
|
449
|
-
throw new Error('Function equals is missing on this target in async context.');
|
|
450
|
-
}
|
|
451
|
-
};
|
|
452
|
-
|
|
453
|
-
export const ff_core_Ordering_Order$ff_core_Buffer_Buffer = {
|
|
454
|
-
compare_(x_, y_) {
|
|
450
|
+
|
|
451
|
+
},
|
|
452
|
+
async equals_$(x_, y_, $task) {
|
|
453
|
+
throw new Error('Function equals is missing on this target in async context.');
|
|
454
|
+
}
|
|
455
|
+
};
|
|
456
|
+
|
|
457
|
+
export const ff_core_Ordering_Order$ff_core_Buffer_Buffer = {
|
|
458
|
+
compare_(x_, y_) {
|
|
455
459
|
|
|
456
460
|
if(x_.buffer === y_.buffer) return ff_core_Ordering.OrderingSame()
|
|
457
461
|
const minLength = Math.min(x_.buffer.byteLength, y_.buffer.byteLength)
|
|
@@ -461,11 +465,11 @@ compare_(x_, y_) {
|
|
|
461
465
|
}
|
|
462
466
|
}
|
|
463
467
|
return ff_core_Ordering.fromInt_(x_.buffer.byteLength - y_.buffer.byteLength)
|
|
464
|
-
|
|
465
|
-
},
|
|
466
|
-
async compare_$(x_, y_, $task) {
|
|
467
|
-
throw new Error('Function compare is missing on this target in async context.');
|
|
468
|
-
}
|
|
469
|
-
};
|
|
470
|
-
|
|
471
|
-
|
|
468
|
+
|
|
469
|
+
},
|
|
470
|
+
async compare_$(x_, y_, $task) {
|
|
471
|
+
throw new Error('Function compare is missing on this target in async context.');
|
|
472
|
+
}
|
|
473
|
+
};
|
|
474
|
+
|
|
475
|
+
|