@flock/wirespec 0.15.3 → 0.15.4
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/arrow-arrow-atomic.mjs +12 -12
- package/arrow-arrow-atomic.mjs.map +1 -1
- package/arrow-arrow-core.mjs +107 -107
- package/arrow-arrow-core.mjs.map +1 -1
- package/clikt-clikt.mjs +3314 -3654
- package/clikt-clikt.mjs.map +1 -1
- package/colormath-root-colormath.mjs +578 -489
- package/colormath-root-colormath.mjs.map +1 -1
- package/kotlin-kotlin-stdlib.mjs +2925 -2897
- package/kotlin-kotlin-stdlib.mjs.map +1 -1
- package/kotlin-openapi-bindings.mjs +5055 -5051
- package/kotlin-openapi-bindings.mjs.map +1 -1
- package/kotlin-rgxgen.mjs +1934 -1929
- package/kotlin-rgxgen.mjs.map +1 -1
- package/kotlinx-io-kotlinx-io-core.mjs +578 -628
- package/kotlinx-io-kotlinx-io-core.mjs.map +1 -1
- package/kotlinx-serialization-kotlinx-serialization-core.mjs +1897 -1875
- package/kotlinx-serialization-kotlinx-serialization-core.mjs.map +1 -1
- package/kotlinx-serialization-kotlinx-serialization-json.mjs +1575 -1574
- package/kotlinx-serialization-kotlinx-serialization-json.mjs.map +1 -1
- package/markdown.mjs +6756 -0
- package/markdown.mjs.map +1 -0
- package/mordant-mordant.mjs +3762 -2059
- package/mordant-mordant.mjs.map +1 -1
- package/package.json +4 -2
- package/wirespec-src-compiler-core.mjs +2464 -2346
- package/wirespec-src-compiler-core.mjs.map +1 -1
- package/wirespec-src-compiler-lib.mjs +488 -482
- package/wirespec-src-compiler-lib.mjs.map +1 -1
- package/wirespec-src-converter-avro.mjs +556 -555
- package/wirespec-src-converter-avro.mjs.map +1 -1
- package/wirespec-src-converter-openapi.mjs +1382 -1314
- package/wirespec-src-converter-openapi.mjs.map +1 -1
- package/wirespec-src-plugin-arguments.mjs +235 -233
- package/wirespec-src-plugin-arguments.mjs.map +1 -1
- package/wirespec-src-plugin-cli.mjs +150 -150
- package/wirespec-src-plugin-cli.mjs.map +1 -1
- package/wirespec-src-plugin-npm.mjs +115 -119
- package/wirespec-src-plugin-npm.mjs.map +1 -1
- package/wirespec-src-tools-generator.mjs +57 -52
- package/wirespec-src-tools-generator.mjs.map +1 -1
- package/clikt-clikt-mordant.mjs +0 -314
- package/clikt-clikt-mordant.mjs.map +0 -1
- package/mordant-mordant-omnibus.mjs +0 -4
- package/mordant-mordant-omnibus.mjs.map +0 -1
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
charArrayOf27f4r3dozbrk1 as charArrayOf,
|
|
7
7
|
protoOf180f3jzyo7rfj as protoOf,
|
|
8
8
|
toString1pkumu07cwy4m as toString,
|
|
9
|
-
|
|
9
|
+
Unit_instanceat14thlj150z as Unit_instance,
|
|
10
10
|
ensureNotNull1e947j3ixpazm as ensureNotNull,
|
|
11
11
|
toLongw1zpgk99d84b as toLong,
|
|
12
12
|
StringBuilder_init_$Create$1ckbfpj83l95o as StringBuilder_init_$Create$,
|
|
@@ -57,7 +57,7 @@ initMetadataForClass(SegmentCopyTracker, 'SegmentCopyTracker');
|
|
|
57
57
|
initMetadataForObject(AlwaysSharedCopyTracker, 'AlwaysSharedCopyTracker', VOID, SegmentCopyTracker);
|
|
58
58
|
function sink$default(path, append, $super) {
|
|
59
59
|
append = append === VOID ? false : append;
|
|
60
|
-
return $super === VOID ? this.
|
|
60
|
+
return $super === VOID ? this.a2i(path, append) : $super.a2i.call(this, path, append);
|
|
61
61
|
}
|
|
62
62
|
initMetadataForInterface(FileSystem, 'FileSystem');
|
|
63
63
|
initMetadataForClass(SystemFileSystemImpl, 'SystemFileSystemImpl', VOID, VOID, [FileSystem]);
|
|
@@ -82,16 +82,16 @@ function get_HEX_DIGIT_CHARS() {
|
|
|
82
82
|
var HEX_DIGIT_CHARS;
|
|
83
83
|
function checkBounds(size, startIndex, endIndex) {
|
|
84
84
|
_init_properties__Util_kt__g8tcl9();
|
|
85
|
-
if (startIndex.
|
|
85
|
+
if (startIndex.j1(new Long(0, 0)) < 0 || endIndex.j1(size) > 0) {
|
|
86
86
|
throw IndexOutOfBoundsException_init_$Create$('startIndex (' + startIndex.toString() + ') and endIndex (' + endIndex.toString() + ') are not within the range [0..size(' + size.toString() + '))');
|
|
87
87
|
}
|
|
88
|
-
if (startIndex.
|
|
88
|
+
if (startIndex.j1(endIndex) > 0) {
|
|
89
89
|
throw IllegalArgumentException_init_$Create$('startIndex (' + startIndex.toString() + ') > endIndex (' + endIndex.toString() + ')');
|
|
90
90
|
}
|
|
91
91
|
}
|
|
92
92
|
function checkOffsetAndCount(size, offset, byteCount) {
|
|
93
93
|
_init_properties__Util_kt__g8tcl9();
|
|
94
|
-
if (offset.
|
|
94
|
+
if (offset.j1(new Long(0, 0)) < 0 || offset.j1(size) > 0 || size.a3(offset).j1(byteCount) < 0 || byteCount.j1(new Long(0, 0)) < 0) {
|
|
95
95
|
throw IllegalArgumentException_init_$Create$('offset (' + offset.toString() + ') and byteCount (' + byteCount.toString() + ') are not within the range [0..size(' + size.toString() + '))');
|
|
96
96
|
}
|
|
97
97
|
}
|
|
@@ -104,69 +104,69 @@ function _init_properties__Util_kt__g8tcl9() {
|
|
|
104
104
|
}
|
|
105
105
|
}
|
|
106
106
|
function Buffer() {
|
|
107
|
-
this.
|
|
108
|
-
this.
|
|
109
|
-
this.
|
|
107
|
+
this.p2f_1 = null;
|
|
108
|
+
this.q2f_1 = null;
|
|
109
|
+
this.r2f_1 = new Long(0, 0);
|
|
110
110
|
}
|
|
111
111
|
protoOf(Buffer).j = function () {
|
|
112
|
-
return this.
|
|
112
|
+
return this.r2f_1;
|
|
113
113
|
};
|
|
114
|
-
protoOf(Buffer).
|
|
114
|
+
protoOf(Buffer).s2f = function () {
|
|
115
115
|
return this;
|
|
116
116
|
};
|
|
117
|
-
protoOf(Buffer).
|
|
117
|
+
protoOf(Buffer).t2f = function () {
|
|
118
118
|
return this.j().equals(new Long(0, 0));
|
|
119
119
|
};
|
|
120
|
-
protoOf(Buffer).
|
|
120
|
+
protoOf(Buffer).u2f = function (byteCount) {
|
|
121
121
|
// Inline function 'kotlin.require' call
|
|
122
|
-
|
|
122
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
123
|
+
if (!(byteCount.j1(new Long(0, 0)) >= 0)) {
|
|
123
124
|
// Inline function 'kotlinx.io.Buffer.require.<anonymous>' call
|
|
124
125
|
var message = 'byteCount: ' + byteCount.toString();
|
|
125
126
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
126
127
|
}
|
|
127
|
-
if (this.j().
|
|
128
|
+
if (this.j().j1(byteCount) < 0) {
|
|
128
129
|
throw EOFException_init_$Create$_0("Buffer doesn't contain required number of bytes (size: " + this.j().toString() + ', required: ' + byteCount.toString() + ')');
|
|
129
130
|
}
|
|
130
131
|
};
|
|
131
|
-
protoOf(Buffer).
|
|
132
|
+
protoOf(Buffer).v2f = function (byteCount) {
|
|
132
133
|
// Inline function 'kotlin.require' call
|
|
133
|
-
|
|
134
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
135
|
+
if (!(byteCount.j1(new Long(0, 0)) >= 0)) {
|
|
134
136
|
// Inline function 'kotlinx.io.Buffer.request.<anonymous>' call
|
|
135
137
|
var message = 'byteCount: ' + byteCount.toString() + ' < 0';
|
|
136
138
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
137
139
|
}
|
|
138
|
-
return this.j().
|
|
140
|
+
return this.j().j1(byteCount) >= 0;
|
|
139
141
|
};
|
|
140
|
-
protoOf(Buffer).
|
|
142
|
+
protoOf(Buffer).w2f = function () {
|
|
141
143
|
return Unit_instance;
|
|
142
144
|
};
|
|
143
|
-
protoOf(Buffer).
|
|
145
|
+
protoOf(Buffer).q8 = function () {
|
|
144
146
|
return Unit_instance;
|
|
145
147
|
};
|
|
146
|
-
protoOf(Buffer).
|
|
148
|
+
protoOf(Buffer).x2f = function () {
|
|
147
149
|
var result = this.j();
|
|
148
150
|
if (result.equals(new Long(0, 0)))
|
|
149
151
|
return new Long(0, 0);
|
|
150
|
-
var tail = ensureNotNull(this.
|
|
151
|
-
if (tail.
|
|
152
|
-
result = result.
|
|
152
|
+
var tail = ensureNotNull(this.q2f_1);
|
|
153
|
+
if (tail.a2g_1 < 8192 && tail.c2g_1) {
|
|
154
|
+
result = result.a3(toLong(tail.a2g_1 - tail.z2f_1 | 0));
|
|
153
155
|
}
|
|
154
156
|
return result;
|
|
155
157
|
};
|
|
156
|
-
protoOf(Buffer).
|
|
157
|
-
return this.w2h(this.j());
|
|
158
|
-
};
|
|
159
|
-
protoOf(Buffer).w2h = function (byteCount) {
|
|
158
|
+
protoOf(Buffer).f2g = function (byteCount) {
|
|
160
159
|
// Inline function 'kotlinx.io.checkByteCount' call
|
|
161
160
|
// Inline function 'kotlin.require' call
|
|
162
|
-
|
|
161
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
162
|
+
if (!(byteCount.j1(new Long(0, 0)) >= 0)) {
|
|
163
163
|
// Inline function 'kotlinx.io.checkByteCount.<anonymous>' call
|
|
164
164
|
var message = 'byteCount (' + byteCount.toString() + ') < 0';
|
|
165
165
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
166
166
|
}
|
|
167
167
|
var remainingByteCount = byteCount;
|
|
168
|
-
while (remainingByteCount.
|
|
169
|
-
var tmp0_elvis_lhs = this.
|
|
168
|
+
while (remainingByteCount.j1(new Long(0, 0)) > 0) {
|
|
169
|
+
var tmp0_elvis_lhs = this.p2f_1;
|
|
170
170
|
var tmp;
|
|
171
171
|
if (tmp0_elvis_lhs == null) {
|
|
172
172
|
throw EOFException_init_$Create$_0('Buffer exhausted before skipping ' + byteCount.toString() + ' bytes.');
|
|
@@ -174,25 +174,25 @@ protoOf(Buffer).w2h = function (byteCount) {
|
|
|
174
174
|
tmp = tmp0_elvis_lhs;
|
|
175
175
|
}
|
|
176
176
|
var head = tmp;
|
|
177
|
-
var tmp1 = remainingByteCount;
|
|
178
177
|
// Inline function 'kotlinx.io.minOf' call
|
|
179
|
-
var
|
|
178
|
+
var a = remainingByteCount;
|
|
179
|
+
var b = head.a2g_1 - head.z2f_1 | 0;
|
|
180
180
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
181
181
|
var b_0 = toLong(b);
|
|
182
|
-
var toSkip = (
|
|
183
|
-
this.
|
|
184
|
-
remainingByteCount = remainingByteCount.
|
|
185
|
-
head.
|
|
186
|
-
if (head.
|
|
187
|
-
this.
|
|
182
|
+
var toSkip = (a.j1(b_0) <= 0 ? a : b_0).l1();
|
|
183
|
+
this.r2f_1 = this.r2f_1.a3(toLong(toSkip));
|
|
184
|
+
remainingByteCount = remainingByteCount.a3(toLong(toSkip));
|
|
185
|
+
head.z2f_1 = head.z2f_1 + toSkip | 0;
|
|
186
|
+
if (head.z2f_1 === head.a2g_1) {
|
|
187
|
+
this.g2g();
|
|
188
188
|
}
|
|
189
189
|
}
|
|
190
190
|
};
|
|
191
|
-
protoOf(Buffer).
|
|
191
|
+
protoOf(Buffer).h2g = function (sink, startIndex, endIndex) {
|
|
192
192
|
// Inline function 'kotlinx.io.checkBounds' call
|
|
193
193
|
var size = sink.length;
|
|
194
194
|
checkBounds(toLong(size), toLong(startIndex), toLong(endIndex));
|
|
195
|
-
var tmp0_elvis_lhs = this.
|
|
195
|
+
var tmp0_elvis_lhs = this.p2f_1;
|
|
196
196
|
var tmp;
|
|
197
197
|
if (tmp0_elvis_lhs == null) {
|
|
198
198
|
return -1;
|
|
@@ -200,114 +200,114 @@ protoOf(Buffer).y2h = function (sink, startIndex, endIndex) {
|
|
|
200
200
|
tmp = tmp0_elvis_lhs;
|
|
201
201
|
}
|
|
202
202
|
var s = tmp;
|
|
203
|
-
var tmp3 = endIndex - startIndex | 0;
|
|
204
203
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
204
|
+
var a = endIndex - startIndex | 0;
|
|
205
205
|
var b = s.j();
|
|
206
|
-
var toCopy = Math.min(
|
|
207
|
-
s.
|
|
208
|
-
this.
|
|
206
|
+
var toCopy = Math.min(a, b);
|
|
207
|
+
s.i2g(sink, startIndex, startIndex + toCopy | 0);
|
|
208
|
+
this.r2f_1 = this.r2f_1.a3(toLong(toCopy));
|
|
209
209
|
if (isEmpty(s)) {
|
|
210
|
-
this.
|
|
210
|
+
this.g2g();
|
|
211
211
|
}
|
|
212
212
|
return toCopy;
|
|
213
213
|
};
|
|
214
|
-
protoOf(Buffer).
|
|
214
|
+
protoOf(Buffer).j2g = function (sink, byteCount) {
|
|
215
215
|
// Inline function 'kotlinx.io.checkByteCount' call
|
|
216
216
|
// Inline function 'kotlin.require' call
|
|
217
|
-
|
|
217
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
218
|
+
if (!(byteCount.j1(new Long(0, 0)) >= 0)) {
|
|
218
219
|
// Inline function 'kotlinx.io.checkByteCount.<anonymous>' call
|
|
219
220
|
var message = 'byteCount (' + byteCount.toString() + ') < 0';
|
|
220
221
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
221
222
|
}
|
|
222
223
|
if (this.j().equals(new Long(0, 0)))
|
|
223
224
|
return new Long(-1, -1);
|
|
224
|
-
var bytesWritten = byteCount.
|
|
225
|
-
sink.
|
|
225
|
+
var bytesWritten = byteCount.j1(this.j()) > 0 ? this.j() : byteCount;
|
|
226
|
+
sink.k2g(this, bytesWritten);
|
|
226
227
|
return bytesWritten;
|
|
227
228
|
};
|
|
228
|
-
protoOf(Buffer).
|
|
229
|
+
protoOf(Buffer).l2g = function (minimumCapacity) {
|
|
229
230
|
// Inline function 'kotlin.require' call
|
|
231
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
230
232
|
if (!(minimumCapacity >= 1 && minimumCapacity <= 8192)) {
|
|
231
233
|
// Inline function 'kotlinx.io.Buffer.writableSegment.<anonymous>' call
|
|
232
234
|
var message = 'unexpected capacity (' + minimumCapacity + '), should be in range [1, 8192]';
|
|
233
235
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
234
236
|
}
|
|
235
|
-
if (this.
|
|
236
|
-
var result = SegmentPool_instance.
|
|
237
|
-
this.
|
|
238
|
-
this.
|
|
237
|
+
if (this.q2f_1 == null) {
|
|
238
|
+
var result = SegmentPool_instance.o2g();
|
|
239
|
+
this.p2f_1 = result;
|
|
240
|
+
this.q2f_1 = result;
|
|
239
241
|
return result;
|
|
240
242
|
}
|
|
241
|
-
var t = ensureNotNull(this.
|
|
242
|
-
if ((t.
|
|
243
|
-
var newTail = t.
|
|
244
|
-
this.
|
|
243
|
+
var t = ensureNotNull(this.q2f_1);
|
|
244
|
+
if ((t.a2g_1 + minimumCapacity | 0) > 8192 || !t.c2g_1) {
|
|
245
|
+
var newTail = t.p2g(SegmentPool_instance.o2g());
|
|
246
|
+
this.q2f_1 = newTail;
|
|
245
247
|
return newTail;
|
|
246
248
|
}
|
|
247
249
|
return t;
|
|
248
250
|
};
|
|
249
|
-
protoOf(Buffer).
|
|
251
|
+
protoOf(Buffer).k2g = function (source, byteCount) {
|
|
250
252
|
// Inline function 'kotlin.require' call
|
|
253
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
251
254
|
if (!!(source === this)) {
|
|
252
255
|
// Inline function 'kotlinx.io.Buffer.write.<anonymous>' call
|
|
253
256
|
var message = 'source == this';
|
|
254
257
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
255
258
|
}
|
|
256
|
-
checkOffsetAndCount(source.
|
|
259
|
+
checkOffsetAndCount(source.r2f_1, new Long(0, 0), byteCount);
|
|
257
260
|
var remainingByteCount = byteCount;
|
|
258
|
-
while (remainingByteCount.
|
|
259
|
-
if (remainingByteCount.
|
|
260
|
-
var tail = this.
|
|
261
|
+
while (remainingByteCount.j1(new Long(0, 0)) > 0) {
|
|
262
|
+
if (remainingByteCount.j1(toLong(ensureNotNull(source.p2f_1).j())) < 0) {
|
|
263
|
+
var tail = this.q2f_1;
|
|
261
264
|
var tmp;
|
|
262
|
-
if (!(tail == null) && tail.
|
|
263
|
-
var tmp1 = remainingByteCount;
|
|
264
|
-
// Inline function 'kotlin.Long.plus' call
|
|
265
|
-
var other = tail.r2h_1;
|
|
266
|
-
var tmp3 = tmp1.y2(toLong(other));
|
|
265
|
+
if (!(tail == null) && tail.c2g_1) {
|
|
267
266
|
// Inline function 'kotlin.Long.minus' call
|
|
268
|
-
|
|
269
|
-
|
|
267
|
+
// Inline function 'kotlin.Long.plus' call
|
|
268
|
+
var this_0 = remainingByteCount;
|
|
269
|
+
var other = tail.a2g_1;
|
|
270
|
+
var this_1 = this_0.z2(toLong(other));
|
|
271
|
+
var other_0 = tail.q2g() ? 0 : tail.z2f_1;
|
|
272
|
+
tmp = this_1.a3(toLong(other_0)).j1(new Long(8192, 0)) <= 0;
|
|
270
273
|
} else {
|
|
271
274
|
tmp = false;
|
|
272
275
|
}
|
|
273
276
|
if (tmp) {
|
|
274
|
-
ensureNotNull(source.
|
|
275
|
-
source.
|
|
276
|
-
this.
|
|
277
|
+
ensureNotNull(source.p2f_1).s2g(tail, remainingByteCount.l1());
|
|
278
|
+
source.r2f_1 = source.r2f_1.a3(remainingByteCount);
|
|
279
|
+
this.r2f_1 = this.r2f_1.z2(remainingByteCount);
|
|
277
280
|
return Unit_instance;
|
|
278
281
|
} else {
|
|
279
|
-
source.
|
|
282
|
+
source.p2f_1 = ensureNotNull(source.p2f_1).r2g(remainingByteCount.l1());
|
|
280
283
|
}
|
|
281
284
|
}
|
|
282
|
-
var segmentToMove = ensureNotNull(source.
|
|
285
|
+
var segmentToMove = ensureNotNull(source.p2f_1);
|
|
283
286
|
var movedByteCount = toLong(segmentToMove.j());
|
|
284
|
-
source.
|
|
285
|
-
if (source.
|
|
286
|
-
source.
|
|
287
|
+
source.p2f_1 = segmentToMove.t2g();
|
|
288
|
+
if (source.p2f_1 == null) {
|
|
289
|
+
source.q2f_1 = null;
|
|
287
290
|
}
|
|
288
291
|
// Inline function 'kotlinx.io.Buffer.pushSegment' call
|
|
289
|
-
if (this.
|
|
290
|
-
this.
|
|
291
|
-
this.
|
|
292
|
+
if (this.p2f_1 == null) {
|
|
293
|
+
this.p2f_1 = segmentToMove;
|
|
294
|
+
this.q2f_1 = segmentToMove;
|
|
292
295
|
} else if (true) {
|
|
293
|
-
this.
|
|
294
|
-
if (ensureNotNull(this.
|
|
295
|
-
this.
|
|
296
|
+
this.q2f_1 = ensureNotNull(this.q2f_1).p2g(segmentToMove).u2g();
|
|
297
|
+
if (ensureNotNull(this.q2f_1).e2g_1 == null) {
|
|
298
|
+
this.p2f_1 = this.q2f_1;
|
|
296
299
|
}
|
|
297
300
|
} else {
|
|
298
|
-
this.
|
|
301
|
+
this.q2f_1 = ensureNotNull(this.q2f_1).p2g(segmentToMove);
|
|
299
302
|
}
|
|
300
|
-
source.
|
|
301
|
-
this.
|
|
302
|
-
remainingByteCount = remainingByteCount.
|
|
303
|
+
source.r2f_1 = source.r2f_1.a3(movedByteCount);
|
|
304
|
+
this.r2f_1 = this.r2f_1.z2(movedByteCount);
|
|
305
|
+
remainingByteCount = remainingByteCount.a3(movedByteCount);
|
|
303
306
|
}
|
|
304
307
|
};
|
|
305
|
-
protoOf(Buffer).
|
|
306
|
-
this.
|
|
307
|
-
this.
|
|
308
|
-
};
|
|
309
|
-
protoOf(Buffer).g4 = function () {
|
|
310
|
-
return Unit_instance;
|
|
308
|
+
protoOf(Buffer).v2g = function (byte) {
|
|
309
|
+
this.l2g(1).w2g(byte);
|
|
310
|
+
this.r2f_1 = this.r2f_1.z2(new Long(1, 0));
|
|
311
311
|
};
|
|
312
312
|
protoOf(Buffer).toString = function () {
|
|
313
313
|
if (this.j().equals(new Long(0, 0)))
|
|
@@ -317,60 +317,60 @@ protoOf(Buffer).toString = function () {
|
|
|
317
317
|
var b = this.j();
|
|
318
318
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
319
319
|
var a = toLong(maxPrintableBytes);
|
|
320
|
-
var len = (a.
|
|
321
|
-
var builder = StringBuilder_init_$Create$(imul(len, 2) + (this.j().
|
|
320
|
+
var len = (a.j1(b) <= 0 ? a : b).l1();
|
|
321
|
+
var builder = StringBuilder_init_$Create$(imul(len, 2) + (this.j().j1(toLong(maxPrintableBytes)) > 0 ? 1 : 0) | 0);
|
|
322
322
|
var bytesWritten = 0;
|
|
323
323
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.forEachSegment' call
|
|
324
|
-
var curr = this.
|
|
324
|
+
var curr = this.p2f_1;
|
|
325
325
|
while (!(curr == null)) {
|
|
326
|
-
var tmp4 = get_SegmentReadContextImpl();
|
|
327
326
|
// Inline function 'kotlinx.io.Buffer.toString.<anonymous>' call
|
|
327
|
+
var ctx = get_SegmentReadContextImpl();
|
|
328
328
|
var segment = curr;
|
|
329
329
|
var idx = 0;
|
|
330
330
|
while (bytesWritten < len && idx < segment.j()) {
|
|
331
331
|
var _unary__edvuaz = idx;
|
|
332
332
|
idx = _unary__edvuaz + 1 | 0;
|
|
333
|
-
var b_0 =
|
|
333
|
+
var b_0 = ctx.x2g(segment, _unary__edvuaz);
|
|
334
334
|
bytesWritten = bytesWritten + 1 | 0;
|
|
335
335
|
var tmp = get_HEX_DIGIT_CHARS();
|
|
336
336
|
// Inline function 'kotlinx.io.shr' call
|
|
337
337
|
var tmp$ret$2 = b_0 >> 4;
|
|
338
|
-
var tmp_0 = builder.
|
|
338
|
+
var tmp_0 = builder.z7(tmp[tmp$ret$2 & 15]);
|
|
339
339
|
var tmp_1 = get_HEX_DIGIT_CHARS();
|
|
340
340
|
// Inline function 'kotlinx.io.and' call
|
|
341
341
|
var tmp$ret$3 = b_0 & 15;
|
|
342
|
-
tmp_0.
|
|
342
|
+
tmp_0.z7(tmp_1[tmp$ret$3]);
|
|
343
343
|
}
|
|
344
|
-
curr = curr.
|
|
344
|
+
curr = curr.d2g_1;
|
|
345
345
|
}
|
|
346
|
-
if (this.j().
|
|
347
|
-
builder.
|
|
346
|
+
if (this.j().j1(toLong(maxPrintableBytes)) > 0) {
|
|
347
|
+
builder.z7(_Char___init__impl__6a9atx(8230));
|
|
348
348
|
}
|
|
349
349
|
return 'Buffer(size=' + this.j().toString() + ' hex=' + builder.toString() + ')';
|
|
350
350
|
};
|
|
351
|
-
protoOf(Buffer).
|
|
352
|
-
var oldHead = ensureNotNull(this.
|
|
353
|
-
var nextHead = oldHead.
|
|
354
|
-
this.
|
|
351
|
+
protoOf(Buffer).g2g = function () {
|
|
352
|
+
var oldHead = ensureNotNull(this.p2f_1);
|
|
353
|
+
var nextHead = oldHead.d2g_1;
|
|
354
|
+
this.p2f_1 = nextHead;
|
|
355
355
|
if (nextHead == null) {
|
|
356
|
-
this.
|
|
356
|
+
this.q2f_1 = null;
|
|
357
357
|
} else {
|
|
358
|
-
nextHead.
|
|
358
|
+
nextHead.e2g_1 = null;
|
|
359
359
|
}
|
|
360
|
-
oldHead.
|
|
361
|
-
SegmentPool_instance.
|
|
360
|
+
oldHead.d2g_1 = null;
|
|
361
|
+
SegmentPool_instance.y2g(oldHead);
|
|
362
362
|
};
|
|
363
|
-
protoOf(Buffer).
|
|
364
|
-
var oldTail = ensureNotNull(this.
|
|
365
|
-
var newTail = oldTail.
|
|
366
|
-
this.
|
|
363
|
+
protoOf(Buffer).z2g = function () {
|
|
364
|
+
var oldTail = ensureNotNull(this.q2f_1);
|
|
365
|
+
var newTail = oldTail.e2g_1;
|
|
366
|
+
this.q2f_1 = newTail;
|
|
367
367
|
if (newTail == null) {
|
|
368
|
-
this.
|
|
368
|
+
this.p2f_1 = null;
|
|
369
369
|
} else {
|
|
370
|
-
newTail.
|
|
370
|
+
newTail.d2g_1 = null;
|
|
371
371
|
}
|
|
372
|
-
oldTail.
|
|
373
|
-
SegmentPool_instance.
|
|
372
|
+
oldTail.e2g_1 = null;
|
|
373
|
+
SegmentPool_instance.y2g(oldTail);
|
|
374
374
|
};
|
|
375
375
|
function buffered(_this__u8e3s4) {
|
|
376
376
|
return new RealSource(_this__u8e3s4);
|
|
@@ -379,178 +379,148 @@ function buffered_0(_this__u8e3s4) {
|
|
|
379
379
|
return new RealSink(_this__u8e3s4);
|
|
380
380
|
}
|
|
381
381
|
function RealSink(sink) {
|
|
382
|
-
this.
|
|
383
|
-
this.
|
|
384
|
-
this.
|
|
382
|
+
this.a2h_1 = sink;
|
|
383
|
+
this.b2h_1 = false;
|
|
384
|
+
this.c2h_1 = new Buffer();
|
|
385
385
|
}
|
|
386
|
-
protoOf(RealSink).
|
|
387
|
-
return this.
|
|
386
|
+
protoOf(RealSink).s2f = function () {
|
|
387
|
+
return this.c2h_1;
|
|
388
388
|
};
|
|
389
|
-
protoOf(RealSink).
|
|
389
|
+
protoOf(RealSink).k2g = function (source, byteCount) {
|
|
390
390
|
// Inline function 'kotlinx.io.RealSink.checkNotClosed' call
|
|
391
391
|
// Inline function 'kotlin.check' call
|
|
392
|
-
|
|
392
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
393
|
+
if (!!this.b2h_1) {
|
|
393
394
|
// Inline function 'kotlinx.io.RealSink.checkNotClosed.<anonymous>' call
|
|
394
395
|
var message = 'Sink is closed.';
|
|
395
396
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
396
397
|
}
|
|
397
398
|
// Inline function 'kotlin.require' call
|
|
398
|
-
|
|
399
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
400
|
+
if (!(byteCount.j1(new Long(0, 0)) >= 0)) {
|
|
399
401
|
// Inline function 'kotlinx.io.RealSink.write.<anonymous>' call
|
|
400
402
|
var message_0 = 'byteCount: ' + byteCount.toString();
|
|
401
403
|
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
402
404
|
}
|
|
403
|
-
this.
|
|
404
|
-
this.
|
|
405
|
+
this.c2h_1.k2g(source, byteCount);
|
|
406
|
+
this.w2f();
|
|
405
407
|
};
|
|
406
|
-
protoOf(RealSink).
|
|
408
|
+
protoOf(RealSink).w2f = function () {
|
|
407
409
|
// Inline function 'kotlinx.io.RealSink.checkNotClosed' call
|
|
408
410
|
// Inline function 'kotlin.check' call
|
|
409
|
-
|
|
411
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
412
|
+
if (!!this.b2h_1) {
|
|
410
413
|
// Inline function 'kotlinx.io.RealSink.checkNotClosed.<anonymous>' call
|
|
411
414
|
var message = 'Sink is closed.';
|
|
412
415
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
413
416
|
}
|
|
414
|
-
var byteCount = this.
|
|
415
|
-
if (byteCount.
|
|
416
|
-
this.
|
|
417
|
+
var byteCount = this.c2h_1.x2f();
|
|
418
|
+
if (byteCount.j1(new Long(0, 0)) > 0) {
|
|
419
|
+
this.a2h_1.k2g(this.c2h_1, byteCount);
|
|
417
420
|
}
|
|
418
421
|
};
|
|
419
|
-
protoOf(RealSink).
|
|
422
|
+
protoOf(RealSink).q8 = function () {
|
|
420
423
|
// Inline function 'kotlinx.io.RealSink.checkNotClosed' call
|
|
421
424
|
// Inline function 'kotlin.check' call
|
|
422
|
-
|
|
425
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
426
|
+
if (!!this.b2h_1) {
|
|
423
427
|
// Inline function 'kotlinx.io.RealSink.checkNotClosed.<anonymous>' call
|
|
424
428
|
var message = 'Sink is closed.';
|
|
425
429
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
426
430
|
}
|
|
427
|
-
if (this.
|
|
428
|
-
this.
|
|
429
|
-
}
|
|
430
|
-
this.r2i_1.f9();
|
|
431
|
-
};
|
|
432
|
-
protoOf(RealSink).g4 = function () {
|
|
433
|
-
if (this.s2i_1)
|
|
434
|
-
return Unit_instance;
|
|
435
|
-
var thrown = null;
|
|
436
|
-
try {
|
|
437
|
-
if (this.t2i_1.j().d1(new Long(0, 0)) > 0) {
|
|
438
|
-
this.r2i_1.b2i(this.t2i_1, this.t2i_1.j());
|
|
439
|
-
}
|
|
440
|
-
} catch ($p) {
|
|
441
|
-
if ($p instanceof Error) {
|
|
442
|
-
var e = $p;
|
|
443
|
-
thrown = e;
|
|
444
|
-
} else {
|
|
445
|
-
throw $p;
|
|
446
|
-
}
|
|
447
|
-
}
|
|
448
|
-
try {
|
|
449
|
-
this.r2i_1.g4();
|
|
450
|
-
} catch ($p) {
|
|
451
|
-
if ($p instanceof Error) {
|
|
452
|
-
var e_0 = $p;
|
|
453
|
-
if (thrown == null)
|
|
454
|
-
thrown = e_0;
|
|
455
|
-
} else {
|
|
456
|
-
throw $p;
|
|
457
|
-
}
|
|
431
|
+
if (this.c2h_1.j().j1(new Long(0, 0)) > 0) {
|
|
432
|
+
this.a2h_1.k2g(this.c2h_1, this.c2h_1.j());
|
|
458
433
|
}
|
|
459
|
-
this.
|
|
460
|
-
if (!(thrown == null))
|
|
461
|
-
throw thrown;
|
|
434
|
+
this.a2h_1.q8();
|
|
462
435
|
};
|
|
463
436
|
protoOf(RealSink).toString = function () {
|
|
464
|
-
return 'buffered(' + toString(this.
|
|
437
|
+
return 'buffered(' + toString(this.a2h_1) + ')';
|
|
465
438
|
};
|
|
466
439
|
function RealSource(source) {
|
|
467
|
-
this.
|
|
468
|
-
this.
|
|
469
|
-
this.
|
|
440
|
+
this.d2h_1 = source;
|
|
441
|
+
this.e2h_1 = false;
|
|
442
|
+
this.f2h_1 = new Buffer();
|
|
470
443
|
}
|
|
471
|
-
protoOf(RealSource).
|
|
472
|
-
return this.
|
|
444
|
+
protoOf(RealSource).s2f = function () {
|
|
445
|
+
return this.f2h_1;
|
|
473
446
|
};
|
|
474
|
-
protoOf(RealSource).
|
|
447
|
+
protoOf(RealSource).j2g = function (sink, byteCount) {
|
|
475
448
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed' call
|
|
476
449
|
// Inline function 'kotlin.check' call
|
|
477
|
-
|
|
450
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
451
|
+
if (!!this.e2h_1) {
|
|
478
452
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed.<anonymous>' call
|
|
479
453
|
var message = 'Source is closed.';
|
|
480
454
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
481
455
|
}
|
|
482
456
|
// Inline function 'kotlin.require' call
|
|
483
|
-
|
|
457
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
458
|
+
if (!(byteCount.j1(new Long(0, 0)) >= 0)) {
|
|
484
459
|
// Inline function 'kotlinx.io.RealSource.readAtMostTo.<anonymous>' call
|
|
485
460
|
var message_0 = 'byteCount: ' + byteCount.toString();
|
|
486
461
|
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
487
462
|
}
|
|
488
|
-
if (this.
|
|
489
|
-
var read = this.
|
|
463
|
+
if (this.f2h_1.j().equals(new Long(0, 0))) {
|
|
464
|
+
var read = this.d2h_1.j2g(this.f2h_1, new Long(8192, 0));
|
|
490
465
|
if (read.equals(new Long(-1, -1)))
|
|
491
466
|
return new Long(-1, -1);
|
|
492
467
|
}
|
|
493
468
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
494
|
-
var b = this.
|
|
495
|
-
var toRead = byteCount.
|
|
496
|
-
return this.
|
|
469
|
+
var b = this.f2h_1.j();
|
|
470
|
+
var toRead = byteCount.j1(b) <= 0 ? byteCount : b;
|
|
471
|
+
return this.f2h_1.j2g(sink, toRead);
|
|
497
472
|
};
|
|
498
|
-
protoOf(RealSource).
|
|
499
|
-
if (!this.
|
|
473
|
+
protoOf(RealSource).u2f = function (byteCount) {
|
|
474
|
+
if (!this.v2f(byteCount))
|
|
500
475
|
throw EOFException_init_$Create$_0("Source doesn't contain required number of bytes (" + byteCount.toString() + ').');
|
|
501
476
|
};
|
|
502
|
-
protoOf(RealSource).
|
|
477
|
+
protoOf(RealSource).v2f = function (byteCount) {
|
|
503
478
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed' call
|
|
504
479
|
// Inline function 'kotlin.check' call
|
|
505
|
-
|
|
480
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
481
|
+
if (!!this.e2h_1) {
|
|
506
482
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed.<anonymous>' call
|
|
507
483
|
var message = 'Source is closed.';
|
|
508
484
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
509
485
|
}
|
|
510
486
|
// Inline function 'kotlin.require' call
|
|
511
|
-
|
|
487
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
488
|
+
if (!(byteCount.j1(new Long(0, 0)) >= 0)) {
|
|
512
489
|
// Inline function 'kotlinx.io.RealSource.request.<anonymous>' call
|
|
513
490
|
var message_0 = 'byteCount: ' + byteCount.toString();
|
|
514
491
|
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
515
492
|
}
|
|
516
|
-
while (this.
|
|
517
|
-
if (this.
|
|
493
|
+
while (this.f2h_1.j().j1(byteCount) < 0) {
|
|
494
|
+
if (this.d2h_1.j2g(this.f2h_1, new Long(8192, 0)).equals(new Long(-1, -1)))
|
|
518
495
|
return false;
|
|
519
496
|
}
|
|
520
497
|
return true;
|
|
521
498
|
};
|
|
522
|
-
protoOf(RealSource).
|
|
499
|
+
protoOf(RealSource).h2g = function (sink, startIndex, endIndex) {
|
|
523
500
|
// Inline function 'kotlinx.io.checkBounds' call
|
|
524
501
|
var size = sink.length;
|
|
525
502
|
checkBounds(toLong(size), toLong(startIndex), toLong(endIndex));
|
|
526
|
-
if (this.
|
|
527
|
-
var read = this.
|
|
503
|
+
if (this.f2h_1.j().equals(new Long(0, 0))) {
|
|
504
|
+
var read = this.d2h_1.j2g(this.f2h_1, new Long(8192, 0));
|
|
528
505
|
if (read.equals(new Long(-1, -1)))
|
|
529
506
|
return -1;
|
|
530
507
|
}
|
|
531
|
-
var tmp3 = endIndex - startIndex | 0;
|
|
532
508
|
// Inline function 'kotlinx.io.minOf' call
|
|
533
|
-
var
|
|
509
|
+
var a = endIndex - startIndex | 0;
|
|
510
|
+
var b = this.f2h_1.j();
|
|
534
511
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
535
|
-
var
|
|
536
|
-
var toRead = (
|
|
537
|
-
return this.
|
|
538
|
-
};
|
|
539
|
-
protoOf(RealSource).g4 = function () {
|
|
540
|
-
if (this.v2i_1)
|
|
541
|
-
return Unit_instance;
|
|
542
|
-
this.v2i_1 = true;
|
|
543
|
-
this.u2i_1.g4();
|
|
544
|
-
this.w2i_1.h2();
|
|
512
|
+
var a_0 = toLong(a);
|
|
513
|
+
var toRead = (a_0.j1(b) <= 0 ? a_0 : b).l1();
|
|
514
|
+
return this.f2h_1.h2g(sink, startIndex, startIndex + toRead | 0);
|
|
545
515
|
};
|
|
546
516
|
protoOf(RealSource).toString = function () {
|
|
547
|
-
return 'buffered(' + toString(this.
|
|
517
|
+
return 'buffered(' + toString(this.d2h_1) + ')';
|
|
548
518
|
};
|
|
549
519
|
function Segment_init_$Init$($this) {
|
|
550
520
|
Segment.call($this);
|
|
551
|
-
$this.
|
|
552
|
-
$this.
|
|
553
|
-
$this.
|
|
521
|
+
$this.y2f_1 = new Int8Array(8192);
|
|
522
|
+
$this.c2g_1 = true;
|
|
523
|
+
$this.b2g_1 = null;
|
|
554
524
|
return $this;
|
|
555
525
|
}
|
|
556
526
|
function Segment_init_$Create$() {
|
|
@@ -558,233 +528,243 @@ function Segment_init_$Create$() {
|
|
|
558
528
|
}
|
|
559
529
|
function Segment_init_$Init$_0(data, pos, limit, shareToken, owner, $this) {
|
|
560
530
|
Segment.call($this);
|
|
561
|
-
$this.
|
|
562
|
-
$this.
|
|
563
|
-
$this.
|
|
564
|
-
$this.
|
|
565
|
-
$this.
|
|
531
|
+
$this.y2f_1 = data;
|
|
532
|
+
$this.z2f_1 = pos;
|
|
533
|
+
$this.a2g_1 = limit;
|
|
534
|
+
$this.b2g_1 = shareToken;
|
|
535
|
+
$this.c2g_1 = owner;
|
|
566
536
|
return $this;
|
|
567
537
|
}
|
|
568
538
|
function Segment_init_$Create$_0(data, pos, limit, shareToken, owner) {
|
|
569
539
|
return Segment_init_$Init$_0(data, pos, limit, shareToken, owner, objectCreate(protoOf(Segment)));
|
|
570
540
|
}
|
|
571
541
|
function Companion() {
|
|
572
|
-
this.
|
|
573
|
-
this.
|
|
542
|
+
this.g2h_1 = 8192;
|
|
543
|
+
this.h2h_1 = 1024;
|
|
574
544
|
}
|
|
575
|
-
protoOf(Companion).
|
|
545
|
+
protoOf(Companion).i2h = function () {
|
|
576
546
|
return Segment_init_$Create$();
|
|
577
547
|
};
|
|
578
548
|
var Companion_instance;
|
|
579
549
|
function Companion_getInstance() {
|
|
580
550
|
return Companion_instance;
|
|
581
551
|
}
|
|
582
|
-
protoOf(Segment).
|
|
583
|
-
var tmp1_safe_receiver = this.
|
|
584
|
-
var tmp0_elvis_lhs = tmp1_safe_receiver == null ? null : tmp1_safe_receiver.
|
|
552
|
+
protoOf(Segment).q2g = function () {
|
|
553
|
+
var tmp1_safe_receiver = this.b2g_1;
|
|
554
|
+
var tmp0_elvis_lhs = tmp1_safe_receiver == null ? null : tmp1_safe_receiver.z25();
|
|
585
555
|
return tmp0_elvis_lhs == null ? false : tmp0_elvis_lhs;
|
|
586
556
|
};
|
|
587
|
-
protoOf(Segment).
|
|
588
|
-
var tmp0_elvis_lhs = this.
|
|
557
|
+
protoOf(Segment).j2h = function () {
|
|
558
|
+
var tmp0_elvis_lhs = this.b2g_1;
|
|
589
559
|
var tmp;
|
|
590
560
|
if (tmp0_elvis_lhs == null) {
|
|
591
561
|
// Inline function 'kotlin.also' call
|
|
592
|
-
var this_0 = SegmentPool_instance.
|
|
562
|
+
var this_0 = SegmentPool_instance.k2h();
|
|
563
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
593
564
|
// Inline function 'kotlinx.io.Segment.sharedCopy.<anonymous>' call
|
|
594
|
-
this.
|
|
565
|
+
this.b2g_1 = this_0;
|
|
595
566
|
tmp = this_0;
|
|
596
567
|
} else {
|
|
597
568
|
tmp = tmp0_elvis_lhs;
|
|
598
569
|
}
|
|
599
570
|
var t = tmp;
|
|
600
|
-
var tmp_0 = this.
|
|
601
|
-
var tmp_1 = this.
|
|
571
|
+
var tmp_0 = this.z2f_1;
|
|
572
|
+
var tmp_1 = this.a2g_1;
|
|
602
573
|
// Inline function 'kotlin.also' call
|
|
574
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
603
575
|
// Inline function 'kotlinx.io.Segment.sharedCopy.<anonymous>' call
|
|
604
|
-
t.
|
|
605
|
-
return Segment_init_$Create$_0(this.
|
|
576
|
+
t.l2h();
|
|
577
|
+
return Segment_init_$Create$_0(this.y2f_1, tmp_0, tmp_1, t, false);
|
|
606
578
|
};
|
|
607
|
-
protoOf(Segment).
|
|
608
|
-
var result = this.
|
|
609
|
-
if (!(this.
|
|
610
|
-
ensureNotNull(this.
|
|
579
|
+
protoOf(Segment).t2g = function () {
|
|
580
|
+
var result = this.d2g_1;
|
|
581
|
+
if (!(this.e2g_1 == null)) {
|
|
582
|
+
ensureNotNull(this.e2g_1).d2g_1 = this.d2g_1;
|
|
611
583
|
}
|
|
612
|
-
if (!(this.
|
|
613
|
-
ensureNotNull(this.
|
|
584
|
+
if (!(this.d2g_1 == null)) {
|
|
585
|
+
ensureNotNull(this.d2g_1).e2g_1 = this.e2g_1;
|
|
614
586
|
}
|
|
615
|
-
this.
|
|
616
|
-
this.
|
|
587
|
+
this.d2g_1 = null;
|
|
588
|
+
this.e2g_1 = null;
|
|
617
589
|
return result;
|
|
618
590
|
};
|
|
619
|
-
protoOf(Segment).
|
|
620
|
-
segment.
|
|
621
|
-
segment.
|
|
622
|
-
if (!(this.
|
|
623
|
-
ensureNotNull(this.
|
|
591
|
+
protoOf(Segment).p2g = function (segment) {
|
|
592
|
+
segment.e2g_1 = this;
|
|
593
|
+
segment.d2g_1 = this.d2g_1;
|
|
594
|
+
if (!(this.d2g_1 == null)) {
|
|
595
|
+
ensureNotNull(this.d2g_1).e2g_1 = segment;
|
|
624
596
|
}
|
|
625
|
-
this.
|
|
597
|
+
this.d2g_1 = segment;
|
|
626
598
|
return segment;
|
|
627
599
|
};
|
|
628
|
-
protoOf(Segment).
|
|
600
|
+
protoOf(Segment).r2g = function (byteCount) {
|
|
629
601
|
// Inline function 'kotlin.require' call
|
|
630
|
-
|
|
602
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
603
|
+
if (!(byteCount > 0 && byteCount <= (this.a2g_1 - this.z2f_1 | 0))) {
|
|
631
604
|
// Inline function 'kotlinx.io.Segment.split.<anonymous>' call
|
|
632
605
|
var message = 'byteCount out of range';
|
|
633
606
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
634
607
|
}
|
|
635
608
|
var prefix;
|
|
636
609
|
if (byteCount >= 1024) {
|
|
637
|
-
prefix = this.
|
|
610
|
+
prefix = this.j2h();
|
|
638
611
|
} else {
|
|
639
|
-
prefix = SegmentPool_instance.
|
|
640
|
-
var tmp1 = this.p2h_1;
|
|
641
|
-
var tmp2 = prefix.p2h_1;
|
|
642
|
-
var tmp3 = this.q2h_1;
|
|
612
|
+
prefix = SegmentPool_instance.o2g();
|
|
643
613
|
// Inline function 'kotlin.collections.copyInto' call
|
|
644
|
-
var
|
|
614
|
+
var this_0 = this.y2f_1;
|
|
615
|
+
var destination = prefix.y2f_1;
|
|
616
|
+
var startIndex = this.z2f_1;
|
|
617
|
+
var endIndex = this.z2f_1 + byteCount | 0;
|
|
645
618
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
646
619
|
// Inline function 'kotlin.js.asDynamic' call
|
|
647
|
-
var tmp =
|
|
620
|
+
var tmp = this_0;
|
|
648
621
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
649
622
|
// Inline function 'kotlin.js.asDynamic' call
|
|
650
|
-
arrayCopy(tmp,
|
|
623
|
+
arrayCopy(tmp, destination, 0, startIndex, endIndex);
|
|
651
624
|
}
|
|
652
|
-
prefix.
|
|
653
|
-
this.
|
|
654
|
-
if (!(this.
|
|
655
|
-
ensureNotNull(this.
|
|
625
|
+
prefix.a2g_1 = prefix.z2f_1 + byteCount | 0;
|
|
626
|
+
this.z2f_1 = this.z2f_1 + byteCount | 0;
|
|
627
|
+
if (!(this.e2g_1 == null)) {
|
|
628
|
+
ensureNotNull(this.e2g_1).p2g(prefix);
|
|
656
629
|
} else {
|
|
657
|
-
prefix.
|
|
658
|
-
this.
|
|
630
|
+
prefix.d2g_1 = this;
|
|
631
|
+
this.e2g_1 = prefix;
|
|
659
632
|
}
|
|
660
633
|
return prefix;
|
|
661
634
|
};
|
|
662
|
-
protoOf(Segment).
|
|
635
|
+
protoOf(Segment).u2g = function () {
|
|
663
636
|
// Inline function 'kotlin.check' call
|
|
664
|
-
|
|
637
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
638
|
+
if (!!(this.e2g_1 == null)) {
|
|
665
639
|
// Inline function 'kotlinx.io.Segment.compact.<anonymous>' call
|
|
666
640
|
var message = 'cannot compact';
|
|
667
641
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
668
642
|
}
|
|
669
|
-
if (!ensureNotNull(this.
|
|
643
|
+
if (!ensureNotNull(this.e2g_1).c2g_1)
|
|
670
644
|
return this;
|
|
671
|
-
var byteCount = this.
|
|
672
|
-
var availableByteCount = (8192 - ensureNotNull(this.
|
|
645
|
+
var byteCount = this.a2g_1 - this.z2f_1 | 0;
|
|
646
|
+
var availableByteCount = (8192 - ensureNotNull(this.e2g_1).a2g_1 | 0) + (ensureNotNull(this.e2g_1).q2g() ? 0 : ensureNotNull(this.e2g_1).z2f_1) | 0;
|
|
673
647
|
if (byteCount > availableByteCount)
|
|
674
648
|
return this;
|
|
675
|
-
var predecessor = this.
|
|
676
|
-
this.
|
|
677
|
-
var successor = this.
|
|
649
|
+
var predecessor = this.e2g_1;
|
|
650
|
+
this.s2g(ensureNotNull(predecessor), byteCount);
|
|
651
|
+
var successor = this.t2g();
|
|
678
652
|
// Inline function 'kotlin.check' call
|
|
653
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
654
|
+
// Inline function 'kotlin.check' call
|
|
655
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
679
656
|
if (!(successor == null)) {
|
|
680
|
-
|
|
657
|
+
// Inline function 'kotlin.check.<anonymous>' call
|
|
658
|
+
var message_0 = 'Check failed.';
|
|
659
|
+
throw IllegalStateException_init_$Create$(toString(message_0));
|
|
681
660
|
}
|
|
682
|
-
SegmentPool_instance.
|
|
661
|
+
SegmentPool_instance.y2g(this);
|
|
683
662
|
return predecessor;
|
|
684
663
|
};
|
|
685
|
-
protoOf(Segment).
|
|
686
|
-
var _unary__edvuaz = this.
|
|
687
|
-
this.
|
|
688
|
-
this.
|
|
664
|
+
protoOf(Segment).w2g = function (byte) {
|
|
665
|
+
var _unary__edvuaz = this.a2g_1;
|
|
666
|
+
this.a2g_1 = _unary__edvuaz + 1 | 0;
|
|
667
|
+
this.y2f_1[_unary__edvuaz] = byte;
|
|
689
668
|
};
|
|
690
|
-
protoOf(Segment).
|
|
669
|
+
protoOf(Segment).s2g = function (sink, byteCount) {
|
|
691
670
|
// Inline function 'kotlin.check' call
|
|
692
|
-
|
|
671
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
672
|
+
if (!sink.c2g_1) {
|
|
693
673
|
// Inline function 'kotlinx.io.Segment.writeTo.<anonymous>' call
|
|
694
674
|
var message = 'only owner can write';
|
|
695
675
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
696
676
|
}
|
|
697
|
-
if ((sink.
|
|
698
|
-
if (sink.
|
|
677
|
+
if ((sink.a2g_1 + byteCount | 0) > 8192) {
|
|
678
|
+
if (sink.q2g())
|
|
699
679
|
throw IllegalArgumentException_init_$Create$_0();
|
|
700
|
-
if (((sink.
|
|
680
|
+
if (((sink.a2g_1 + byteCount | 0) - sink.z2f_1 | 0) > 8192)
|
|
701
681
|
throw IllegalArgumentException_init_$Create$_0();
|
|
702
|
-
var tmp1 = sink.p2h_1;
|
|
703
|
-
var tmp2 = sink.p2h_1;
|
|
704
|
-
var tmp3 = sink.q2h_1;
|
|
705
682
|
// Inline function 'kotlin.collections.copyInto' call
|
|
706
|
-
var
|
|
683
|
+
var this_0 = sink.y2f_1;
|
|
684
|
+
var destination = sink.y2f_1;
|
|
685
|
+
var startIndex = sink.z2f_1;
|
|
686
|
+
var endIndex = sink.a2g_1;
|
|
707
687
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
708
688
|
// Inline function 'kotlin.js.asDynamic' call
|
|
709
|
-
var tmp =
|
|
689
|
+
var tmp = this_0;
|
|
710
690
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
711
691
|
// Inline function 'kotlin.js.asDynamic' call
|
|
712
|
-
arrayCopy(tmp,
|
|
713
|
-
sink.
|
|
714
|
-
sink.
|
|
715
|
-
}
|
|
716
|
-
var tmp6 = this.p2h_1;
|
|
717
|
-
var tmp7 = sink.p2h_1;
|
|
718
|
-
var tmp8 = sink.r2h_1;
|
|
719
|
-
var tmp9 = this.q2h_1;
|
|
692
|
+
arrayCopy(tmp, destination, 0, startIndex, endIndex);
|
|
693
|
+
sink.a2g_1 = sink.a2g_1 - sink.z2f_1 | 0;
|
|
694
|
+
sink.z2f_1 = 0;
|
|
695
|
+
}
|
|
720
696
|
// Inline function 'kotlin.collections.copyInto' call
|
|
721
|
-
var
|
|
697
|
+
var this_1 = this.y2f_1;
|
|
698
|
+
var destination_0 = sink.y2f_1;
|
|
699
|
+
var destinationOffset = sink.a2g_1;
|
|
700
|
+
var startIndex_0 = this.z2f_1;
|
|
701
|
+
var endIndex_0 = this.z2f_1 + byteCount | 0;
|
|
722
702
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
723
703
|
// Inline function 'kotlin.js.asDynamic' call
|
|
724
|
-
var tmp_0 =
|
|
704
|
+
var tmp_0 = this_1;
|
|
725
705
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
726
706
|
// Inline function 'kotlin.js.asDynamic' call
|
|
727
|
-
arrayCopy(tmp_0,
|
|
728
|
-
sink.
|
|
729
|
-
this.
|
|
707
|
+
arrayCopy(tmp_0, destination_0, destinationOffset, startIndex_0, endIndex_0);
|
|
708
|
+
sink.a2g_1 = sink.a2g_1 + byteCount | 0;
|
|
709
|
+
this.z2f_1 = this.z2f_1 + byteCount | 0;
|
|
730
710
|
};
|
|
731
|
-
protoOf(Segment).
|
|
711
|
+
protoOf(Segment).i2g = function (dst, dstStartOffset, dstEndOffset) {
|
|
732
712
|
var len = dstEndOffset - dstStartOffset | 0;
|
|
733
|
-
var tmp0 = this.p2h_1;
|
|
734
|
-
var tmp3 = this.q2h_1;
|
|
735
713
|
// Inline function 'kotlin.collections.copyInto' call
|
|
736
|
-
var
|
|
714
|
+
var this_0 = this.y2f_1;
|
|
715
|
+
var startIndex = this.z2f_1;
|
|
716
|
+
var endIndex = this.z2f_1 + len | 0;
|
|
737
717
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
738
718
|
// Inline function 'kotlin.js.asDynamic' call
|
|
739
|
-
var tmp =
|
|
719
|
+
var tmp = this_0;
|
|
740
720
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
741
721
|
// Inline function 'kotlin.js.asDynamic' call
|
|
742
|
-
arrayCopy(tmp, dst, dstStartOffset,
|
|
743
|
-
this.
|
|
722
|
+
arrayCopy(tmp, dst, dstStartOffset, startIndex, endIndex);
|
|
723
|
+
this.z2f_1 = this.z2f_1 + len | 0;
|
|
744
724
|
};
|
|
745
725
|
protoOf(Segment).j = function () {
|
|
746
|
-
return this.
|
|
726
|
+
return this.a2g_1 - this.z2f_1 | 0;
|
|
747
727
|
};
|
|
748
|
-
protoOf(Segment).
|
|
749
|
-
return this.
|
|
728
|
+
protoOf(Segment).m2h = function () {
|
|
729
|
+
return this.y2f_1.length - this.a2g_1 | 0;
|
|
750
730
|
};
|
|
751
|
-
protoOf(Segment).
|
|
752
|
-
return this.
|
|
731
|
+
protoOf(Segment).n2h = function (readOnly) {
|
|
732
|
+
return this.y2f_1;
|
|
753
733
|
};
|
|
754
|
-
protoOf(Segment).
|
|
755
|
-
return this.
|
|
734
|
+
protoOf(Segment).o2h = function (index) {
|
|
735
|
+
return this.y2f_1[this.z2f_1 + index | 0];
|
|
756
736
|
};
|
|
757
|
-
protoOf(Segment).
|
|
758
|
-
this.
|
|
737
|
+
protoOf(Segment).p2h = function (index, value) {
|
|
738
|
+
this.y2f_1[this.a2g_1 + index | 0] = value;
|
|
759
739
|
};
|
|
760
|
-
protoOf(Segment).
|
|
761
|
-
var d = this.
|
|
762
|
-
var l = this.
|
|
740
|
+
protoOf(Segment).q2h = function (index, b0, b1) {
|
|
741
|
+
var d = this.y2f_1;
|
|
742
|
+
var l = this.a2g_1;
|
|
763
743
|
d[l + index | 0] = b0;
|
|
764
744
|
d[(l + index | 0) + 1 | 0] = b1;
|
|
765
745
|
};
|
|
766
|
-
protoOf(Segment).
|
|
767
|
-
var d = this.
|
|
768
|
-
var l = this.
|
|
746
|
+
protoOf(Segment).r2h = function (index, b0, b1, b2) {
|
|
747
|
+
var d = this.y2f_1;
|
|
748
|
+
var l = this.a2g_1;
|
|
769
749
|
d[l + index | 0] = b0;
|
|
770
750
|
d[(l + index | 0) + 1 | 0] = b1;
|
|
771
751
|
d[(l + index | 0) + 2 | 0] = b2;
|
|
772
752
|
};
|
|
773
|
-
protoOf(Segment).
|
|
774
|
-
var d = this.
|
|
775
|
-
var l = this.
|
|
753
|
+
protoOf(Segment).s2h = function (index, b0, b1, b2, b3) {
|
|
754
|
+
var d = this.y2f_1;
|
|
755
|
+
var l = this.a2g_1;
|
|
776
756
|
d[l + index | 0] = b0;
|
|
777
757
|
d[(l + index | 0) + 1 | 0] = b1;
|
|
778
758
|
d[(l + index | 0) + 2 | 0] = b2;
|
|
779
759
|
d[(l + index | 0) + 3 | 0] = b3;
|
|
780
760
|
};
|
|
781
761
|
function Segment() {
|
|
782
|
-
this.
|
|
783
|
-
this.
|
|
784
|
-
this.
|
|
785
|
-
this.
|
|
786
|
-
this.
|
|
787
|
-
this.
|
|
762
|
+
this.z2f_1 = 0;
|
|
763
|
+
this.a2g_1 = 0;
|
|
764
|
+
this.b2g_1 = null;
|
|
765
|
+
this.c2g_1 = false;
|
|
766
|
+
this.d2g_1 = null;
|
|
767
|
+
this.e2g_1 = null;
|
|
788
768
|
}
|
|
789
769
|
function SegmentCopyTracker() {
|
|
790
770
|
}
|
|
@@ -795,10 +775,10 @@ function AlwaysSharedCopyTracker() {
|
|
|
795
775
|
AlwaysSharedCopyTracker_instance = this;
|
|
796
776
|
SegmentCopyTracker.call(this);
|
|
797
777
|
}
|
|
798
|
-
protoOf(AlwaysSharedCopyTracker).
|
|
778
|
+
protoOf(AlwaysSharedCopyTracker).z25 = function () {
|
|
799
779
|
return true;
|
|
800
780
|
};
|
|
801
|
-
protoOf(AlwaysSharedCopyTracker).
|
|
781
|
+
protoOf(AlwaysSharedCopyTracker).l2h = function () {
|
|
802
782
|
return Unit_instance;
|
|
803
783
|
};
|
|
804
784
|
var AlwaysSharedCopyTracker_instance;
|
|
@@ -811,7 +791,8 @@ function readByteArray(_this__u8e3s4, byteCount) {
|
|
|
811
791
|
// Inline function 'kotlinx.io.checkByteCount' call
|
|
812
792
|
var byteCount_0 = toLong(byteCount);
|
|
813
793
|
// Inline function 'kotlin.require' call
|
|
814
|
-
|
|
794
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
795
|
+
if (!(byteCount_0.j1(new Long(0, 0)) >= 0)) {
|
|
815
796
|
// Inline function 'kotlinx.io.checkByteCount.<anonymous>' call
|
|
816
797
|
var message = 'byteCount (' + byteCount_0.toString() + ') < 0';
|
|
817
798
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
@@ -822,22 +803,23 @@ function readByteArrayImpl(_this__u8e3s4, size) {
|
|
|
822
803
|
var arraySize = size;
|
|
823
804
|
if (size === -1) {
|
|
824
805
|
var fetchSize = new Long(2147483647, 0);
|
|
825
|
-
while (_this__u8e3s4.
|
|
806
|
+
while (_this__u8e3s4.s2f().j().j1(new Long(2147483647, 0)) < 0 && _this__u8e3s4.v2f(fetchSize)) {
|
|
826
807
|
// Inline function 'kotlin.Long.times' call
|
|
827
|
-
fetchSize = fetchSize.
|
|
808
|
+
fetchSize = fetchSize.b3(toLong(2));
|
|
828
809
|
}
|
|
829
810
|
// Inline function 'kotlin.check' call
|
|
830
|
-
|
|
811
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
812
|
+
if (!(_this__u8e3s4.s2f().j().j1(new Long(2147483647, 0)) < 0)) {
|
|
831
813
|
// Inline function 'kotlinx.io.readByteArrayImpl.<anonymous>' call
|
|
832
|
-
var message = "Can't create an array of size " + _this__u8e3s4.
|
|
814
|
+
var message = "Can't create an array of size " + _this__u8e3s4.s2f().j().toString();
|
|
833
815
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
834
816
|
}
|
|
835
|
-
arraySize = _this__u8e3s4.
|
|
817
|
+
arraySize = _this__u8e3s4.s2f().j().l1();
|
|
836
818
|
} else {
|
|
837
|
-
_this__u8e3s4.
|
|
819
|
+
_this__u8e3s4.u2f(toLong(size));
|
|
838
820
|
}
|
|
839
821
|
var array = new Int8Array(arraySize);
|
|
840
|
-
readTo(_this__u8e3s4.
|
|
822
|
+
readTo(_this__u8e3s4.s2f(), array);
|
|
841
823
|
return array;
|
|
842
824
|
}
|
|
843
825
|
function readTo(_this__u8e3s4, sink, startIndex, endIndex) {
|
|
@@ -848,7 +830,7 @@ function readTo(_this__u8e3s4, sink, startIndex, endIndex) {
|
|
|
848
830
|
checkBounds(toLong(size), toLong(startIndex), toLong(endIndex));
|
|
849
831
|
var offset = startIndex;
|
|
850
832
|
while (offset < endIndex) {
|
|
851
|
-
var bytesRead = _this__u8e3s4.
|
|
833
|
+
var bytesRead = _this__u8e3s4.h2g(sink, offset, endIndex);
|
|
852
834
|
if (bytesRead === -1) {
|
|
853
835
|
throw EOFException_init_$Create$_0('Source exhausted before reading ' + (endIndex - startIndex | 0) + ' bytes. ' + ('Only ' + bytesRead + ' bytes were read.'));
|
|
854
836
|
}
|
|
@@ -856,8 +838,8 @@ function readTo(_this__u8e3s4, sink, startIndex, endIndex) {
|
|
|
856
838
|
}
|
|
857
839
|
}
|
|
858
840
|
function readString(_this__u8e3s4) {
|
|
859
|
-
_this__u8e3s4.
|
|
860
|
-
return commonReadUtf8(_this__u8e3s4.
|
|
841
|
+
_this__u8e3s4.v2f(new Long(-1, 2147483647));
|
|
842
|
+
return commonReadUtf8(_this__u8e3s4.s2f(), _this__u8e3s4.s2f().j());
|
|
861
843
|
}
|
|
862
844
|
function writeString(_this__u8e3s4, string, startIndex, endIndex) {
|
|
863
845
|
startIndex = startIndex === VOID ? 0 : startIndex;
|
|
@@ -868,134 +850,134 @@ function writeString(_this__u8e3s4, string, startIndex, endIndex) {
|
|
|
868
850
|
// Inline function 'kotlinx.io.writeToInternalBuffer' call
|
|
869
851
|
// Inline function 'kotlinx.io.writeString.<anonymous>' call
|
|
870
852
|
// Inline function 'kotlinx.io.commonWriteUtf8' call
|
|
871
|
-
var this_0 = _this__u8e3s4.
|
|
853
|
+
var this_0 = _this__u8e3s4.s2f();
|
|
872
854
|
var i = startIndex;
|
|
873
855
|
while (i < endIndex) {
|
|
874
|
-
// Inline function 'kotlinx.io.writeString.<anonymous>.stub_for_inlining' call
|
|
875
|
-
var p0 = i;
|
|
876
856
|
// Inline function 'kotlin.code' call
|
|
857
|
+
var p0 = i;
|
|
877
858
|
var this_1 = charSequenceGet(string, p0);
|
|
878
859
|
var c = Char__toInt_impl_vasixd(this_1);
|
|
879
860
|
if (c < 128) {
|
|
880
861
|
$l$block_0: {
|
|
881
862
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail' call
|
|
882
|
-
var tail = this_0.
|
|
863
|
+
var tail = this_0.l2g(1);
|
|
883
864
|
// Inline function 'kotlinx.io.commonWriteUtf8.<anonymous>' call
|
|
884
865
|
var ctx = get_SegmentWriteContextImpl();
|
|
885
866
|
var segmentOffset = -i | 0;
|
|
886
867
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
887
|
-
var b = i + tail.
|
|
868
|
+
var b = i + tail.m2h() | 0;
|
|
888
869
|
var runLimit = Math.min(endIndex, b);
|
|
889
870
|
var _unary__edvuaz = i;
|
|
890
871
|
i = _unary__edvuaz + 1 | 0;
|
|
891
|
-
ctx.
|
|
872
|
+
ctx.w2h(tail, segmentOffset + _unary__edvuaz | 0, toByte(c));
|
|
892
873
|
$l$loop: while (i < runLimit) {
|
|
893
|
-
// Inline function 'kotlinx.io.writeString.<anonymous>.stub_for_inlining' call
|
|
894
|
-
var p0_0 = i;
|
|
895
874
|
// Inline function 'kotlin.code' call
|
|
875
|
+
var p0_0 = i;
|
|
896
876
|
var this_2 = charSequenceGet(string, p0_0);
|
|
897
877
|
c = Char__toInt_impl_vasixd(this_2);
|
|
898
878
|
if (c >= 128)
|
|
899
879
|
break $l$loop;
|
|
900
880
|
var _unary__edvuaz_0 = i;
|
|
901
881
|
i = _unary__edvuaz_0 + 1 | 0;
|
|
902
|
-
ctx.
|
|
882
|
+
ctx.w2h(tail, segmentOffset + _unary__edvuaz_0 | 0, toByte(c));
|
|
903
883
|
}
|
|
904
884
|
var bytesWritten = i + segmentOffset | 0;
|
|
905
885
|
if (bytesWritten === 1) {
|
|
906
|
-
tail.
|
|
886
|
+
tail.a2g_1 = tail.a2g_1 + bytesWritten | 0;
|
|
907
887
|
var tmp = this_0;
|
|
908
888
|
// Inline function 'kotlin.Long.plus' call
|
|
909
|
-
tmp.
|
|
889
|
+
tmp.r2f_1 = this_0.r2f_1.z2(toLong(bytesWritten));
|
|
910
890
|
break $l$block_0;
|
|
911
891
|
}
|
|
912
892
|
// Inline function 'kotlin.check' call
|
|
913
|
-
|
|
893
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
894
|
+
if (!(0 <= bytesWritten ? bytesWritten <= tail.m2h() : false)) {
|
|
914
895
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail.<anonymous>' call
|
|
915
|
-
var message = 'Invalid number of bytes written: ' + bytesWritten + '. Should be in 0..' + tail.
|
|
896
|
+
var message = 'Invalid number of bytes written: ' + bytesWritten + '. Should be in 0..' + tail.m2h();
|
|
916
897
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
917
898
|
}
|
|
918
899
|
if (!(bytesWritten === 0)) {
|
|
919
|
-
tail.
|
|
900
|
+
tail.a2g_1 = tail.a2g_1 + bytesWritten | 0;
|
|
920
901
|
var tmp_0 = this_0;
|
|
921
902
|
// Inline function 'kotlin.Long.plus' call
|
|
922
|
-
tmp_0.
|
|
903
|
+
tmp_0.r2f_1 = this_0.r2f_1.z2(toLong(bytesWritten));
|
|
923
904
|
break $l$block_0;
|
|
924
905
|
}
|
|
925
906
|
if (isEmpty(tail)) {
|
|
926
|
-
this_0.
|
|
907
|
+
this_0.z2g();
|
|
927
908
|
}
|
|
928
909
|
}
|
|
929
910
|
} else if (c < 2048) {
|
|
930
911
|
$l$block_2: {
|
|
931
912
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail' call
|
|
932
|
-
var tail_0 = this_0.
|
|
913
|
+
var tail_0 = this_0.l2g(2);
|
|
933
914
|
// Inline function 'kotlinx.io.commonWriteUtf8.<anonymous>' call
|
|
934
|
-
get_SegmentWriteContextImpl().
|
|
915
|
+
get_SegmentWriteContextImpl().v2h(tail_0, 0, toByte(c >> 6 | 192), toByte(c & 63 | 128));
|
|
935
916
|
var bytesWritten_0 = 2;
|
|
936
917
|
if (bytesWritten_0 === 2) {
|
|
937
|
-
tail_0.
|
|
918
|
+
tail_0.a2g_1 = tail_0.a2g_1 + bytesWritten_0 | 0;
|
|
938
919
|
var tmp_1 = this_0;
|
|
939
920
|
// Inline function 'kotlin.Long.plus' call
|
|
940
|
-
tmp_1.
|
|
921
|
+
tmp_1.r2f_1 = this_0.r2f_1.z2(toLong(bytesWritten_0));
|
|
941
922
|
break $l$block_2;
|
|
942
923
|
}
|
|
943
924
|
// Inline function 'kotlin.check' call
|
|
944
|
-
|
|
925
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
926
|
+
if (!(0 <= bytesWritten_0 ? bytesWritten_0 <= tail_0.m2h() : false)) {
|
|
945
927
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail.<anonymous>' call
|
|
946
|
-
var message_0 = 'Invalid number of bytes written: ' + bytesWritten_0 + '. Should be in 0..' + tail_0.
|
|
928
|
+
var message_0 = 'Invalid number of bytes written: ' + bytesWritten_0 + '. Should be in 0..' + tail_0.m2h();
|
|
947
929
|
throw IllegalStateException_init_$Create$(toString(message_0));
|
|
948
930
|
}
|
|
949
931
|
if (!(bytesWritten_0 === 0)) {
|
|
950
|
-
tail_0.
|
|
932
|
+
tail_0.a2g_1 = tail_0.a2g_1 + bytesWritten_0 | 0;
|
|
951
933
|
var tmp_2 = this_0;
|
|
952
934
|
// Inline function 'kotlin.Long.plus' call
|
|
953
|
-
tmp_2.
|
|
935
|
+
tmp_2.r2f_1 = this_0.r2f_1.z2(toLong(bytesWritten_0));
|
|
954
936
|
break $l$block_2;
|
|
955
937
|
}
|
|
956
938
|
if (isEmpty(tail_0)) {
|
|
957
|
-
this_0.
|
|
939
|
+
this_0.z2g();
|
|
958
940
|
}
|
|
959
941
|
}
|
|
960
942
|
i = i + 1 | 0;
|
|
961
943
|
} else if (c < 55296 || c > 57343) {
|
|
962
944
|
$l$block_4: {
|
|
963
945
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail' call
|
|
964
|
-
var tail_1 = this_0.
|
|
946
|
+
var tail_1 = this_0.l2g(3);
|
|
965
947
|
// Inline function 'kotlinx.io.commonWriteUtf8.<anonymous>' call
|
|
966
|
-
get_SegmentWriteContextImpl().
|
|
948
|
+
get_SegmentWriteContextImpl().u2h(tail_1, 0, toByte(c >> 12 | 224), toByte(c >> 6 & 63 | 128), toByte(c & 63 | 128));
|
|
967
949
|
var bytesWritten_1 = 3;
|
|
968
950
|
if (bytesWritten_1 === 3) {
|
|
969
|
-
tail_1.
|
|
951
|
+
tail_1.a2g_1 = tail_1.a2g_1 + bytesWritten_1 | 0;
|
|
970
952
|
var tmp_3 = this_0;
|
|
971
953
|
// Inline function 'kotlin.Long.plus' call
|
|
972
|
-
tmp_3.
|
|
954
|
+
tmp_3.r2f_1 = this_0.r2f_1.z2(toLong(bytesWritten_1));
|
|
973
955
|
break $l$block_4;
|
|
974
956
|
}
|
|
975
957
|
// Inline function 'kotlin.check' call
|
|
976
|
-
|
|
958
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
959
|
+
if (!(0 <= bytesWritten_1 ? bytesWritten_1 <= tail_1.m2h() : false)) {
|
|
977
960
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail.<anonymous>' call
|
|
978
|
-
var message_1 = 'Invalid number of bytes written: ' + bytesWritten_1 + '. Should be in 0..' + tail_1.
|
|
961
|
+
var message_1 = 'Invalid number of bytes written: ' + bytesWritten_1 + '. Should be in 0..' + tail_1.m2h();
|
|
979
962
|
throw IllegalStateException_init_$Create$(toString(message_1));
|
|
980
963
|
}
|
|
981
964
|
if (!(bytesWritten_1 === 0)) {
|
|
982
|
-
tail_1.
|
|
965
|
+
tail_1.a2g_1 = tail_1.a2g_1 + bytesWritten_1 | 0;
|
|
983
966
|
var tmp_4 = this_0;
|
|
984
967
|
// Inline function 'kotlin.Long.plus' call
|
|
985
|
-
tmp_4.
|
|
968
|
+
tmp_4.r2f_1 = this_0.r2f_1.z2(toLong(bytesWritten_1));
|
|
986
969
|
break $l$block_4;
|
|
987
970
|
}
|
|
988
971
|
if (isEmpty(tail_1)) {
|
|
989
|
-
this_0.
|
|
972
|
+
this_0.z2g();
|
|
990
973
|
}
|
|
991
974
|
}
|
|
992
975
|
i = i + 1 | 0;
|
|
993
976
|
} else {
|
|
994
977
|
var tmp_5;
|
|
995
978
|
if ((i + 1 | 0) < endIndex) {
|
|
996
|
-
// Inline function 'kotlinx.io.writeString.<anonymous>.stub_for_inlining' call
|
|
997
|
-
var p0_1 = i + 1 | 0;
|
|
998
979
|
// Inline function 'kotlin.code' call
|
|
980
|
+
var p0_1 = i + 1 | 0;
|
|
999
981
|
var this_3 = charSequenceGet(string, p0_1);
|
|
1000
982
|
tmp_5 = Char__toInt_impl_vasixd(this_3);
|
|
1001
983
|
} else {
|
|
@@ -1003,72 +985,70 @@ function writeString(_this__u8e3s4, string, startIndex, endIndex) {
|
|
|
1003
985
|
}
|
|
1004
986
|
var low = tmp_5;
|
|
1005
987
|
if (c > 56319 || !(56320 <= low ? low <= 57343 : false)) {
|
|
1006
|
-
|
|
1007
|
-
var this_4 = _Char___init__impl__6a9atx(63);
|
|
1008
|
-
var tmp$ret$23 = Char__toInt_impl_vasixd(this_4);
|
|
1009
|
-
this_0.m2i(toByte(tmp$ret$23));
|
|
988
|
+
this_0.v2g(63);
|
|
1010
989
|
i = i + 1 | 0;
|
|
1011
990
|
} else {
|
|
1012
991
|
var codePoint = 65536 + ((c & 1023) << 10 | low & 1023) | 0;
|
|
1013
992
|
$l$block_6: {
|
|
1014
993
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail' call
|
|
1015
|
-
var tail_2 = this_0.
|
|
994
|
+
var tail_2 = this_0.l2g(4);
|
|
1016
995
|
// Inline function 'kotlinx.io.commonWriteUtf8.<anonymous>' call
|
|
1017
|
-
get_SegmentWriteContextImpl().
|
|
996
|
+
get_SegmentWriteContextImpl().t2h(tail_2, 0, toByte(codePoint >> 18 | 240), toByte(codePoint >> 12 & 63 | 128), toByte(codePoint >> 6 & 63 | 128), toByte(codePoint & 63 | 128));
|
|
1018
997
|
var bytesWritten_2 = 4;
|
|
1019
998
|
if (bytesWritten_2 === 4) {
|
|
1020
|
-
tail_2.
|
|
999
|
+
tail_2.a2g_1 = tail_2.a2g_1 + bytesWritten_2 | 0;
|
|
1021
1000
|
var tmp_6 = this_0;
|
|
1022
1001
|
// Inline function 'kotlin.Long.plus' call
|
|
1023
|
-
tmp_6.
|
|
1002
|
+
tmp_6.r2f_1 = this_0.r2f_1.z2(toLong(bytesWritten_2));
|
|
1024
1003
|
break $l$block_6;
|
|
1025
1004
|
}
|
|
1026
1005
|
// Inline function 'kotlin.check' call
|
|
1027
|
-
|
|
1006
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
1007
|
+
if (!(0 <= bytesWritten_2 ? bytesWritten_2 <= tail_2.m2h() : false)) {
|
|
1028
1008
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail.<anonymous>' call
|
|
1029
|
-
var message_2 = 'Invalid number of bytes written: ' + bytesWritten_2 + '. Should be in 0..' + tail_2.
|
|
1009
|
+
var message_2 = 'Invalid number of bytes written: ' + bytesWritten_2 + '. Should be in 0..' + tail_2.m2h();
|
|
1030
1010
|
throw IllegalStateException_init_$Create$(toString(message_2));
|
|
1031
1011
|
}
|
|
1032
1012
|
if (!(bytesWritten_2 === 0)) {
|
|
1033
|
-
tail_2.
|
|
1013
|
+
tail_2.a2g_1 = tail_2.a2g_1 + bytesWritten_2 | 0;
|
|
1034
1014
|
var tmp_7 = this_0;
|
|
1035
1015
|
// Inline function 'kotlin.Long.plus' call
|
|
1036
|
-
tmp_7.
|
|
1016
|
+
tmp_7.r2f_1 = this_0.r2f_1.z2(toLong(bytesWritten_2));
|
|
1037
1017
|
break $l$block_6;
|
|
1038
1018
|
}
|
|
1039
1019
|
if (isEmpty(tail_2)) {
|
|
1040
|
-
this_0.
|
|
1020
|
+
this_0.z2g();
|
|
1041
1021
|
}
|
|
1042
1022
|
}
|
|
1043
1023
|
i = i + 2 | 0;
|
|
1044
1024
|
}
|
|
1045
1025
|
}
|
|
1046
1026
|
}
|
|
1047
|
-
_this__u8e3s4.
|
|
1027
|
+
_this__u8e3s4.w2f();
|
|
1048
1028
|
}
|
|
1049
1029
|
function commonReadUtf8(_this__u8e3s4, byteCount) {
|
|
1050
1030
|
if (byteCount.equals(new Long(0, 0)))
|
|
1051
1031
|
return '';
|
|
1052
1032
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.forEachSegment' call
|
|
1053
|
-
var curr = _this__u8e3s4.
|
|
1033
|
+
var curr = _this__u8e3s4.p2f_1;
|
|
1054
1034
|
while (!(curr == null)) {
|
|
1055
|
-
get_SegmentReadContextImpl();
|
|
1056
1035
|
// Inline function 'kotlinx.io.commonReadUtf8.<anonymous>' call
|
|
1057
|
-
|
|
1036
|
+
get_SegmentReadContextImpl();
|
|
1037
|
+
if (toLong(curr.j()).j1(byteCount) >= 0) {
|
|
1058
1038
|
var result = '';
|
|
1059
1039
|
// Inline function 'kotlinx.io.unsafe.withData' call
|
|
1060
|
-
var tmp2 = curr.e2j(true);
|
|
1061
|
-
var tmp3 = curr.q2h_1;
|
|
1062
1040
|
// Inline function 'kotlinx.io.commonReadUtf8.<anonymous>.<anonymous>' call
|
|
1063
|
-
var
|
|
1041
|
+
var data = curr.n2h(true);
|
|
1042
|
+
var pos = curr.z2f_1;
|
|
1064
1043
|
// Inline function 'kotlin.math.min' call
|
|
1065
|
-
var
|
|
1066
|
-
var
|
|
1067
|
-
|
|
1068
|
-
|
|
1044
|
+
var a = curr.a2g_1;
|
|
1045
|
+
var b = pos + byteCount.l1() | 0;
|
|
1046
|
+
var tmp$ret$0 = Math.min(a, b);
|
|
1047
|
+
result = commonToUtf8String(data, pos, tmp$ret$0);
|
|
1048
|
+
_this__u8e3s4.f2g(byteCount);
|
|
1069
1049
|
return result;
|
|
1070
1050
|
}
|
|
1071
|
-
return commonToUtf8String(readByteArray(_this__u8e3s4, byteCount.
|
|
1051
|
+
return commonToUtf8String(readByteArray(_this__u8e3s4, byteCount.l1()));
|
|
1072
1052
|
}
|
|
1073
1053
|
// Inline function 'kotlin.error' call
|
|
1074
1054
|
var message = 'Unreacheable';
|
|
@@ -1082,9 +1062,9 @@ function FileMetadata(isRegularFile, isDirectory, size) {
|
|
|
1082
1062
|
isRegularFile = isRegularFile === VOID ? false : isRegularFile;
|
|
1083
1063
|
isDirectory = isDirectory === VOID ? false : isDirectory;
|
|
1084
1064
|
size = size === VOID ? new Long(0, 0) : size;
|
|
1085
|
-
this.
|
|
1086
|
-
this.
|
|
1087
|
-
this.
|
|
1065
|
+
this.e2i_1 = isRegularFile;
|
|
1066
|
+
this.f2i_1 = isDirectory;
|
|
1067
|
+
this.g2i_1 = size;
|
|
1088
1068
|
}
|
|
1089
1069
|
function Path(base, parts) {
|
|
1090
1070
|
return Path_0(base.toString(), parts.slice());
|
|
@@ -1113,10 +1093,12 @@ function removeTrailingSeparators(path, isWindows_) {
|
|
|
1113
1093
|
}
|
|
1114
1094
|
function Path_0(base, parts) {
|
|
1115
1095
|
// Inline function 'kotlin.text.buildString' call
|
|
1096
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
1116
1097
|
// Inline function 'kotlin.apply' call
|
|
1117
1098
|
var this_0 = StringBuilder_init_$Create$_0();
|
|
1099
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
1118
1100
|
// Inline function 'kotlinx.io.files.Path.<anonymous>' call
|
|
1119
|
-
this_0.
|
|
1101
|
+
this_0.y7(base);
|
|
1120
1102
|
// Inline function 'kotlin.collections.forEach' call
|
|
1121
1103
|
var inductionVariable = 0;
|
|
1122
1104
|
var last = parts.length;
|
|
@@ -1132,9 +1114,9 @@ function Path_0(base, parts) {
|
|
|
1132
1114
|
tmp = false;
|
|
1133
1115
|
}
|
|
1134
1116
|
if (tmp) {
|
|
1135
|
-
this_0.
|
|
1117
|
+
this_0.z7(get_SystemPathSeparator());
|
|
1136
1118
|
}
|
|
1137
|
-
this_0.
|
|
1119
|
+
this_0.y7(element);
|
|
1138
1120
|
}
|
|
1139
1121
|
var tmp$ret$2 = this_0.toString();
|
|
1140
1122
|
return Path_2(tmp$ret$2);
|
|
@@ -1150,7 +1132,9 @@ function isUnc(path) {
|
|
|
1150
1132
|
}
|
|
1151
1133
|
function removeTrailingSeparatorsWindows(suffixLength, path) {
|
|
1152
1134
|
// Inline function 'kotlin.require' call
|
|
1135
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
1153
1136
|
// Inline function 'kotlin.require' call
|
|
1137
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
1154
1138
|
if (!(suffixLength >= 1)) {
|
|
1155
1139
|
// Inline function 'kotlin.require.<anonymous>' call
|
|
1156
1140
|
var message = 'Failed requirement.';
|
|
@@ -1192,49 +1176,45 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1192
1176
|
var b0 = _this__u8e3s4[index];
|
|
1193
1177
|
if (b0 >= 0) {
|
|
1194
1178
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1195
|
-
var c = numberToChar(b0);
|
|
1196
1179
|
var _unary__edvuaz = length;
|
|
1197
1180
|
length = _unary__edvuaz + 1 | 0;
|
|
1198
|
-
chars[_unary__edvuaz] =
|
|
1181
|
+
chars[_unary__edvuaz] = numberToChar(b0);
|
|
1199
1182
|
index = index + 1 | 0;
|
|
1200
1183
|
while (index < endIndex && _this__u8e3s4[index] >= 0) {
|
|
1184
|
+
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1201
1185
|
var _unary__edvuaz_0 = index;
|
|
1202
1186
|
index = _unary__edvuaz_0 + 1 | 0;
|
|
1203
|
-
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1204
|
-
var c_0 = numberToChar(_this__u8e3s4[_unary__edvuaz_0]);
|
|
1205
1187
|
var _unary__edvuaz_1 = length;
|
|
1206
1188
|
length = _unary__edvuaz_1 + 1 | 0;
|
|
1207
|
-
chars[_unary__edvuaz_1] =
|
|
1189
|
+
chars[_unary__edvuaz_1] = numberToChar(_this__u8e3s4[_unary__edvuaz_0]);
|
|
1208
1190
|
}
|
|
1209
1191
|
} else {
|
|
1210
1192
|
// Inline function 'kotlinx.io.shr' call
|
|
1211
1193
|
if (b0 >> 5 === -2) {
|
|
1212
1194
|
var tmp = index;
|
|
1213
|
-
var tmp3 = index;
|
|
1214
1195
|
var tmp$ret$1;
|
|
1215
1196
|
$l$block_0: {
|
|
1216
1197
|
// Inline function 'kotlinx.io.internal.process2Utf8Bytes' call
|
|
1217
|
-
|
|
1198
|
+
var beginIndex_0 = index;
|
|
1199
|
+
if (endIndex <= (beginIndex_0 + 1 | 0)) {
|
|
1218
1200
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1219
1201
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1220
|
-
var c_1 = numberToChar(65533);
|
|
1221
1202
|
var _unary__edvuaz_2 = length;
|
|
1222
1203
|
length = _unary__edvuaz_2 + 1 | 0;
|
|
1223
|
-
chars[_unary__edvuaz_2] =
|
|
1204
|
+
chars[_unary__edvuaz_2] = numberToChar(65533);
|
|
1224
1205
|
tmp$ret$1 = 1;
|
|
1225
1206
|
break $l$block_0;
|
|
1226
1207
|
}
|
|
1227
|
-
var b0_0 = _this__u8e3s4[
|
|
1228
|
-
var b1 = _this__u8e3s4[
|
|
1208
|
+
var b0_0 = _this__u8e3s4[beginIndex_0];
|
|
1209
|
+
var b1 = _this__u8e3s4[beginIndex_0 + 1 | 0];
|
|
1229
1210
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1230
1211
|
// Inline function 'kotlinx.io.and' call
|
|
1231
1212
|
if (!((b1 & 192) === 128)) {
|
|
1232
1213
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1233
1214
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1234
|
-
var c_2 = numberToChar(65533);
|
|
1235
1215
|
var _unary__edvuaz_3 = length;
|
|
1236
1216
|
length = _unary__edvuaz_3 + 1 | 0;
|
|
1237
|
-
chars[_unary__edvuaz_3] =
|
|
1217
|
+
chars[_unary__edvuaz_3] = numberToChar(65533);
|
|
1238
1218
|
tmp$ret$1 = 1;
|
|
1239
1219
|
break $l$block_0;
|
|
1240
1220
|
}
|
|
@@ -1242,17 +1222,15 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1242
1222
|
if (codePoint < 128) {
|
|
1243
1223
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1244
1224
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1245
|
-
var c_3 = numberToChar(65533);
|
|
1246
1225
|
var _unary__edvuaz_4 = length;
|
|
1247
1226
|
length = _unary__edvuaz_4 + 1 | 0;
|
|
1248
|
-
chars[_unary__edvuaz_4] =
|
|
1227
|
+
chars[_unary__edvuaz_4] = numberToChar(65533);
|
|
1249
1228
|
} else {
|
|
1250
1229
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1251
1230
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1252
|
-
var c_4 = numberToChar(codePoint);
|
|
1253
1231
|
var _unary__edvuaz_5 = length;
|
|
1254
1232
|
length = _unary__edvuaz_5 + 1 | 0;
|
|
1255
|
-
chars[_unary__edvuaz_5] =
|
|
1233
|
+
chars[_unary__edvuaz_5] = numberToChar(codePoint);
|
|
1256
1234
|
}
|
|
1257
1235
|
tmp$ret$1 = 2;
|
|
1258
1236
|
}
|
|
@@ -1261,24 +1239,23 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1261
1239
|
// Inline function 'kotlinx.io.shr' call
|
|
1262
1240
|
if (b0 >> 4 === -2) {
|
|
1263
1241
|
var tmp_0 = index;
|
|
1264
|
-
var tmp12 = index;
|
|
1265
1242
|
var tmp$ret$7;
|
|
1266
1243
|
$l$block_4: {
|
|
1267
1244
|
// Inline function 'kotlinx.io.internal.process3Utf8Bytes' call
|
|
1268
|
-
|
|
1245
|
+
var beginIndex_1 = index;
|
|
1246
|
+
if (endIndex <= (beginIndex_1 + 2 | 0)) {
|
|
1269
1247
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1270
1248
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1271
|
-
var c_5 = numberToChar(65533);
|
|
1272
1249
|
var _unary__edvuaz_6 = length;
|
|
1273
1250
|
length = _unary__edvuaz_6 + 1 | 0;
|
|
1274
|
-
chars[_unary__edvuaz_6] =
|
|
1251
|
+
chars[_unary__edvuaz_6] = numberToChar(65533);
|
|
1275
1252
|
var tmp_1;
|
|
1276
|
-
if (endIndex <= (
|
|
1253
|
+
if (endIndex <= (beginIndex_1 + 1 | 0)) {
|
|
1277
1254
|
tmp_1 = true;
|
|
1278
1255
|
} else {
|
|
1279
1256
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1280
1257
|
// Inline function 'kotlinx.io.and' call
|
|
1281
|
-
tmp_1 = !((_this__u8e3s4[
|
|
1258
|
+
tmp_1 = !((_this__u8e3s4[beginIndex_1 + 1 | 0] & 192) === 128);
|
|
1282
1259
|
}
|
|
1283
1260
|
if (tmp_1) {
|
|
1284
1261
|
tmp$ret$7 = 1;
|
|
@@ -1288,30 +1265,28 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1288
1265
|
break $l$block_4;
|
|
1289
1266
|
}
|
|
1290
1267
|
}
|
|
1291
|
-
var b0_1 = _this__u8e3s4[
|
|
1292
|
-
var b1_0 = _this__u8e3s4[
|
|
1268
|
+
var b0_1 = _this__u8e3s4[beginIndex_1];
|
|
1269
|
+
var b1_0 = _this__u8e3s4[beginIndex_1 + 1 | 0];
|
|
1293
1270
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1294
1271
|
// Inline function 'kotlinx.io.and' call
|
|
1295
1272
|
if (!((b1_0 & 192) === 128)) {
|
|
1296
1273
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1297
1274
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1298
|
-
var c_6 = numberToChar(65533);
|
|
1299
1275
|
var _unary__edvuaz_7 = length;
|
|
1300
1276
|
length = _unary__edvuaz_7 + 1 | 0;
|
|
1301
|
-
chars[_unary__edvuaz_7] =
|
|
1277
|
+
chars[_unary__edvuaz_7] = numberToChar(65533);
|
|
1302
1278
|
tmp$ret$7 = 1;
|
|
1303
1279
|
break $l$block_4;
|
|
1304
1280
|
}
|
|
1305
|
-
var b2 = _this__u8e3s4[
|
|
1281
|
+
var b2 = _this__u8e3s4[beginIndex_1 + 2 | 0];
|
|
1306
1282
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1307
1283
|
// Inline function 'kotlinx.io.and' call
|
|
1308
1284
|
if (!((b2 & 192) === 128)) {
|
|
1309
1285
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1310
1286
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1311
|
-
var c_7 = numberToChar(65533);
|
|
1312
1287
|
var _unary__edvuaz_8 = length;
|
|
1313
1288
|
length = _unary__edvuaz_8 + 1 | 0;
|
|
1314
|
-
chars[_unary__edvuaz_8] =
|
|
1289
|
+
chars[_unary__edvuaz_8] = numberToChar(65533);
|
|
1315
1290
|
tmp$ret$7 = 2;
|
|
1316
1291
|
break $l$block_4;
|
|
1317
1292
|
}
|
|
@@ -1319,24 +1294,21 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1319
1294
|
if (codePoint_0 < 2048) {
|
|
1320
1295
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1321
1296
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1322
|
-
var c_8 = numberToChar(65533);
|
|
1323
1297
|
var _unary__edvuaz_9 = length;
|
|
1324
1298
|
length = _unary__edvuaz_9 + 1 | 0;
|
|
1325
|
-
chars[_unary__edvuaz_9] =
|
|
1299
|
+
chars[_unary__edvuaz_9] = numberToChar(65533);
|
|
1326
1300
|
} else if (55296 <= codePoint_0 ? codePoint_0 <= 57343 : false) {
|
|
1327
1301
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1328
1302
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1329
|
-
var c_9 = numberToChar(65533);
|
|
1330
1303
|
var _unary__edvuaz_10 = length;
|
|
1331
1304
|
length = _unary__edvuaz_10 + 1 | 0;
|
|
1332
|
-
chars[_unary__edvuaz_10] =
|
|
1305
|
+
chars[_unary__edvuaz_10] = numberToChar(65533);
|
|
1333
1306
|
} else {
|
|
1334
1307
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1335
1308
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1336
|
-
var c_10 = numberToChar(codePoint_0);
|
|
1337
1309
|
var _unary__edvuaz_11 = length;
|
|
1338
1310
|
length = _unary__edvuaz_11 + 1 | 0;
|
|
1339
|
-
chars[_unary__edvuaz_11] =
|
|
1311
|
+
chars[_unary__edvuaz_11] = numberToChar(codePoint_0);
|
|
1340
1312
|
}
|
|
1341
1313
|
tmp$ret$7 = 3;
|
|
1342
1314
|
}
|
|
@@ -1345,49 +1317,46 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1345
1317
|
// Inline function 'kotlinx.io.shr' call
|
|
1346
1318
|
if (b0 >> 3 === -2) {
|
|
1347
1319
|
var tmp_2 = index;
|
|
1348
|
-
var tmp23 = index;
|
|
1349
1320
|
var tmp$ret$15;
|
|
1350
1321
|
$l$block_10: {
|
|
1351
1322
|
// Inline function 'kotlinx.io.internal.process4Utf8Bytes' call
|
|
1352
|
-
|
|
1323
|
+
var beginIndex_2 = index;
|
|
1324
|
+
if (endIndex <= (beginIndex_2 + 3 | 0)) {
|
|
1353
1325
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1354
1326
|
if (!(65533 === 65533)) {
|
|
1355
1327
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1356
|
-
var c_11 = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1357
1328
|
var _unary__edvuaz_12 = length;
|
|
1358
1329
|
length = _unary__edvuaz_12 + 1 | 0;
|
|
1359
|
-
chars[_unary__edvuaz_12] =
|
|
1330
|
+
chars[_unary__edvuaz_12] = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1360
1331
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1361
|
-
var c_12 = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1362
1332
|
var _unary__edvuaz_13 = length;
|
|
1363
1333
|
length = _unary__edvuaz_13 + 1 | 0;
|
|
1364
|
-
chars[_unary__edvuaz_13] =
|
|
1334
|
+
chars[_unary__edvuaz_13] = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1365
1335
|
} else {
|
|
1366
1336
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1367
|
-
var c_13 = _Char___init__impl__6a9atx(65533);
|
|
1368
1337
|
var _unary__edvuaz_14 = length;
|
|
1369
1338
|
length = _unary__edvuaz_14 + 1 | 0;
|
|
1370
|
-
chars[_unary__edvuaz_14] =
|
|
1339
|
+
chars[_unary__edvuaz_14] = _Char___init__impl__6a9atx(65533);
|
|
1371
1340
|
}
|
|
1372
1341
|
var tmp_3;
|
|
1373
|
-
if (endIndex <= (
|
|
1342
|
+
if (endIndex <= (beginIndex_2 + 1 | 0)) {
|
|
1374
1343
|
tmp_3 = true;
|
|
1375
1344
|
} else {
|
|
1376
1345
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1377
1346
|
// Inline function 'kotlinx.io.and' call
|
|
1378
|
-
tmp_3 = !((_this__u8e3s4[
|
|
1347
|
+
tmp_3 = !((_this__u8e3s4[beginIndex_2 + 1 | 0] & 192) === 128);
|
|
1379
1348
|
}
|
|
1380
1349
|
if (tmp_3) {
|
|
1381
1350
|
tmp$ret$15 = 1;
|
|
1382
1351
|
break $l$block_10;
|
|
1383
1352
|
} else {
|
|
1384
1353
|
var tmp_4;
|
|
1385
|
-
if (endIndex <= (
|
|
1354
|
+
if (endIndex <= (beginIndex_2 + 2 | 0)) {
|
|
1386
1355
|
tmp_4 = true;
|
|
1387
1356
|
} else {
|
|
1388
1357
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1389
1358
|
// Inline function 'kotlinx.io.and' call
|
|
1390
|
-
tmp_4 = !((_this__u8e3s4[
|
|
1359
|
+
tmp_4 = !((_this__u8e3s4[beginIndex_2 + 2 | 0] & 192) === 128);
|
|
1391
1360
|
}
|
|
1392
1361
|
if (tmp_4) {
|
|
1393
1362
|
tmp$ret$15 = 2;
|
|
@@ -1398,81 +1367,72 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1398
1367
|
}
|
|
1399
1368
|
}
|
|
1400
1369
|
}
|
|
1401
|
-
var b0_2 = _this__u8e3s4[
|
|
1402
|
-
var b1_1 = _this__u8e3s4[
|
|
1370
|
+
var b0_2 = _this__u8e3s4[beginIndex_2];
|
|
1371
|
+
var b1_1 = _this__u8e3s4[beginIndex_2 + 1 | 0];
|
|
1403
1372
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1404
1373
|
// Inline function 'kotlinx.io.and' call
|
|
1405
1374
|
if (!((b1_1 & 192) === 128)) {
|
|
1406
1375
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1407
1376
|
if (!(65533 === 65533)) {
|
|
1408
1377
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1409
|
-
var c_14 = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1410
1378
|
var _unary__edvuaz_15 = length;
|
|
1411
1379
|
length = _unary__edvuaz_15 + 1 | 0;
|
|
1412
|
-
chars[_unary__edvuaz_15] =
|
|
1380
|
+
chars[_unary__edvuaz_15] = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1413
1381
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1414
|
-
var c_15 = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1415
1382
|
var _unary__edvuaz_16 = length;
|
|
1416
1383
|
length = _unary__edvuaz_16 + 1 | 0;
|
|
1417
|
-
chars[_unary__edvuaz_16] =
|
|
1384
|
+
chars[_unary__edvuaz_16] = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1418
1385
|
} else {
|
|
1419
1386
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1420
|
-
var c_16 = _Char___init__impl__6a9atx(65533);
|
|
1421
1387
|
var _unary__edvuaz_17 = length;
|
|
1422
1388
|
length = _unary__edvuaz_17 + 1 | 0;
|
|
1423
|
-
chars[_unary__edvuaz_17] =
|
|
1389
|
+
chars[_unary__edvuaz_17] = _Char___init__impl__6a9atx(65533);
|
|
1424
1390
|
}
|
|
1425
1391
|
tmp$ret$15 = 1;
|
|
1426
1392
|
break $l$block_10;
|
|
1427
1393
|
}
|
|
1428
|
-
var b2_0 = _this__u8e3s4[
|
|
1394
|
+
var b2_0 = _this__u8e3s4[beginIndex_2 + 2 | 0];
|
|
1429
1395
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1430
1396
|
// Inline function 'kotlinx.io.and' call
|
|
1431
1397
|
if (!((b2_0 & 192) === 128)) {
|
|
1432
1398
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1433
1399
|
if (!(65533 === 65533)) {
|
|
1434
1400
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1435
|
-
var c_17 = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1436
1401
|
var _unary__edvuaz_18 = length;
|
|
1437
1402
|
length = _unary__edvuaz_18 + 1 | 0;
|
|
1438
|
-
chars[_unary__edvuaz_18] =
|
|
1403
|
+
chars[_unary__edvuaz_18] = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1439
1404
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1440
|
-
var c_18 = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1441
1405
|
var _unary__edvuaz_19 = length;
|
|
1442
1406
|
length = _unary__edvuaz_19 + 1 | 0;
|
|
1443
|
-
chars[_unary__edvuaz_19] =
|
|
1407
|
+
chars[_unary__edvuaz_19] = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1444
1408
|
} else {
|
|
1445
1409
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1446
|
-
var c_19 = _Char___init__impl__6a9atx(65533);
|
|
1447
1410
|
var _unary__edvuaz_20 = length;
|
|
1448
1411
|
length = _unary__edvuaz_20 + 1 | 0;
|
|
1449
|
-
chars[_unary__edvuaz_20] =
|
|
1412
|
+
chars[_unary__edvuaz_20] = _Char___init__impl__6a9atx(65533);
|
|
1450
1413
|
}
|
|
1451
1414
|
tmp$ret$15 = 2;
|
|
1452
1415
|
break $l$block_10;
|
|
1453
1416
|
}
|
|
1454
|
-
var b3 = _this__u8e3s4[
|
|
1417
|
+
var b3 = _this__u8e3s4[beginIndex_2 + 3 | 0];
|
|
1455
1418
|
// Inline function 'kotlinx.io.internal.isUtf8Continuation' call
|
|
1456
1419
|
// Inline function 'kotlinx.io.and' call
|
|
1457
1420
|
if (!((b3 & 192) === 128)) {
|
|
1458
1421
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1459
1422
|
if (!(65533 === 65533)) {
|
|
1460
1423
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1461
|
-
var c_20 = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1462
1424
|
var _unary__edvuaz_21 = length;
|
|
1463
1425
|
length = _unary__edvuaz_21 + 1 | 0;
|
|
1464
|
-
chars[_unary__edvuaz_21] =
|
|
1426
|
+
chars[_unary__edvuaz_21] = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1465
1427
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1466
|
-
var c_21 = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1467
1428
|
var _unary__edvuaz_22 = length;
|
|
1468
1429
|
length = _unary__edvuaz_22 + 1 | 0;
|
|
1469
|
-
chars[_unary__edvuaz_22] =
|
|
1430
|
+
chars[_unary__edvuaz_22] = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1470
1431
|
} else {
|
|
1471
1432
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1472
|
-
var c_22 = _Char___init__impl__6a9atx(65533);
|
|
1473
1433
|
var _unary__edvuaz_23 = length;
|
|
1474
1434
|
length = _unary__edvuaz_23 + 1 | 0;
|
|
1475
|
-
chars[_unary__edvuaz_23] =
|
|
1435
|
+
chars[_unary__edvuaz_23] = _Char___init__impl__6a9atx(65533);
|
|
1476
1436
|
}
|
|
1477
1437
|
tmp$ret$15 = 3;
|
|
1478
1438
|
break $l$block_10;
|
|
@@ -1482,81 +1442,69 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1482
1442
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1483
1443
|
if (!(65533 === 65533)) {
|
|
1484
1444
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1485
|
-
var c_23 = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1486
1445
|
var _unary__edvuaz_24 = length;
|
|
1487
1446
|
length = _unary__edvuaz_24 + 1 | 0;
|
|
1488
|
-
chars[_unary__edvuaz_24] =
|
|
1447
|
+
chars[_unary__edvuaz_24] = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1489
1448
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1490
|
-
var c_24 = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1491
1449
|
var _unary__edvuaz_25 = length;
|
|
1492
1450
|
length = _unary__edvuaz_25 + 1 | 0;
|
|
1493
|
-
chars[_unary__edvuaz_25] =
|
|
1451
|
+
chars[_unary__edvuaz_25] = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1494
1452
|
} else {
|
|
1495
1453
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1496
|
-
var c_25 = _Char___init__impl__6a9atx(65533);
|
|
1497
1454
|
var _unary__edvuaz_26 = length;
|
|
1498
1455
|
length = _unary__edvuaz_26 + 1 | 0;
|
|
1499
|
-
chars[_unary__edvuaz_26] =
|
|
1456
|
+
chars[_unary__edvuaz_26] = _Char___init__impl__6a9atx(65533);
|
|
1500
1457
|
}
|
|
1501
1458
|
} else if (55296 <= codePoint_1 ? codePoint_1 <= 57343 : false) {
|
|
1502
1459
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1503
1460
|
if (!(65533 === 65533)) {
|
|
1504
1461
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1505
|
-
var c_26 = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1506
1462
|
var _unary__edvuaz_27 = length;
|
|
1507
1463
|
length = _unary__edvuaz_27 + 1 | 0;
|
|
1508
|
-
chars[_unary__edvuaz_27] =
|
|
1464
|
+
chars[_unary__edvuaz_27] = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1509
1465
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1510
|
-
var c_27 = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1511
1466
|
var _unary__edvuaz_28 = length;
|
|
1512
1467
|
length = _unary__edvuaz_28 + 1 | 0;
|
|
1513
|
-
chars[_unary__edvuaz_28] =
|
|
1468
|
+
chars[_unary__edvuaz_28] = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1514
1469
|
} else {
|
|
1515
1470
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1516
|
-
var c_28 = _Char___init__impl__6a9atx(65533);
|
|
1517
1471
|
var _unary__edvuaz_29 = length;
|
|
1518
1472
|
length = _unary__edvuaz_29 + 1 | 0;
|
|
1519
|
-
chars[_unary__edvuaz_29] =
|
|
1473
|
+
chars[_unary__edvuaz_29] = _Char___init__impl__6a9atx(65533);
|
|
1520
1474
|
}
|
|
1521
1475
|
} else if (codePoint_1 < 65536) {
|
|
1522
1476
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1523
1477
|
if (!(65533 === 65533)) {
|
|
1524
1478
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1525
|
-
var c_29 = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1526
1479
|
var _unary__edvuaz_30 = length;
|
|
1527
1480
|
length = _unary__edvuaz_30 + 1 | 0;
|
|
1528
|
-
chars[_unary__edvuaz_30] =
|
|
1481
|
+
chars[_unary__edvuaz_30] = numberToChar((65533 >>> 10 | 0) + 55232 | 0);
|
|
1529
1482
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1530
|
-
var c_30 = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1531
1483
|
var _unary__edvuaz_31 = length;
|
|
1532
1484
|
length = _unary__edvuaz_31 + 1 | 0;
|
|
1533
|
-
chars[_unary__edvuaz_31] =
|
|
1485
|
+
chars[_unary__edvuaz_31] = numberToChar((65533 & 1023) + 56320 | 0);
|
|
1534
1486
|
} else {
|
|
1535
1487
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1536
|
-
var c_31 = _Char___init__impl__6a9atx(65533);
|
|
1537
1488
|
var _unary__edvuaz_32 = length;
|
|
1538
1489
|
length = _unary__edvuaz_32 + 1 | 0;
|
|
1539
|
-
chars[_unary__edvuaz_32] =
|
|
1490
|
+
chars[_unary__edvuaz_32] = _Char___init__impl__6a9atx(65533);
|
|
1540
1491
|
}
|
|
1541
1492
|
} else {
|
|
1542
1493
|
// Inline function 'kotlinx.io.internal.processUtf16Chars.<anonymous>' call
|
|
1543
1494
|
if (!(codePoint_1 === 65533)) {
|
|
1544
1495
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1545
|
-
var c_32 = numberToChar((codePoint_1 >>> 10 | 0) + 55232 | 0);
|
|
1546
1496
|
var _unary__edvuaz_33 = length;
|
|
1547
1497
|
length = _unary__edvuaz_33 + 1 | 0;
|
|
1548
|
-
chars[_unary__edvuaz_33] =
|
|
1498
|
+
chars[_unary__edvuaz_33] = numberToChar((codePoint_1 >>> 10 | 0) + 55232 | 0);
|
|
1549
1499
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1550
|
-
var c_33 = numberToChar((codePoint_1 & 1023) + 56320 | 0);
|
|
1551
1500
|
var _unary__edvuaz_34 = length;
|
|
1552
1501
|
length = _unary__edvuaz_34 + 1 | 0;
|
|
1553
|
-
chars[_unary__edvuaz_34] =
|
|
1502
|
+
chars[_unary__edvuaz_34] = numberToChar((codePoint_1 & 1023) + 56320 | 0);
|
|
1554
1503
|
} else {
|
|
1555
1504
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1556
|
-
var c_34 = _Char___init__impl__6a9atx(65533);
|
|
1557
1505
|
var _unary__edvuaz_35 = length;
|
|
1558
1506
|
length = _unary__edvuaz_35 + 1 | 0;
|
|
1559
|
-
chars[_unary__edvuaz_35] =
|
|
1507
|
+
chars[_unary__edvuaz_35] = _Char___init__impl__6a9atx(65533);
|
|
1560
1508
|
}
|
|
1561
1509
|
}
|
|
1562
1510
|
tmp$ret$15 = 4;
|
|
@@ -1564,10 +1512,9 @@ function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
|
1564
1512
|
index = tmp_2 + tmp$ret$15 | 0;
|
|
1565
1513
|
} else {
|
|
1566
1514
|
// Inline function 'kotlinx.io.internal.commonToUtf8String.<anonymous>' call
|
|
1567
|
-
var c_35 = _Char___init__impl__6a9atx(65533);
|
|
1568
1515
|
var _unary__edvuaz_36 = length;
|
|
1569
1516
|
length = _unary__edvuaz_36 + 1 | 0;
|
|
1570
|
-
chars[_unary__edvuaz_36] =
|
|
1517
|
+
chars[_unary__edvuaz_36] = _Char___init__impl__6a9atx(65533);
|
|
1571
1518
|
index = index + 1 | 0;
|
|
1572
1519
|
}
|
|
1573
1520
|
}
|
|
@@ -1595,27 +1542,27 @@ function UnsafeBufferOperations_getInstance() {
|
|
|
1595
1542
|
}
|
|
1596
1543
|
function SegmentReadContextImpl$1() {
|
|
1597
1544
|
}
|
|
1598
|
-
protoOf(SegmentReadContextImpl$1).
|
|
1599
|
-
return segment.
|
|
1545
|
+
protoOf(SegmentReadContextImpl$1).x2g = function (segment, offset) {
|
|
1546
|
+
return segment.o2h(offset);
|
|
1600
1547
|
};
|
|
1601
1548
|
function SegmentWriteContextImpl$1() {
|
|
1602
1549
|
}
|
|
1603
|
-
protoOf(SegmentWriteContextImpl$1).
|
|
1604
|
-
segment.
|
|
1550
|
+
protoOf(SegmentWriteContextImpl$1).w2h = function (segment, offset, value) {
|
|
1551
|
+
segment.p2h(offset, value);
|
|
1605
1552
|
};
|
|
1606
|
-
protoOf(SegmentWriteContextImpl$1).
|
|
1607
|
-
segment.
|
|
1553
|
+
protoOf(SegmentWriteContextImpl$1).v2h = function (segment, offset, b0, b1) {
|
|
1554
|
+
segment.q2h(offset, b0, b1);
|
|
1608
1555
|
};
|
|
1609
|
-
protoOf(SegmentWriteContextImpl$1).
|
|
1610
|
-
segment.
|
|
1556
|
+
protoOf(SegmentWriteContextImpl$1).u2h = function (segment, offset, b0, b1, b2) {
|
|
1557
|
+
segment.r2h(offset, b0, b1, b2);
|
|
1611
1558
|
};
|
|
1612
|
-
protoOf(SegmentWriteContextImpl$1).
|
|
1613
|
-
segment.
|
|
1559
|
+
protoOf(SegmentWriteContextImpl$1).t2h = function (segment, offset, b0, b1, b2, b3) {
|
|
1560
|
+
segment.s2h(offset, b0, b1, b2, b3);
|
|
1614
1561
|
};
|
|
1615
1562
|
function BufferIterationContextImpl$1() {
|
|
1616
1563
|
}
|
|
1617
|
-
protoOf(BufferIterationContextImpl$1).
|
|
1618
|
-
return get_SegmentReadContextImpl().
|
|
1564
|
+
protoOf(BufferIterationContextImpl$1).x2g = function (segment, offset) {
|
|
1565
|
+
return get_SegmentReadContextImpl().x2g(segment, offset);
|
|
1619
1566
|
};
|
|
1620
1567
|
var properties_initialized_UnsafeBufferOperations_kt_2xfgoc;
|
|
1621
1568
|
function _init_properties_UnsafeBufferOperations_kt__xw75gy() {
|
|
@@ -1696,15 +1643,15 @@ function EOFException() {
|
|
|
1696
1643
|
captureStack(this, EOFException);
|
|
1697
1644
|
}
|
|
1698
1645
|
function SegmentPool() {
|
|
1699
|
-
this.
|
|
1700
|
-
this.
|
|
1646
|
+
this.m2g_1 = 0;
|
|
1647
|
+
this.n2g_1 = 0;
|
|
1701
1648
|
}
|
|
1702
|
-
protoOf(SegmentPool).
|
|
1703
|
-
return Companion_instance.
|
|
1649
|
+
protoOf(SegmentPool).o2g = function () {
|
|
1650
|
+
return Companion_instance.i2h();
|
|
1704
1651
|
};
|
|
1705
|
-
protoOf(SegmentPool).
|
|
1652
|
+
protoOf(SegmentPool).y2g = function (segment) {
|
|
1706
1653
|
};
|
|
1707
|
-
protoOf(SegmentPool).
|
|
1654
|
+
protoOf(SegmentPool).k2h = function () {
|
|
1708
1655
|
return AlwaysSharedCopyTracker_getInstance();
|
|
1709
1656
|
};
|
|
1710
1657
|
var SegmentPool_instance;
|
|
@@ -1713,34 +1660,34 @@ function SegmentPool_getInstance() {
|
|
|
1713
1660
|
}
|
|
1714
1661
|
function get_path() {
|
|
1715
1662
|
_init_properties_nodeModulesJs_kt__ngjjzw();
|
|
1716
|
-
var tmp0 = path$delegate;
|
|
1717
1663
|
// Inline function 'kotlin.getValue' call
|
|
1664
|
+
var this_0 = path$delegate;
|
|
1718
1665
|
path$factory();
|
|
1719
|
-
return
|
|
1666
|
+
return this_0.b1();
|
|
1720
1667
|
}
|
|
1721
1668
|
var path$delegate;
|
|
1722
1669
|
function get_fs() {
|
|
1723
1670
|
_init_properties_nodeModulesJs_kt__ngjjzw();
|
|
1724
|
-
var tmp0 = fs$delegate;
|
|
1725
1671
|
// Inline function 'kotlin.getValue' call
|
|
1672
|
+
var this_0 = fs$delegate;
|
|
1726
1673
|
fs$factory();
|
|
1727
|
-
return
|
|
1674
|
+
return this_0.b1();
|
|
1728
1675
|
}
|
|
1729
1676
|
var fs$delegate;
|
|
1730
1677
|
function get_os() {
|
|
1731
1678
|
_init_properties_nodeModulesJs_kt__ngjjzw();
|
|
1732
|
-
var tmp0 = os$delegate;
|
|
1733
1679
|
// Inline function 'kotlin.getValue' call
|
|
1680
|
+
var this_0 = os$delegate;
|
|
1734
1681
|
os$factory();
|
|
1735
|
-
return
|
|
1682
|
+
return this_0.b1();
|
|
1736
1683
|
}
|
|
1737
1684
|
var os$delegate;
|
|
1738
1685
|
function get_buffer() {
|
|
1739
1686
|
_init_properties_nodeModulesJs_kt__ngjjzw();
|
|
1740
|
-
var tmp0 = buffer$delegate;
|
|
1741
1687
|
// Inline function 'kotlin.getValue' call
|
|
1688
|
+
var this_0 = buffer$delegate;
|
|
1742
1689
|
buffer$factory();
|
|
1743
|
-
return
|
|
1690
|
+
return this_0.b1();
|
|
1744
1691
|
}
|
|
1745
1692
|
var buffer$delegate;
|
|
1746
1693
|
function path$delegate$lambda() {
|
|
@@ -1853,7 +1800,7 @@ function FileNotFoundException(message) {
|
|
|
1853
1800
|
}
|
|
1854
1801
|
function SystemFileSystem$o$metadataOrNull$lambda($path, $metadata) {
|
|
1855
1802
|
return function () {
|
|
1856
|
-
var tmp0_elvis_lhs = get_fs().statSync($path.
|
|
1803
|
+
var tmp0_elvis_lhs = get_fs().statSync($path.h2i_1);
|
|
1857
1804
|
var tmp;
|
|
1858
1805
|
if (tmp0_elvis_lhs == null) {
|
|
1859
1806
|
return Unit_instance;
|
|
@@ -1870,16 +1817,16 @@ function SystemFileSystem$o$metadataOrNull$lambda($path, $metadata) {
|
|
|
1870
1817
|
function SystemFileSystem$1() {
|
|
1871
1818
|
SystemFileSystemImpl.call(this);
|
|
1872
1819
|
}
|
|
1873
|
-
protoOf(SystemFileSystem$1).
|
|
1874
|
-
return get_fs().existsSync(path.
|
|
1820
|
+
protoOf(SystemFileSystem$1).x2h = function (path) {
|
|
1821
|
+
return get_fs().existsSync(path.h2i_1);
|
|
1875
1822
|
};
|
|
1876
|
-
protoOf(SystemFileSystem$1).
|
|
1877
|
-
var metadata = this.
|
|
1823
|
+
protoOf(SystemFileSystem$1).y2h = function (path, mustCreate) {
|
|
1824
|
+
var metadata = this.c2i(path);
|
|
1878
1825
|
if (!(metadata == null)) {
|
|
1879
1826
|
if (mustCreate) {
|
|
1880
1827
|
throw IOException_init_$Create$_0('Path already exists: ' + path.toString());
|
|
1881
1828
|
}
|
|
1882
|
-
if (metadata.
|
|
1829
|
+
if (metadata.e2i_1) {
|
|
1883
1830
|
throw IOException_init_$Create$_0("Path already exists and it's a file: " + path.toString());
|
|
1884
1831
|
}
|
|
1885
1832
|
return Unit_instance;
|
|
@@ -1887,20 +1834,20 @@ protoOf(SystemFileSystem$1).p2j = function (path, mustCreate) {
|
|
|
1887
1834
|
// Inline function 'kotlin.collections.arrayListOf' call
|
|
1888
1835
|
var parts = ArrayList_init_$Create$();
|
|
1889
1836
|
var p = path;
|
|
1890
|
-
while (!(p == null) && !this.
|
|
1837
|
+
while (!(p == null) && !this.x2h(p)) {
|
|
1891
1838
|
parts.e(p.toString());
|
|
1892
|
-
p = p.
|
|
1839
|
+
p = p.i2i();
|
|
1893
1840
|
}
|
|
1894
1841
|
// Inline function 'kotlin.collections.forEach' call
|
|
1895
|
-
var
|
|
1896
|
-
while (
|
|
1897
|
-
var element =
|
|
1842
|
+
var tmp0_iterator = asReversed(parts).g();
|
|
1843
|
+
while (tmp0_iterator.h()) {
|
|
1844
|
+
var element = tmp0_iterator.i();
|
|
1898
1845
|
// Inline function 'kotlinx.io.files.<no name provided>.createDirectories.<anonymous>' call
|
|
1899
1846
|
get_fs().mkdirSync(element);
|
|
1900
1847
|
}
|
|
1901
1848
|
};
|
|
1902
|
-
protoOf(SystemFileSystem$1).
|
|
1903
|
-
if (!this.
|
|
1849
|
+
protoOf(SystemFileSystem$1).c2i = function (path) {
|
|
1850
|
+
if (!this.x2h(path))
|
|
1904
1851
|
return null;
|
|
1905
1852
|
var metadata = {_v: null};
|
|
1906
1853
|
var tmp2_safe_receiver = withCaughtException(SystemFileSystem$o$metadataOrNull$lambda(path, metadata));
|
|
@@ -1908,48 +1855,51 @@ protoOf(SystemFileSystem$1).t2j = function (path) {
|
|
|
1908
1855
|
null;
|
|
1909
1856
|
else {
|
|
1910
1857
|
// Inline function 'kotlin.also' call
|
|
1858
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
1911
1859
|
// Inline function 'kotlinx.io.files.<no name provided>.metadataOrNull.<anonymous>' call
|
|
1912
1860
|
throw IOException_init_$Create$_1('Stat failed for ' + path.toString(), tmp2_safe_receiver);
|
|
1913
1861
|
}
|
|
1914
1862
|
return metadata._v;
|
|
1915
1863
|
};
|
|
1916
|
-
protoOf(SystemFileSystem$1).
|
|
1864
|
+
protoOf(SystemFileSystem$1).z2h = function (path) {
|
|
1917
1865
|
return new FileSource(path);
|
|
1918
1866
|
};
|
|
1919
|
-
protoOf(SystemFileSystem$1).
|
|
1867
|
+
protoOf(SystemFileSystem$1).a2i = function (path, append) {
|
|
1920
1868
|
return new FileSink(path, append);
|
|
1921
1869
|
};
|
|
1922
|
-
protoOf(SystemFileSystem$1).
|
|
1923
|
-
var tmp0_elvis_lhs = this.
|
|
1870
|
+
protoOf(SystemFileSystem$1).d2i = function (directory) {
|
|
1871
|
+
var tmp0_elvis_lhs = this.c2i(directory);
|
|
1924
1872
|
var tmp;
|
|
1925
1873
|
if (tmp0_elvis_lhs == null) {
|
|
1926
|
-
throw new FileNotFoundException(directory.
|
|
1874
|
+
throw new FileNotFoundException(directory.h2i_1);
|
|
1927
1875
|
} else {
|
|
1928
1876
|
tmp = tmp0_elvis_lhs;
|
|
1929
1877
|
}
|
|
1930
1878
|
var metadata = tmp;
|
|
1931
|
-
if (!metadata.
|
|
1932
|
-
throw IOException_init_$Create$_0('Not a directory: ' + directory.
|
|
1933
|
-
var tmp1_elvis_lhs = get_fs().opendirSync(directory.
|
|
1879
|
+
if (!metadata.f2i_1)
|
|
1880
|
+
throw IOException_init_$Create$_0('Not a directory: ' + directory.h2i_1);
|
|
1881
|
+
var tmp1_elvis_lhs = get_fs().opendirSync(directory.h2i_1);
|
|
1934
1882
|
var tmp_0;
|
|
1935
1883
|
if (tmp1_elvis_lhs == null) {
|
|
1936
|
-
throw IOException_init_$Create$_0('Unable to read directory: ' + directory.
|
|
1884
|
+
throw IOException_init_$Create$_0('Unable to read directory: ' + directory.h2i_1);
|
|
1937
1885
|
} else {
|
|
1938
1886
|
tmp_0 = tmp1_elvis_lhs;
|
|
1939
1887
|
}
|
|
1940
1888
|
var dir = tmp_0;
|
|
1941
1889
|
try {
|
|
1942
1890
|
// Inline function 'kotlin.collections.buildList' call
|
|
1891
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
1943
1892
|
// Inline function 'kotlin.collections.buildListInternal' call
|
|
1944
1893
|
// Inline function 'kotlin.apply' call
|
|
1945
1894
|
var this_0 = ArrayList_init_$Create$();
|
|
1895
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
1946
1896
|
// Inline function 'kotlinx.io.files.<no name provided>.list.<anonymous>' call
|
|
1947
1897
|
var child = dir.readSync();
|
|
1948
1898
|
while (!(child == null)) {
|
|
1949
1899
|
this_0.e(Path(directory, [child.name]));
|
|
1950
1900
|
child = dir.readSync();
|
|
1951
1901
|
}
|
|
1952
|
-
return this_0.
|
|
1902
|
+
return this_0.q5();
|
|
1953
1903
|
}finally {
|
|
1954
1904
|
dir.closeSync();
|
|
1955
1905
|
}
|
|
@@ -1964,34 +1914,34 @@ function _init_properties_FileSystemNodeJs_kt__m4c3u() {
|
|
|
1964
1914
|
}
|
|
1965
1915
|
function get_SystemPathSeparator() {
|
|
1966
1916
|
_init_properties_PathsNodeJs_kt__bvvvsp();
|
|
1967
|
-
var tmp0 = SystemPathSeparator$delegate;
|
|
1968
1917
|
// Inline function 'kotlin.getValue' call
|
|
1918
|
+
var this_0 = SystemPathSeparator$delegate;
|
|
1969
1919
|
SystemPathSeparator$factory();
|
|
1970
|
-
return
|
|
1920
|
+
return this_0.b1().x_1;
|
|
1971
1921
|
}
|
|
1972
1922
|
var SystemPathSeparator$delegate;
|
|
1973
1923
|
function Path_1(rawPath, any) {
|
|
1974
|
-
this.
|
|
1924
|
+
this.h2i_1 = removeTrailingSeparators(rawPath);
|
|
1975
1925
|
}
|
|
1976
|
-
protoOf(Path_1).
|
|
1926
|
+
protoOf(Path_1).i2i = function () {
|
|
1977
1927
|
// Inline function 'kotlin.text.isEmpty' call
|
|
1978
|
-
var this_0 = this.
|
|
1928
|
+
var this_0 = this.h2i_1;
|
|
1979
1929
|
if (charSequenceLength(this_0) === 0)
|
|
1980
1930
|
return null;
|
|
1981
1931
|
if (get_isWindows()) {
|
|
1982
|
-
if (!contains(this.
|
|
1932
|
+
if (!contains(this.h2i_1, _Char___init__impl__6a9atx(47)) && !contains(this.h2i_1, _Char___init__impl__6a9atx(92))) {
|
|
1983
1933
|
return null;
|
|
1984
1934
|
}
|
|
1985
|
-
} else if (!contains(this.
|
|
1935
|
+
} else if (!contains(this.h2i_1, get_SystemPathSeparator())) {
|
|
1986
1936
|
return null;
|
|
1987
1937
|
}
|
|
1988
|
-
var p = get_path().dirname(this.
|
|
1938
|
+
var p = get_path().dirname(this.h2i_1);
|
|
1989
1939
|
var tmp;
|
|
1990
1940
|
// Inline function 'kotlin.text.isEmpty' call
|
|
1991
1941
|
if (charSequenceLength(p) === 0) {
|
|
1992
1942
|
tmp = null;
|
|
1993
1943
|
} else {
|
|
1994
|
-
if (p === this.
|
|
1944
|
+
if (p === this.h2i_1) {
|
|
1995
1945
|
tmp = null;
|
|
1996
1946
|
} else {
|
|
1997
1947
|
tmp = Path_2(p);
|
|
@@ -1999,12 +1949,12 @@ protoOf(Path_1).z2j = function () {
|
|
|
1999
1949
|
}
|
|
2000
1950
|
return tmp;
|
|
2001
1951
|
};
|
|
2002
|
-
protoOf(Path_1).
|
|
1952
|
+
protoOf(Path_1).s2 = function () {
|
|
2003
1953
|
// Inline function 'kotlin.text.isEmpty' call
|
|
2004
|
-
var this_0 = this.
|
|
1954
|
+
var this_0 = this.h2i_1;
|
|
2005
1955
|
if (charSequenceLength(this_0) === 0)
|
|
2006
1956
|
return '';
|
|
2007
|
-
var p = get_path().basename(this.
|
|
1957
|
+
var p = get_path().basename(this.h2i_1);
|
|
2008
1958
|
var tmp;
|
|
2009
1959
|
// Inline function 'kotlin.text.isEmpty' call
|
|
2010
1960
|
if (charSequenceLength(p) === 0) {
|
|
@@ -2015,21 +1965,21 @@ protoOf(Path_1).r2 = function () {
|
|
|
2015
1965
|
return tmp;
|
|
2016
1966
|
};
|
|
2017
1967
|
protoOf(Path_1).toString = function () {
|
|
2018
|
-
return this.
|
|
1968
|
+
return this.h2i_1;
|
|
2019
1969
|
};
|
|
2020
1970
|
protoOf(Path_1).equals = function (other) {
|
|
2021
1971
|
if (this === other)
|
|
2022
1972
|
return true;
|
|
2023
1973
|
if (!(other instanceof Path_1))
|
|
2024
1974
|
return false;
|
|
2025
|
-
return this.
|
|
1975
|
+
return this.h2i_1 === other.h2i_1;
|
|
2026
1976
|
};
|
|
2027
1977
|
protoOf(Path_1).hashCode = function () {
|
|
2028
|
-
return getStringHashCode(this.
|
|
1978
|
+
return getStringHashCode(this.h2i_1);
|
|
2029
1979
|
};
|
|
2030
1980
|
function open($this, path) {
|
|
2031
|
-
if (!get_fs().existsSync(path.
|
|
2032
|
-
throw new FileNotFoundException('File does not exist: ' + path.
|
|
1981
|
+
if (!get_fs().existsSync(path.h2i_1)) {
|
|
1982
|
+
throw new FileNotFoundException('File does not exist: ' + path.h2i_1);
|
|
2033
1983
|
}
|
|
2034
1984
|
var fd = {_v: -1};
|
|
2035
1985
|
var tmp3_safe_receiver = withCaughtException(FileSource$open$lambda(fd, path));
|
|
@@ -2037,35 +1987,37 @@ function open($this, path) {
|
|
|
2037
1987
|
null;
|
|
2038
1988
|
else {
|
|
2039
1989
|
// Inline function 'kotlin.also' call
|
|
1990
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2040
1991
|
// Inline function 'kotlinx.io.files.FileSource.open.<anonymous>' call
|
|
2041
|
-
throw IOException_init_$Create$_1('Failed to open a file ' + path.
|
|
1992
|
+
throw IOException_init_$Create$_1('Failed to open a file ' + path.h2i_1 + '.', tmp3_safe_receiver);
|
|
2042
1993
|
}
|
|
2043
1994
|
if (fd._v < 0)
|
|
2044
|
-
throw IOException_init_$Create$_0('Failed to open a file ' + path.
|
|
1995
|
+
throw IOException_init_$Create$_0('Failed to open a file ' + path.h2i_1 + '.');
|
|
2045
1996
|
return fd._v;
|
|
2046
1997
|
}
|
|
2047
1998
|
function FileSource$open$lambda($fd, $path) {
|
|
2048
1999
|
return function () {
|
|
2049
|
-
$fd._v = get_fs().openSync($path.
|
|
2000
|
+
$fd._v = get_fs().openSync($path.h2i_1, 'r');
|
|
2050
2001
|
return Unit_instance;
|
|
2051
2002
|
};
|
|
2052
2003
|
}
|
|
2053
2004
|
function FileSource$readAtMostTo$lambda(this$0) {
|
|
2054
2005
|
return function () {
|
|
2055
|
-
this$0.
|
|
2006
|
+
this$0.k2i_1 = get_fs().readFileSync(this$0.n2i_1, null);
|
|
2056
2007
|
return Unit_instance;
|
|
2057
2008
|
};
|
|
2058
2009
|
}
|
|
2059
2010
|
function FileSource(path) {
|
|
2060
|
-
this.
|
|
2061
|
-
this.
|
|
2062
|
-
this.
|
|
2063
|
-
this.
|
|
2064
|
-
this.
|
|
2011
|
+
this.j2i_1 = path;
|
|
2012
|
+
this.k2i_1 = null;
|
|
2013
|
+
this.l2i_1 = false;
|
|
2014
|
+
this.m2i_1 = 0;
|
|
2015
|
+
this.n2i_1 = open(this, this.j2i_1);
|
|
2065
2016
|
}
|
|
2066
|
-
protoOf(FileSource).
|
|
2017
|
+
protoOf(FileSource).j2g = function (sink, byteCount) {
|
|
2067
2018
|
// Inline function 'kotlin.check' call
|
|
2068
|
-
|
|
2019
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2020
|
+
if (!!this.l2i_1) {
|
|
2069
2021
|
// Inline function 'kotlinx.io.files.FileSource.readAtMostTo.<anonymous>' call
|
|
2070
2022
|
var message = 'Source is closed.';
|
|
2071
2023
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
@@ -2073,44 +2025,39 @@ protoOf(FileSource).a2i = function (sink, byteCount) {
|
|
|
2073
2025
|
if (byteCount.equals(new Long(0, 0))) {
|
|
2074
2026
|
return new Long(0, 0);
|
|
2075
2027
|
}
|
|
2076
|
-
if (this.
|
|
2028
|
+
if (this.k2i_1 === null) {
|
|
2077
2029
|
var tmp4_safe_receiver = withCaughtException(FileSource$readAtMostTo$lambda(this));
|
|
2078
2030
|
if (tmp4_safe_receiver == null)
|
|
2079
2031
|
null;
|
|
2080
2032
|
else {
|
|
2081
2033
|
// Inline function 'kotlin.also' call
|
|
2034
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2082
2035
|
// Inline function 'kotlinx.io.files.FileSource.readAtMostTo.<anonymous>' call
|
|
2083
|
-
throw IOException_init_$Create$_1('Failed to read data from ' + this.
|
|
2036
|
+
throw IOException_init_$Create$_1('Failed to read data from ' + this.j2i_1.h2i_1, tmp4_safe_receiver);
|
|
2084
2037
|
}
|
|
2085
2038
|
}
|
|
2086
|
-
var len = ensureNotNull(this.
|
|
2087
|
-
if (this.
|
|
2039
|
+
var len = ensureNotNull(this.k2i_1).length;
|
|
2040
|
+
if (this.m2i_1 >= len) {
|
|
2088
2041
|
return new Long(-1, -1);
|
|
2089
2042
|
}
|
|
2090
2043
|
// Inline function 'kotlinx.io.minOf' call
|
|
2091
|
-
var b = len - this.
|
|
2044
|
+
var b = len - this.m2i_1 | 0;
|
|
2092
2045
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
2093
2046
|
var b_0 = toLong(b);
|
|
2094
|
-
var bytesToRead = byteCount.
|
|
2047
|
+
var bytesToRead = byteCount.j1(b_0) <= 0 ? byteCount : b_0;
|
|
2095
2048
|
var inductionVariable = new Long(0, 0);
|
|
2096
|
-
if (inductionVariable.
|
|
2049
|
+
if (inductionVariable.j1(bytesToRead) < 0)
|
|
2097
2050
|
do {
|
|
2098
2051
|
var i = inductionVariable;
|
|
2099
|
-
inductionVariable = inductionVariable.
|
|
2100
|
-
var tmp = ensureNotNull(this.
|
|
2101
|
-
var _unary__edvuaz = this.
|
|
2102
|
-
this.
|
|
2103
|
-
sink.
|
|
2052
|
+
inductionVariable = inductionVariable.z2(new Long(1, 0));
|
|
2053
|
+
var tmp = ensureNotNull(this.k2i_1);
|
|
2054
|
+
var _unary__edvuaz = this.m2i_1;
|
|
2055
|
+
this.m2i_1 = _unary__edvuaz + 1 | 0;
|
|
2056
|
+
sink.v2g(tmp.readInt8(_unary__edvuaz));
|
|
2104
2057
|
}
|
|
2105
|
-
while (inductionVariable.
|
|
2058
|
+
while (inductionVariable.j1(bytesToRead) < 0);
|
|
2106
2059
|
return bytesToRead;
|
|
2107
2060
|
};
|
|
2108
|
-
protoOf(FileSource).g4 = function () {
|
|
2109
|
-
if (!this.c2k_1) {
|
|
2110
|
-
this.c2k_1 = true;
|
|
2111
|
-
get_fs().closeSync(this.e2k_1);
|
|
2112
|
-
}
|
|
2113
|
-
};
|
|
2114
2061
|
function open_0($this, path, append) {
|
|
2115
2062
|
var flags = append ? 'a' : 'w';
|
|
2116
2063
|
var fd = {_v: -1};
|
|
@@ -2119,32 +2066,34 @@ function open_0($this, path, append) {
|
|
|
2119
2066
|
null;
|
|
2120
2067
|
else {
|
|
2121
2068
|
// Inline function 'kotlin.also' call
|
|
2069
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2122
2070
|
// Inline function 'kotlinx.io.files.FileSink.open.<anonymous>' call
|
|
2123
|
-
throw IOException_init_$Create$_1('Failed to open a file ' + path.
|
|
2071
|
+
throw IOException_init_$Create$_1('Failed to open a file ' + path.h2i_1 + '.', tmp5_safe_receiver);
|
|
2124
2072
|
}
|
|
2125
2073
|
if (fd._v < 0)
|
|
2126
|
-
throw IOException_init_$Create$_0('Failed to open a file ' + path.
|
|
2074
|
+
throw IOException_init_$Create$_0('Failed to open a file ' + path.h2i_1 + '.');
|
|
2127
2075
|
return fd._v;
|
|
2128
2076
|
}
|
|
2129
2077
|
function FileSink$open$lambda($fd, $path, $flags) {
|
|
2130
2078
|
return function () {
|
|
2131
|
-
$fd._v = get_fs().openSync($path.
|
|
2079
|
+
$fd._v = get_fs().openSync($path.h2i_1, $flags);
|
|
2132
2080
|
return Unit_instance;
|
|
2133
2081
|
};
|
|
2134
2082
|
}
|
|
2135
2083
|
function FileSink$write$lambda(this$0, $buf) {
|
|
2136
2084
|
return function () {
|
|
2137
|
-
get_fs().writeFileSync(this$0.
|
|
2085
|
+
get_fs().writeFileSync(this$0.p2i_1, $buf);
|
|
2138
2086
|
return Unit_instance;
|
|
2139
2087
|
};
|
|
2140
2088
|
}
|
|
2141
2089
|
function FileSink(path, append) {
|
|
2142
|
-
this.
|
|
2143
|
-
this.
|
|
2090
|
+
this.o2i_1 = false;
|
|
2091
|
+
this.p2i_1 = open_0(this, path, append);
|
|
2144
2092
|
}
|
|
2145
|
-
protoOf(FileSink).
|
|
2093
|
+
protoOf(FileSink).k2g = function (source, byteCount) {
|
|
2146
2094
|
// Inline function 'kotlin.check' call
|
|
2147
|
-
|
|
2095
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2096
|
+
if (!!this.o2i_1) {
|
|
2148
2097
|
// Inline function 'kotlinx.io.files.FileSink.write.<anonymous>' call
|
|
2149
2098
|
var message = 'Sink is closed.';
|
|
2150
2099
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
@@ -2154,21 +2103,22 @@ protoOf(FileSink).b2i = function (source, byteCount) {
|
|
|
2154
2103
|
}
|
|
2155
2104
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
2156
2105
|
var b = source.j();
|
|
2157
|
-
var remainingBytes = byteCount.
|
|
2158
|
-
while (remainingBytes.
|
|
2106
|
+
var remainingBytes = byteCount.j1(b) <= 0 ? byteCount : b;
|
|
2107
|
+
while (remainingBytes.j1(new Long(0, 0)) > 0) {
|
|
2159
2108
|
var segmentBytes = 0;
|
|
2160
2109
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.readFromHead' call
|
|
2161
2110
|
// Inline function 'kotlin.require' call
|
|
2162
|
-
|
|
2111
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2112
|
+
if (!!source.t2f()) {
|
|
2163
2113
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.readFromHead.<anonymous>' call
|
|
2164
2114
|
var message_0 = 'Buffer is empty';
|
|
2165
2115
|
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
2166
2116
|
}
|
|
2167
|
-
var head = ensureNotNull(source.
|
|
2168
|
-
var tmp5 = head.e2j(true);
|
|
2169
|
-
var tmp6 = head.q2h_1;
|
|
2117
|
+
var head = ensureNotNull(source.p2f_1);
|
|
2170
2118
|
// Inline function 'kotlinx.io.files.FileSink.write.<anonymous>' call
|
|
2171
|
-
|
|
2119
|
+
var headData = head.n2h(true);
|
|
2120
|
+
var headPos = head.z2f_1;
|
|
2121
|
+
segmentBytes = head.a2g_1 - headPos | 0;
|
|
2172
2122
|
var buf = get_buffer().Buffer.allocUnsafe(segmentBytes);
|
|
2173
2123
|
var inductionVariable = 0;
|
|
2174
2124
|
var last = segmentBytes;
|
|
@@ -2176,7 +2126,7 @@ protoOf(FileSink).b2i = function (source, byteCount) {
|
|
|
2176
2126
|
do {
|
|
2177
2127
|
var offset = inductionVariable;
|
|
2178
2128
|
inductionVariable = inductionVariable + 1 | 0;
|
|
2179
|
-
buf.writeInt8(
|
|
2129
|
+
buf.writeInt8(headData[headPos + offset | 0], offset);
|
|
2180
2130
|
}
|
|
2181
2131
|
while (inductionVariable < last);
|
|
2182
2132
|
var tmp6_safe_receiver = withCaughtException(FileSink$write$lambda(this, buf));
|
|
@@ -2184,6 +2134,7 @@ protoOf(FileSink).b2i = function (source, byteCount) {
|
|
|
2184
2134
|
null;
|
|
2185
2135
|
else {
|
|
2186
2136
|
// Inline function 'kotlin.also' call
|
|
2137
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2187
2138
|
// Inline function 'kotlinx.io.files.FileSink.write.<anonymous>.<anonymous>' call
|
|
2188
2139
|
throw IOException_init_$Create$_1('Write failed', tmp6_safe_receiver);
|
|
2189
2140
|
}
|
|
@@ -2193,23 +2144,17 @@ protoOf(FileSink).b2i = function (source, byteCount) {
|
|
|
2193
2144
|
throw IllegalStateException_init_$Create$('Returned negative read bytes count');
|
|
2194
2145
|
if (bytesRead > head.j())
|
|
2195
2146
|
throw IllegalStateException_init_$Create$('Returned too many bytes');
|
|
2196
|
-
source.
|
|
2147
|
+
source.f2g(toLong(bytesRead));
|
|
2197
2148
|
}
|
|
2198
|
-
var tmp8 = remainingBytes;
|
|
2199
2149
|
// Inline function 'kotlin.Long.minus' call
|
|
2150
|
+
var this_0 = remainingBytes;
|
|
2200
2151
|
var other = segmentBytes;
|
|
2201
|
-
remainingBytes =
|
|
2152
|
+
remainingBytes = this_0.a3(toLong(other));
|
|
2202
2153
|
}
|
|
2203
2154
|
};
|
|
2204
|
-
protoOf(FileSink).
|
|
2155
|
+
protoOf(FileSink).q8 = function () {
|
|
2205
2156
|
return Unit_instance;
|
|
2206
2157
|
};
|
|
2207
|
-
protoOf(FileSink).g4 = function () {
|
|
2208
|
-
if (!this.f2k_1) {
|
|
2209
|
-
this.f2k_1 = true;
|
|
2210
|
-
get_fs().closeSync(this.g2k_1);
|
|
2211
|
-
}
|
|
2212
|
-
};
|
|
2213
2158
|
function Path_2(path) {
|
|
2214
2159
|
_init_properties_PathsNodeJs_kt__bvvvsp();
|
|
2215
2160
|
return new Path_1(path, null);
|
|
@@ -2218,8 +2163,13 @@ function SystemPathSeparator$delegate$lambda() {
|
|
|
2218
2163
|
_init_properties_PathsNodeJs_kt__bvvvsp();
|
|
2219
2164
|
var sep = get_path().sep;
|
|
2220
2165
|
// Inline function 'kotlin.check' call
|
|
2166
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2167
|
+
// Inline function 'kotlin.check' call
|
|
2168
|
+
// Inline function 'kotlin.contracts.contract' call
|
|
2221
2169
|
if (!(sep.length === 1)) {
|
|
2222
|
-
|
|
2170
|
+
// Inline function 'kotlin.check.<anonymous>' call
|
|
2171
|
+
var message = 'Check failed.';
|
|
2172
|
+
throw IllegalStateException_init_$Create$(toString(message));
|
|
2223
2173
|
}
|
|
2224
2174
|
return new Char(charSequenceGet(sep, 0));
|
|
2225
2175
|
}
|
|
@@ -2236,7 +2186,7 @@ function _init_properties_PathsNodeJs_kt__bvvvsp() {
|
|
|
2236
2186
|
}
|
|
2237
2187
|
}
|
|
2238
2188
|
//region block: post-declaration
|
|
2239
|
-
protoOf(SystemFileSystemImpl).
|
|
2189
|
+
protoOf(SystemFileSystemImpl).b2i = sink$default;
|
|
2240
2190
|
//endregion
|
|
2241
2191
|
//region block: init
|
|
2242
2192
|
Companion_instance = new Companion();
|