@doordeck/doordeck-headless-sdk 0.71.0 → 0.73.0
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/README.md +14 -14
- package/kotlin/Kotlin-DateTime-library-kotlinx-datetime.js +1343 -1343
- package/kotlin/KotlinMultiplatformLibsodium-multiplatform-crypto-libsodium-bindings.js +35 -35
- package/kotlin/MultiplatformSettings-multiplatform-settings.js +9 -9
- package/kotlin/doordeck-sdk.d.ts +463 -489
- package/kotlin/doordeck-sdk.js +28975 -28999
- package/kotlin/kotlin-kotlin-stdlib.js +2288 -2789
- package/kotlin/kotlin-kotlinx-atomicfu-runtime.js +6 -0
- package/kotlin/kotlinx-atomicfu.js +19 -19
- package/kotlin/kotlinx-coroutines-core.js +2189 -2805
- package/kotlin/kotlinx-io-kotlinx-io-bytestring.js +2 -198
- package/kotlin/kotlinx-io-kotlinx-io-core.js +463 -536
- package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js +1939 -1939
- package/kotlin/kotlinx-serialization-kotlinx-serialization-json.js +1684 -1733
- package/kotlin/ktor-ktor-client-ktor-client-core.js +3074 -3401
- package/kotlin/ktor-ktor-client-ktor-client-js.js +6 -0
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-auth.js +438 -540
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-content-negotiation.js +271 -372
- package/kotlin/ktor-ktor-http.js +906 -1012
- package/kotlin/ktor-ktor-io.js +880 -1782
- package/kotlin/ktor-ktor-shared-ktor-events.js +13 -13
- package/kotlin/ktor-ktor-shared-ktor-serialization-ktor-serialization-kotlinx-ktor-serialization-kotlinx-json.js +8 -8
- package/kotlin/ktor-ktor-shared-ktor-serialization-ktor-serialization-kotlinx.js +282 -282
- package/kotlin/ktor-ktor-shared-ktor-serialization.js +137 -137
- package/kotlin/ktor-ktor-shared-ktor-websockets.js +57 -57
- package/kotlin/ktor-ktor-utils.js +668 -758
- package/package.json +2 -2
- package/kotlin/ktor-ktor-http-ktor-http-cio.js +0 -2009
|
@@ -1,59 +1,57 @@
|
|
|
1
|
-
(function (_, kotlin_kotlin
|
|
1
|
+
(function (_, kotlin_kotlin) {
|
|
2
2
|
'use strict';
|
|
3
3
|
//region block: imports
|
|
4
4
|
var imul = Math.imul;
|
|
5
|
-
var IndexOutOfBoundsException_init_$Create$ = kotlin_kotlin.$_$.
|
|
6
|
-
var Long = kotlin_kotlin.$_$.
|
|
7
|
-
var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.
|
|
8
|
-
var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.
|
|
9
|
-
var charArrayOf = kotlin_kotlin.$_$.
|
|
10
|
-
var protoOf = kotlin_kotlin.$_$.
|
|
11
|
-
var toString = kotlin_kotlin.$_$.
|
|
12
|
-
var Unit_instance = kotlin_kotlin.$_$.
|
|
13
|
-
var toShort = kotlin_kotlin.$_$.
|
|
14
|
-
var ensureNotNull = kotlin_kotlin.$_$.
|
|
15
|
-
var toLong = kotlin_kotlin.$_$.
|
|
16
|
-
var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.
|
|
17
|
-
var initMetadataForClass = kotlin_kotlin.$_$.
|
|
5
|
+
var IndexOutOfBoundsException_init_$Create$ = kotlin_kotlin.$_$.b2;
|
|
6
|
+
var Long = kotlin_kotlin.$_$.pe;
|
|
7
|
+
var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.u1;
|
|
8
|
+
var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.p2;
|
|
9
|
+
var charArrayOf = kotlin_kotlin.$_$.u9;
|
|
10
|
+
var protoOf = kotlin_kotlin.$_$.jb;
|
|
11
|
+
var toString = kotlin_kotlin.$_$.nb;
|
|
12
|
+
var Unit_instance = kotlin_kotlin.$_$.g5;
|
|
13
|
+
var toShort = kotlin_kotlin.$_$.mb;
|
|
14
|
+
var ensureNotNull = kotlin_kotlin.$_$.mf;
|
|
15
|
+
var toLong = kotlin_kotlin.$_$.lb;
|
|
16
|
+
var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.h1;
|
|
17
|
+
var initMetadataForClass = kotlin_kotlin.$_$.ja;
|
|
18
18
|
var VOID = kotlin_kotlin.$_$.h;
|
|
19
|
-
var
|
|
20
|
-
var
|
|
21
|
-
var
|
|
22
|
-
var
|
|
23
|
-
var
|
|
24
|
-
var
|
|
25
|
-
var
|
|
26
|
-
var
|
|
27
|
-
var
|
|
28
|
-
var
|
|
29
|
-
var
|
|
30
|
-
var
|
|
31
|
-
var
|
|
32
|
-
var
|
|
33
|
-
var
|
|
34
|
-
var Exception_init_$Init$ = kotlin_kotlin.$_$.n1;
|
|
35
|
-
var
|
|
36
|
-
var
|
|
37
|
-
var Exception_init_$Init$_1 = kotlin_kotlin.$_$.q1;
|
|
38
|
-
var Exception = kotlin_kotlin.$_$.cf;
|
|
19
|
+
var IllegalStateException_init_$Create$ = kotlin_kotlin.$_$.y1;
|
|
20
|
+
var objectCreate = kotlin_kotlin.$_$.ib;
|
|
21
|
+
var initMetadataForCompanion = kotlin_kotlin.$_$.ka;
|
|
22
|
+
var arrayCopy = kotlin_kotlin.$_$.w5;
|
|
23
|
+
var toByte = kotlin_kotlin.$_$.kb;
|
|
24
|
+
var IllegalArgumentException_init_$Create$_0 = kotlin_kotlin.$_$.s1;
|
|
25
|
+
var initMetadataForObject = kotlin_kotlin.$_$.pa;
|
|
26
|
+
var initMetadataForInterface = kotlin_kotlin.$_$.na;
|
|
27
|
+
var charSequenceGet = kotlin_kotlin.$_$.w9;
|
|
28
|
+
var Char__toInt_impl_vasixd = kotlin_kotlin.$_$.v2;
|
|
29
|
+
var charArray = kotlin_kotlin.$_$.v9;
|
|
30
|
+
var numberToChar = kotlin_kotlin.$_$.fb;
|
|
31
|
+
var concatToString = kotlin_kotlin.$_$.dc;
|
|
32
|
+
var Exception_init_$Init$ = kotlin_kotlin.$_$.m1;
|
|
33
|
+
var captureStack = kotlin_kotlin.$_$.t9;
|
|
34
|
+
var Exception_init_$Init$_0 = kotlin_kotlin.$_$.n1;
|
|
35
|
+
var Exception_init_$Init$_1 = kotlin_kotlin.$_$.o1;
|
|
36
|
+
var Exception = kotlin_kotlin.$_$.me;
|
|
39
37
|
//endregion
|
|
40
38
|
//region block: pre-declaration
|
|
41
|
-
initMetadataForInterface(Source, 'Source'
|
|
39
|
+
initMetadataForInterface(Source, 'Source');
|
|
42
40
|
function write$default(source, startIndex, endIndex, $super) {
|
|
43
41
|
startIndex = startIndex === VOID ? 0 : startIndex;
|
|
44
42
|
endIndex = endIndex === VOID ? source.length : endIndex;
|
|
45
43
|
var tmp;
|
|
46
44
|
if ($super === VOID) {
|
|
47
|
-
this.
|
|
45
|
+
this.l1c(source, startIndex, endIndex);
|
|
48
46
|
tmp = Unit_instance;
|
|
49
47
|
} else {
|
|
50
|
-
tmp = $super.
|
|
48
|
+
tmp = $super.l1c.call(this, source, startIndex, endIndex);
|
|
51
49
|
}
|
|
52
50
|
return tmp;
|
|
53
51
|
}
|
|
54
|
-
initMetadataForInterface(Sink, 'Sink'
|
|
52
|
+
initMetadataForInterface(Sink, 'Sink');
|
|
55
53
|
initMetadataForClass(Buffer, 'Buffer', Buffer, VOID, [Source, Sink]);
|
|
56
|
-
initMetadataForClass(PeekSource, 'PeekSource'
|
|
54
|
+
initMetadataForClass(PeekSource, 'PeekSource');
|
|
57
55
|
initMetadataForClass(RealSource, 'RealSource', VOID, VOID, [Source]);
|
|
58
56
|
initMetadataForCompanion(Companion);
|
|
59
57
|
initMetadataForClass(Segment, 'Segment');
|
|
@@ -99,20 +97,20 @@
|
|
|
99
97
|
throw EOFException_init_$Create$_0("Buffer doesn't contain required number of bytes (size: " + $this.s().toString() + ', required: ' + byteCount.toString() + ')');
|
|
100
98
|
}
|
|
101
99
|
function Buffer() {
|
|
102
|
-
this.
|
|
103
|
-
this.
|
|
104
|
-
this.
|
|
100
|
+
this.z1a_1 = null;
|
|
101
|
+
this.a1b_1 = null;
|
|
102
|
+
this.b1b_1 = new Long(0, 0);
|
|
105
103
|
}
|
|
106
104
|
protoOf(Buffer).s = function () {
|
|
107
|
-
return this.
|
|
105
|
+
return this.b1b_1;
|
|
108
106
|
};
|
|
109
|
-
protoOf(Buffer).
|
|
107
|
+
protoOf(Buffer).c1b = function () {
|
|
110
108
|
return this;
|
|
111
109
|
};
|
|
112
|
-
protoOf(Buffer).
|
|
110
|
+
protoOf(Buffer).d1b = function () {
|
|
113
111
|
return this.s().equals(new Long(0, 0));
|
|
114
112
|
};
|
|
115
|
-
protoOf(Buffer).
|
|
113
|
+
protoOf(Buffer).e1b = function (byteCount) {
|
|
116
114
|
// Inline function 'kotlin.require' call
|
|
117
115
|
if (!(byteCount.e1(new Long(0, 0)) >= 0)) {
|
|
118
116
|
// Inline function 'kotlinx.io.Buffer.require.<anonymous>' call
|
|
@@ -123,7 +121,7 @@
|
|
|
123
121
|
throw EOFException_init_$Create$_0("Buffer doesn't contain required number of bytes (size: " + this.s().toString() + ', required: ' + byteCount.toString() + ')');
|
|
124
122
|
}
|
|
125
123
|
};
|
|
126
|
-
protoOf(Buffer).
|
|
124
|
+
protoOf(Buffer).f1b = function (byteCount) {
|
|
127
125
|
// Inline function 'kotlin.require' call
|
|
128
126
|
if (!(byteCount.e1(new Long(0, 0)) >= 0)) {
|
|
129
127
|
// Inline function 'kotlinx.io.Buffer.request.<anonymous>' call
|
|
@@ -132,8 +130,8 @@
|
|
|
132
130
|
}
|
|
133
131
|
return this.s().e1(byteCount) >= 0;
|
|
134
132
|
};
|
|
135
|
-
protoOf(Buffer).
|
|
136
|
-
var tmp0_elvis_lhs = this.
|
|
133
|
+
protoOf(Buffer).g1b = function () {
|
|
134
|
+
var tmp0_elvis_lhs = this.z1a_1;
|
|
137
135
|
var tmp;
|
|
138
136
|
if (tmp0_elvis_lhs == null) {
|
|
139
137
|
throwEof(this, new Long(1, 0));
|
|
@@ -141,20 +139,20 @@
|
|
|
141
139
|
tmp = tmp0_elvis_lhs;
|
|
142
140
|
}
|
|
143
141
|
var segment = tmp;
|
|
144
|
-
var segmentSize = segment.
|
|
142
|
+
var segmentSize = segment.o1b();
|
|
145
143
|
if (segmentSize === 0) {
|
|
146
|
-
this.
|
|
147
|
-
return this.
|
|
144
|
+
this.p1b();
|
|
145
|
+
return this.g1b();
|
|
148
146
|
}
|
|
149
|
-
var v = segment.
|
|
150
|
-
this.
|
|
147
|
+
var v = segment.q1b();
|
|
148
|
+
this.b1b_1 = this.b1b_1.a3(new Long(1, 0));
|
|
151
149
|
if (segmentSize === 1) {
|
|
152
|
-
this.
|
|
150
|
+
this.p1b();
|
|
153
151
|
}
|
|
154
152
|
return v;
|
|
155
153
|
};
|
|
156
|
-
protoOf(Buffer).
|
|
157
|
-
var tmp0_elvis_lhs = this.
|
|
154
|
+
protoOf(Buffer).r1b = function () {
|
|
155
|
+
var tmp0_elvis_lhs = this.z1a_1;
|
|
158
156
|
var tmp;
|
|
159
157
|
if (tmp0_elvis_lhs == null) {
|
|
160
158
|
throwEof(this, new Long(2, 0));
|
|
@@ -162,122 +160,80 @@
|
|
|
162
160
|
tmp = tmp0_elvis_lhs;
|
|
163
161
|
}
|
|
164
162
|
var segment = tmp;
|
|
165
|
-
var segmentSize = segment.
|
|
163
|
+
var segmentSize = segment.o1b();
|
|
166
164
|
if (segmentSize < 2) {
|
|
167
|
-
this.
|
|
165
|
+
this.e1b(new Long(2, 0));
|
|
168
166
|
if (segmentSize === 0) {
|
|
169
|
-
this.
|
|
170
|
-
return this.
|
|
167
|
+
this.p1b();
|
|
168
|
+
return this.r1b();
|
|
171
169
|
}
|
|
172
170
|
// Inline function 'kotlinx.io.and' call
|
|
173
|
-
var tmp_0 = (this.
|
|
171
|
+
var tmp_0 = (this.g1b() & 255) << 8;
|
|
174
172
|
// Inline function 'kotlinx.io.and' call
|
|
175
|
-
var tmp$ret$1 = this.
|
|
173
|
+
var tmp$ret$1 = this.g1b() & 255;
|
|
176
174
|
return toShort(tmp_0 | tmp$ret$1);
|
|
177
175
|
}
|
|
178
|
-
var v = segment.
|
|
179
|
-
this.
|
|
176
|
+
var v = segment.s1b();
|
|
177
|
+
this.b1b_1 = this.b1b_1.a3(new Long(2, 0));
|
|
180
178
|
if (segmentSize === 2) {
|
|
181
|
-
this.
|
|
179
|
+
this.p1b();
|
|
182
180
|
}
|
|
183
181
|
return v;
|
|
184
182
|
};
|
|
185
|
-
protoOf(Buffer).
|
|
183
|
+
protoOf(Buffer).t1b = function () {
|
|
186
184
|
return Unit_instance;
|
|
187
185
|
};
|
|
188
|
-
protoOf(Buffer).
|
|
186
|
+
protoOf(Buffer).u1b = function (out, startIndex, endIndex) {
|
|
189
187
|
checkBounds(this.s(), startIndex, endIndex);
|
|
190
188
|
if (startIndex.equals(endIndex))
|
|
191
189
|
return Unit_instance;
|
|
192
190
|
var currentOffset = startIndex;
|
|
193
191
|
var remainingByteCount = endIndex.a3(startIndex);
|
|
194
|
-
out.
|
|
195
|
-
var s = this.
|
|
196
|
-
while (currentOffset.e1(toLong(ensureNotNull(s).
|
|
197
|
-
currentOffset = currentOffset.a3(toLong(s.
|
|
198
|
-
s = s.
|
|
192
|
+
out.b1b_1 = out.b1b_1.z2(remainingByteCount);
|
|
193
|
+
var s = this.z1a_1;
|
|
194
|
+
while (currentOffset.e1(toLong(ensureNotNull(s).j1b_1 - s.i1b_1 | 0)) >= 0) {
|
|
195
|
+
currentOffset = currentOffset.a3(toLong(s.j1b_1 - s.i1b_1 | 0));
|
|
196
|
+
s = s.m1b_1;
|
|
199
197
|
}
|
|
200
198
|
while (remainingByteCount.e1(new Long(0, 0)) > 0) {
|
|
201
|
-
var copy = ensureNotNull(s).
|
|
202
|
-
copy.
|
|
199
|
+
var copy = ensureNotNull(s).v1b();
|
|
200
|
+
copy.i1b_1 = copy.i1b_1 + currentOffset.j1() | 0;
|
|
203
201
|
var tmp = copy;
|
|
204
|
-
var tmp0 = copy.
|
|
202
|
+
var tmp0 = copy.i1b_1 + remainingByteCount.j1() | 0;
|
|
205
203
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
206
|
-
var b = copy.
|
|
207
|
-
tmp.
|
|
204
|
+
var b = copy.j1b_1;
|
|
205
|
+
tmp.j1b_1 = Math.min(tmp0, b);
|
|
208
206
|
// Inline function 'kotlinx.io.Buffer.pushSegment' call
|
|
209
|
-
if (out.
|
|
210
|
-
out.
|
|
211
|
-
out.
|
|
207
|
+
if (out.z1a_1 == null) {
|
|
208
|
+
out.z1a_1 = copy;
|
|
209
|
+
out.a1b_1 = copy;
|
|
212
210
|
} else if (false) {
|
|
213
|
-
out.
|
|
214
|
-
if (ensureNotNull(out.
|
|
215
|
-
out.
|
|
211
|
+
out.a1b_1 = ensureNotNull(out.a1b_1).w1b(copy).x1b();
|
|
212
|
+
if (ensureNotNull(out.a1b_1).n1b_1 == null) {
|
|
213
|
+
out.z1a_1 = out.a1b_1;
|
|
216
214
|
}
|
|
217
215
|
} else {
|
|
218
|
-
out.
|
|
216
|
+
out.a1b_1 = ensureNotNull(out.a1b_1).w1b(copy);
|
|
219
217
|
}
|
|
220
|
-
remainingByteCount = remainingByteCount.a3(toLong(copy.
|
|
218
|
+
remainingByteCount = remainingByteCount.a3(toLong(copy.j1b_1 - copy.i1b_1 | 0));
|
|
221
219
|
currentOffset = new Long(0, 0);
|
|
222
|
-
s = s.
|
|
220
|
+
s = s.m1b_1;
|
|
223
221
|
}
|
|
224
222
|
};
|
|
225
|
-
protoOf(Buffer).
|
|
223
|
+
protoOf(Buffer).y1b = function () {
|
|
226
224
|
var result = this.s();
|
|
227
225
|
if (result.equals(new Long(0, 0)))
|
|
228
226
|
return new Long(0, 0);
|
|
229
|
-
var tail = ensureNotNull(this.
|
|
230
|
-
if (tail.
|
|
231
|
-
result = result.a3(toLong(tail.
|
|
227
|
+
var tail = ensureNotNull(this.a1b_1);
|
|
228
|
+
if (tail.j1b_1 < 8192 && tail.l1b_1) {
|
|
229
|
+
result = result.a3(toLong(tail.j1b_1 - tail.i1b_1 | 0));
|
|
232
230
|
}
|
|
233
231
|
return result;
|
|
234
232
|
};
|
|
235
|
-
protoOf(Buffer).b1f = function (position) {
|
|
236
|
-
if (position.e1(new Long(0, 0)) < 0 || position.e1(this.s()) >= 0) {
|
|
237
|
-
throw IndexOutOfBoundsException_init_$Create$('position (' + position.toString() + ') is not within the range [0..size(' + this.s().toString() + '))');
|
|
238
|
-
}
|
|
239
|
-
if (position.equals(new Long(0, 0))) {
|
|
240
|
-
return ensureNotNull(this.c1e_1).c1f(0);
|
|
241
|
-
}
|
|
242
|
-
// Inline function 'kotlinx.io.seek' call
|
|
243
|
-
if (this.c1e_1 == null) {
|
|
244
|
-
var offset = new Long(-1, -1);
|
|
245
|
-
return ensureNotNull(null).c1f(position.a3(offset).j1());
|
|
246
|
-
}
|
|
247
|
-
if (this.s().a3(position).e1(position) < 0) {
|
|
248
|
-
var s = this.d1e_1;
|
|
249
|
-
var offset_0 = this.s();
|
|
250
|
-
$l$loop: while (!(s == null) && offset_0.e1(position) > 0) {
|
|
251
|
-
offset_0 = offset_0.a3(toLong(s.m1e_1 - s.l1e_1 | 0));
|
|
252
|
-
if (offset_0.e1(position) <= 0)
|
|
253
|
-
break $l$loop;
|
|
254
|
-
s = s.q1e_1;
|
|
255
|
-
}
|
|
256
|
-
var tmp4 = s;
|
|
257
|
-
var offset_1 = offset_0;
|
|
258
|
-
return ensureNotNull(tmp4).c1f(position.a3(offset_1).j1());
|
|
259
|
-
} else {
|
|
260
|
-
var s_0 = this.c1e_1;
|
|
261
|
-
var offset_2 = new Long(0, 0);
|
|
262
|
-
$l$loop_0: while (!(s_0 == null)) {
|
|
263
|
-
var tmp0 = offset_2;
|
|
264
|
-
// Inline function 'kotlin.Long.plus' call
|
|
265
|
-
var other = s_0.m1e_1 - s_0.l1e_1 | 0;
|
|
266
|
-
var nextOffset = tmp0.z2(toLong(other));
|
|
267
|
-
if (nextOffset.e1(position) > 0)
|
|
268
|
-
break $l$loop_0;
|
|
269
|
-
s_0 = s_0.p1e_1;
|
|
270
|
-
offset_2 = nextOffset;
|
|
271
|
-
}
|
|
272
|
-
var tmp6 = s_0;
|
|
273
|
-
var offset_3 = offset_2;
|
|
274
|
-
return ensureNotNull(tmp6).c1f(position.a3(offset_3).j1());
|
|
275
|
-
}
|
|
276
|
-
};
|
|
277
233
|
protoOf(Buffer).e2 = function () {
|
|
278
|
-
return this.
|
|
234
|
+
return this.z1b(this.s());
|
|
279
235
|
};
|
|
280
|
-
protoOf(Buffer).
|
|
236
|
+
protoOf(Buffer).z1b = function (byteCount) {
|
|
281
237
|
// Inline function 'kotlinx.io.checkByteCount' call
|
|
282
238
|
// Inline function 'kotlin.require' call
|
|
283
239
|
if (!(byteCount.e1(new Long(0, 0)) >= 0)) {
|
|
@@ -287,7 +243,7 @@
|
|
|
287
243
|
}
|
|
288
244
|
var remainingByteCount = byteCount;
|
|
289
245
|
while (remainingByteCount.e1(new Long(0, 0)) > 0) {
|
|
290
|
-
var tmp0_elvis_lhs = this.
|
|
246
|
+
var tmp0_elvis_lhs = this.z1a_1;
|
|
291
247
|
var tmp;
|
|
292
248
|
if (tmp0_elvis_lhs == null) {
|
|
293
249
|
throw EOFException_init_$Create$_0('Buffer exhausted before skipping ' + byteCount.toString() + ' bytes.');
|
|
@@ -297,23 +253,23 @@
|
|
|
297
253
|
var head = tmp;
|
|
298
254
|
var tmp1 = remainingByteCount;
|
|
299
255
|
// Inline function 'kotlinx.io.minOf' call
|
|
300
|
-
var b = head.
|
|
256
|
+
var b = head.j1b_1 - head.i1b_1 | 0;
|
|
301
257
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
302
258
|
var b_0 = toLong(b);
|
|
303
259
|
var toSkip = (tmp1.e1(b_0) <= 0 ? tmp1 : b_0).j1();
|
|
304
|
-
this.
|
|
260
|
+
this.b1b_1 = this.b1b_1.a3(toLong(toSkip));
|
|
305
261
|
remainingByteCount = remainingByteCount.a3(toLong(toSkip));
|
|
306
|
-
head.
|
|
307
|
-
if (head.
|
|
308
|
-
this.
|
|
262
|
+
head.i1b_1 = head.i1b_1 + toSkip | 0;
|
|
263
|
+
if (head.i1b_1 === head.j1b_1) {
|
|
264
|
+
this.p1b();
|
|
309
265
|
}
|
|
310
266
|
}
|
|
311
267
|
};
|
|
312
|
-
protoOf(Buffer).
|
|
268
|
+
protoOf(Buffer).a1c = function (sink, startIndex, endIndex) {
|
|
313
269
|
// Inline function 'kotlinx.io.checkBounds' call
|
|
314
270
|
var size = sink.length;
|
|
315
271
|
checkBounds(toLong(size), toLong(startIndex), toLong(endIndex));
|
|
316
|
-
var tmp0_elvis_lhs = this.
|
|
272
|
+
var tmp0_elvis_lhs = this.z1a_1;
|
|
317
273
|
var tmp;
|
|
318
274
|
if (tmp0_elvis_lhs == null) {
|
|
319
275
|
return -1;
|
|
@@ -323,16 +279,16 @@
|
|
|
323
279
|
var s = tmp;
|
|
324
280
|
var tmp3 = endIndex - startIndex | 0;
|
|
325
281
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
326
|
-
var b = s.
|
|
282
|
+
var b = s.o1b();
|
|
327
283
|
var toCopy = Math.min(tmp3, b);
|
|
328
|
-
s.
|
|
329
|
-
this.
|
|
284
|
+
s.b1c(sink, startIndex, startIndex + toCopy | 0);
|
|
285
|
+
this.b1b_1 = this.b1b_1.a3(toLong(toCopy));
|
|
330
286
|
if (isEmpty(s)) {
|
|
331
|
-
this.
|
|
287
|
+
this.p1b();
|
|
332
288
|
}
|
|
333
289
|
return toCopy;
|
|
334
290
|
};
|
|
335
|
-
protoOf(Buffer).
|
|
291
|
+
protoOf(Buffer).c1c = function (sink, byteCount) {
|
|
336
292
|
// Inline function 'kotlinx.io.checkByteCount' call
|
|
337
293
|
// Inline function 'kotlin.require' call
|
|
338
294
|
if (!(byteCount.e1(new Long(0, 0)) >= 0)) {
|
|
@@ -343,10 +299,10 @@
|
|
|
343
299
|
if (this.s().equals(new Long(0, 0)))
|
|
344
300
|
return new Long(-1, -1);
|
|
345
301
|
var bytesWritten = byteCount.e1(this.s()) > 0 ? this.s() : byteCount;
|
|
346
|
-
sink.
|
|
302
|
+
sink.d1c(this, bytesWritten);
|
|
347
303
|
return bytesWritten;
|
|
348
304
|
};
|
|
349
|
-
protoOf(Buffer).
|
|
305
|
+
protoOf(Buffer).e1c = function (sink, byteCount) {
|
|
350
306
|
// Inline function 'kotlinx.io.checkByteCount' call
|
|
351
307
|
// Inline function 'kotlin.require' call
|
|
352
308
|
if (!(byteCount.e1(new Long(0, 0)) >= 0)) {
|
|
@@ -355,154 +311,137 @@
|
|
|
355
311
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
356
312
|
}
|
|
357
313
|
if (this.s().e1(byteCount) < 0) {
|
|
358
|
-
sink.
|
|
314
|
+
sink.d1c(this, this.s());
|
|
359
315
|
throw EOFException_init_$Create$_0('Buffer exhausted before writing ' + byteCount.toString() + ' bytes. Only ' + this.s().toString() + ' bytes were written.');
|
|
360
316
|
}
|
|
361
|
-
sink.
|
|
317
|
+
sink.d1c(this, byteCount);
|
|
362
318
|
};
|
|
363
|
-
protoOf(Buffer).
|
|
319
|
+
protoOf(Buffer).f1c = function (sink) {
|
|
364
320
|
var byteCount = this.s();
|
|
365
321
|
if (byteCount.e1(new Long(0, 0)) > 0) {
|
|
366
|
-
sink.
|
|
322
|
+
sink.d1c(this, byteCount);
|
|
367
323
|
}
|
|
368
324
|
return byteCount;
|
|
369
325
|
};
|
|
370
|
-
protoOf(Buffer).
|
|
326
|
+
protoOf(Buffer).g1c = function () {
|
|
371
327
|
return buffered(new PeekSource(this));
|
|
372
328
|
};
|
|
373
|
-
protoOf(Buffer).
|
|
329
|
+
protoOf(Buffer).h1c = function (minimumCapacity) {
|
|
374
330
|
// Inline function 'kotlin.require' call
|
|
375
331
|
if (!(minimumCapacity >= 1 && minimumCapacity <= 8192)) {
|
|
376
332
|
// Inline function 'kotlinx.io.Buffer.writableSegment.<anonymous>' call
|
|
377
|
-
var message = 'unexpected capacity
|
|
333
|
+
var message = 'unexpected capacity';
|
|
378
334
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
379
335
|
}
|
|
380
|
-
if (this.
|
|
381
|
-
var result = SegmentPool_instance.
|
|
382
|
-
this.
|
|
383
|
-
this.
|
|
336
|
+
if (this.a1b_1 == null) {
|
|
337
|
+
var result = SegmentPool_instance.k1c();
|
|
338
|
+
this.z1a_1 = result;
|
|
339
|
+
this.a1b_1 = result;
|
|
384
340
|
return result;
|
|
385
341
|
}
|
|
386
|
-
var t = ensureNotNull(this.
|
|
387
|
-
if ((t.
|
|
388
|
-
var newTail = t.
|
|
389
|
-
this.
|
|
342
|
+
var t = ensureNotNull(this.a1b_1);
|
|
343
|
+
if ((t.j1b_1 + minimumCapacity | 0) > 8192 || !t.l1b_1) {
|
|
344
|
+
var newTail = t.w1b(SegmentPool_instance.k1c());
|
|
345
|
+
this.a1b_1 = newTail;
|
|
390
346
|
return newTail;
|
|
391
347
|
}
|
|
392
348
|
return t;
|
|
393
349
|
};
|
|
394
|
-
protoOf(Buffer).
|
|
350
|
+
protoOf(Buffer).l1c = function (source, startIndex, endIndex) {
|
|
395
351
|
// Inline function 'kotlinx.io.checkBounds' call
|
|
396
352
|
var size = source.length;
|
|
397
353
|
checkBounds(toLong(size), toLong(startIndex), toLong(endIndex));
|
|
398
354
|
var currentOffset = startIndex;
|
|
399
355
|
while (currentOffset < endIndex) {
|
|
400
|
-
var tail = this.
|
|
356
|
+
var tail = this.h1c(1);
|
|
401
357
|
var tmp3 = endIndex - currentOffset | 0;
|
|
402
358
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
403
|
-
var b = tail.
|
|
359
|
+
var b = tail.m1c();
|
|
404
360
|
var toCopy = Math.min(tmp3, b);
|
|
405
|
-
tail.
|
|
361
|
+
tail.n1c(source, currentOffset, currentOffset + toCopy | 0);
|
|
406
362
|
currentOffset = currentOffset + toCopy | 0;
|
|
407
363
|
}
|
|
408
364
|
var tmp = this;
|
|
409
|
-
var tmp5 = this.
|
|
365
|
+
var tmp5 = this.b1b_1;
|
|
410
366
|
// Inline function 'kotlin.Long.plus' call
|
|
411
367
|
var other = endIndex - startIndex | 0;
|
|
412
|
-
tmp.
|
|
413
|
-
};
|
|
414
|
-
protoOf(Buffer).t1f = function (source, byteCount) {
|
|
415
|
-
// Inline function 'kotlinx.io.checkByteCount' call
|
|
416
|
-
// Inline function 'kotlin.require' call
|
|
417
|
-
if (!(byteCount.e1(new Long(0, 0)) >= 0)) {
|
|
418
|
-
// Inline function 'kotlinx.io.checkByteCount.<anonymous>' call
|
|
419
|
-
var message = 'byteCount (' + byteCount.toString() + ') < 0';
|
|
420
|
-
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
421
|
-
}
|
|
422
|
-
var remainingByteCount = byteCount;
|
|
423
|
-
while (remainingByteCount.e1(new Long(0, 0)) > 0) {
|
|
424
|
-
var read = source.g1f(this, remainingByteCount);
|
|
425
|
-
if (read.equals(new Long(-1, -1))) {
|
|
426
|
-
throw EOFException_init_$Create$_0('Source exhausted before reading ' + byteCount.toString() + ' bytes. ' + ('Only ' + byteCount.a3(remainingByteCount).toString() + ' were read.'));
|
|
427
|
-
}
|
|
428
|
-
remainingByteCount = remainingByteCount.a3(read);
|
|
429
|
-
}
|
|
368
|
+
tmp.b1b_1 = tmp5.z2(toLong(other));
|
|
430
369
|
};
|
|
431
|
-
protoOf(Buffer).
|
|
370
|
+
protoOf(Buffer).d1c = function (source, byteCount) {
|
|
432
371
|
// Inline function 'kotlin.require' call
|
|
433
372
|
if (!!(source === this)) {
|
|
434
373
|
// Inline function 'kotlinx.io.Buffer.write.<anonymous>' call
|
|
435
374
|
var message = 'source == this';
|
|
436
375
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
437
376
|
}
|
|
438
|
-
checkOffsetAndCount(source.
|
|
377
|
+
checkOffsetAndCount(source.b1b_1, new Long(0, 0), byteCount);
|
|
439
378
|
var remainingByteCount = byteCount;
|
|
440
379
|
while (remainingByteCount.e1(new Long(0, 0)) > 0) {
|
|
441
|
-
if (remainingByteCount.e1(toLong(ensureNotNull(source.
|
|
442
|
-
var tail = this.
|
|
380
|
+
if (remainingByteCount.e1(toLong(ensureNotNull(source.z1a_1).o1b())) < 0) {
|
|
381
|
+
var tail = this.a1b_1;
|
|
443
382
|
var tmp;
|
|
444
|
-
if (!(tail == null) && tail.
|
|
383
|
+
if (!(tail == null) && tail.l1b_1) {
|
|
445
384
|
var tmp1 = remainingByteCount;
|
|
446
385
|
// Inline function 'kotlin.Long.plus' call
|
|
447
|
-
var other = tail.
|
|
386
|
+
var other = tail.j1b_1;
|
|
448
387
|
var tmp3 = tmp1.z2(toLong(other));
|
|
449
388
|
// Inline function 'kotlin.Long.minus' call
|
|
450
|
-
var other_0 = tail.
|
|
389
|
+
var other_0 = tail.p1c() ? 0 : tail.i1b_1;
|
|
451
390
|
tmp = tmp3.a3(toLong(other_0)).e1(new Long(8192, 0)) <= 0;
|
|
452
391
|
} else {
|
|
453
392
|
tmp = false;
|
|
454
393
|
}
|
|
455
394
|
if (tmp) {
|
|
456
|
-
ensureNotNull(source.
|
|
457
|
-
source.
|
|
458
|
-
this.
|
|
395
|
+
ensureNotNull(source.z1a_1).r1c(tail, remainingByteCount.j1());
|
|
396
|
+
source.b1b_1 = source.b1b_1.a3(remainingByteCount);
|
|
397
|
+
this.b1b_1 = this.b1b_1.z2(remainingByteCount);
|
|
459
398
|
return Unit_instance;
|
|
460
399
|
} else {
|
|
461
|
-
source.
|
|
400
|
+
source.z1a_1 = ensureNotNull(source.z1a_1).q1c(remainingByteCount.j1());
|
|
462
401
|
}
|
|
463
402
|
}
|
|
464
|
-
var segmentToMove = ensureNotNull(source.
|
|
465
|
-
var movedByteCount = toLong(segmentToMove.
|
|
466
|
-
source.
|
|
467
|
-
if (source.
|
|
468
|
-
source.
|
|
403
|
+
var segmentToMove = ensureNotNull(source.z1a_1);
|
|
404
|
+
var movedByteCount = toLong(segmentToMove.o1b());
|
|
405
|
+
source.z1a_1 = segmentToMove.s1c();
|
|
406
|
+
if (source.z1a_1 == null) {
|
|
407
|
+
source.a1b_1 = null;
|
|
469
408
|
}
|
|
470
409
|
// Inline function 'kotlinx.io.Buffer.pushSegment' call
|
|
471
|
-
if (this.
|
|
472
|
-
this.
|
|
473
|
-
this.
|
|
410
|
+
if (this.z1a_1 == null) {
|
|
411
|
+
this.z1a_1 = segmentToMove;
|
|
412
|
+
this.a1b_1 = segmentToMove;
|
|
474
413
|
} else if (true) {
|
|
475
|
-
this.
|
|
476
|
-
if (ensureNotNull(this.
|
|
477
|
-
this.
|
|
414
|
+
this.a1b_1 = ensureNotNull(this.a1b_1).w1b(segmentToMove).x1b();
|
|
415
|
+
if (ensureNotNull(this.a1b_1).n1b_1 == null) {
|
|
416
|
+
this.z1a_1 = this.a1b_1;
|
|
478
417
|
}
|
|
479
418
|
} else {
|
|
480
|
-
this.
|
|
419
|
+
this.a1b_1 = ensureNotNull(this.a1b_1).w1b(segmentToMove);
|
|
481
420
|
}
|
|
482
|
-
source.
|
|
483
|
-
this.
|
|
421
|
+
source.b1b_1 = source.b1b_1.a3(movedByteCount);
|
|
422
|
+
this.b1b_1 = this.b1b_1.z2(movedByteCount);
|
|
484
423
|
remainingByteCount = remainingByteCount.a3(movedByteCount);
|
|
485
424
|
}
|
|
486
425
|
};
|
|
487
|
-
protoOf(Buffer).
|
|
426
|
+
protoOf(Buffer).t1c = function (source) {
|
|
488
427
|
var totalBytesRead = new Long(0, 0);
|
|
489
428
|
$l$loop: while (true) {
|
|
490
|
-
var readCount = source.
|
|
429
|
+
var readCount = source.c1c(this, new Long(8192, 0));
|
|
491
430
|
if (readCount.equals(new Long(-1, -1)))
|
|
492
431
|
break $l$loop;
|
|
493
432
|
totalBytesRead = totalBytesRead.z2(readCount);
|
|
494
433
|
}
|
|
495
434
|
return totalBytesRead;
|
|
496
435
|
};
|
|
497
|
-
protoOf(Buffer).
|
|
498
|
-
this.
|
|
499
|
-
this.
|
|
436
|
+
protoOf(Buffer).u1c = function (byte) {
|
|
437
|
+
this.h1c(1).v1c(byte);
|
|
438
|
+
this.b1b_1 = this.b1b_1.z2(new Long(1, 0));
|
|
500
439
|
};
|
|
501
|
-
protoOf(Buffer).
|
|
502
|
-
this.
|
|
503
|
-
this.
|
|
440
|
+
protoOf(Buffer).w1c = function (short) {
|
|
441
|
+
this.h1c(2).x1c(short);
|
|
442
|
+
this.b1b_1 = this.b1b_1.z2(new Long(2, 0));
|
|
504
443
|
};
|
|
505
|
-
protoOf(Buffer).
|
|
444
|
+
protoOf(Buffer).y1c = function () {
|
|
506
445
|
return Unit_instance;
|
|
507
446
|
};
|
|
508
447
|
protoOf(Buffer).toString = function () {
|
|
@@ -517,77 +456,74 @@
|
|
|
517
456
|
var builder = StringBuilder_init_$Create$(imul(len, 2) + (this.s().e1(toLong(maxPrintableBytes)) > 0 ? 1 : 0) | 0);
|
|
518
457
|
var bytesWritten = 0;
|
|
519
458
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.forEachSegment' call
|
|
520
|
-
var curr = this.
|
|
459
|
+
var curr = this.z1a_1;
|
|
521
460
|
while (!(curr == null)) {
|
|
522
461
|
var tmp4 = get_SegmentReadContextImpl();
|
|
523
462
|
// Inline function 'kotlinx.io.Buffer.toString.<anonymous>' call
|
|
524
463
|
var segment = curr;
|
|
525
464
|
var idx = 0;
|
|
526
|
-
while (bytesWritten < len && idx < segment.
|
|
465
|
+
while (bytesWritten < len && idx < segment.o1b()) {
|
|
527
466
|
var _unary__edvuaz = idx;
|
|
528
467
|
idx = _unary__edvuaz + 1 | 0;
|
|
529
|
-
var b_0 = tmp4.
|
|
468
|
+
var b_0 = tmp4.z1c(segment, _unary__edvuaz);
|
|
530
469
|
bytesWritten = bytesWritten + 1 | 0;
|
|
531
470
|
var tmp = get_HEX_DIGIT_CHARS();
|
|
532
471
|
// Inline function 'kotlinx.io.shr' call
|
|
533
472
|
var tmp$ret$2 = b_0 >> 4;
|
|
534
|
-
var tmp_0 = builder.
|
|
473
|
+
var tmp_0 = builder.p8(tmp[tmp$ret$2 & 15]);
|
|
535
474
|
var tmp_1 = get_HEX_DIGIT_CHARS();
|
|
536
475
|
// Inline function 'kotlinx.io.and' call
|
|
537
476
|
var tmp$ret$3 = b_0 & 15;
|
|
538
|
-
tmp_0.
|
|
477
|
+
tmp_0.p8(tmp_1[tmp$ret$3]);
|
|
539
478
|
}
|
|
540
|
-
curr = curr.
|
|
479
|
+
curr = curr.m1b_1;
|
|
541
480
|
}
|
|
542
481
|
if (this.s().e1(toLong(maxPrintableBytes)) > 0) {
|
|
543
|
-
builder.
|
|
482
|
+
builder.p8(_Char___init__impl__6a9atx(8230));
|
|
544
483
|
}
|
|
545
484
|
return 'Buffer(size=' + this.s().toString() + ' hex=' + builder.toString() + ')';
|
|
546
485
|
};
|
|
547
|
-
protoOf(Buffer).
|
|
548
|
-
var oldHead = ensureNotNull(this.
|
|
549
|
-
var nextHead = oldHead.
|
|
550
|
-
this.
|
|
486
|
+
protoOf(Buffer).p1b = function () {
|
|
487
|
+
var oldHead = ensureNotNull(this.z1a_1);
|
|
488
|
+
var nextHead = oldHead.m1b_1;
|
|
489
|
+
this.z1a_1 = nextHead;
|
|
551
490
|
if (nextHead == null) {
|
|
552
|
-
this.
|
|
491
|
+
this.a1b_1 = null;
|
|
553
492
|
} else {
|
|
554
|
-
nextHead.
|
|
493
|
+
nextHead.n1b_1 = null;
|
|
555
494
|
}
|
|
556
|
-
oldHead.
|
|
557
|
-
SegmentPool_instance.
|
|
495
|
+
oldHead.m1b_1 = null;
|
|
496
|
+
SegmentPool_instance.a1d(oldHead);
|
|
558
497
|
};
|
|
559
|
-
protoOf(Buffer).
|
|
560
|
-
var oldTail = ensureNotNull(this.
|
|
561
|
-
var newTail = oldTail.
|
|
562
|
-
this.
|
|
498
|
+
protoOf(Buffer).b1d = function () {
|
|
499
|
+
var oldTail = ensureNotNull(this.a1b_1);
|
|
500
|
+
var newTail = oldTail.n1b_1;
|
|
501
|
+
this.a1b_1 = newTail;
|
|
563
502
|
if (newTail == null) {
|
|
564
|
-
this.
|
|
503
|
+
this.z1a_1 = null;
|
|
565
504
|
} else {
|
|
566
|
-
newTail.
|
|
505
|
+
newTail.m1b_1 = null;
|
|
567
506
|
}
|
|
568
|
-
oldTail.
|
|
569
|
-
SegmentPool_instance.
|
|
507
|
+
oldTail.n1b_1 = null;
|
|
508
|
+
SegmentPool_instance.a1d(oldTail);
|
|
570
509
|
};
|
|
571
|
-
function readByteString(_this__u8e3s4, byteCount) {
|
|
572
|
-
return UnsafeByteStringOperations_instance.b1e(readByteArray_0(_this__u8e3s4, byteCount));
|
|
573
|
-
}
|
|
574
510
|
function buffered(_this__u8e3s4) {
|
|
575
511
|
return new RealSource(_this__u8e3s4);
|
|
576
512
|
}
|
|
577
513
|
function PeekSource(upstream) {
|
|
578
|
-
this.
|
|
579
|
-
this.
|
|
580
|
-
this.
|
|
514
|
+
this.c1d_1 = upstream;
|
|
515
|
+
this.d1d_1 = this.c1d_1.c1b();
|
|
516
|
+
this.e1d_1 = this.d1d_1.z1a_1;
|
|
581
517
|
var tmp = this;
|
|
582
|
-
var tmp0_safe_receiver = this.
|
|
583
|
-
var tmp0_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.
|
|
584
|
-
tmp.
|
|
585
|
-
this.
|
|
586
|
-
this.
|
|
518
|
+
var tmp0_safe_receiver = this.d1d_1.z1a_1;
|
|
519
|
+
var tmp0_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.i1b_1;
|
|
520
|
+
tmp.f1d_1 = tmp0_elvis_lhs == null ? -1 : tmp0_elvis_lhs;
|
|
521
|
+
this.g1d_1 = false;
|
|
522
|
+
this.h1d_1 = new Long(0, 0);
|
|
587
523
|
}
|
|
588
|
-
protoOf(PeekSource).
|
|
524
|
+
protoOf(PeekSource).c1c = function (sink, byteCount) {
|
|
589
525
|
// Inline function 'kotlin.check' call
|
|
590
|
-
if (!!this.
|
|
526
|
+
if (!!this.g1d_1) {
|
|
591
527
|
// Inline function 'kotlinx.io.PeekSource.readAtMostTo.<anonymous>' call
|
|
592
528
|
var message = 'Source is closed.';
|
|
593
529
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
@@ -600,7 +536,7 @@
|
|
|
600
536
|
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
601
537
|
}
|
|
602
538
|
// Inline function 'kotlin.check' call
|
|
603
|
-
if (!(this.
|
|
539
|
+
if (!(this.e1d_1 == null || (this.e1d_1 === this.d1d_1.z1a_1 && this.f1d_1 === ensureNotNull(this.d1d_1.z1a_1).i1b_1))) {
|
|
604
540
|
// Inline function 'kotlinx.io.PeekSource.readAtMostTo.<anonymous>' call
|
|
605
541
|
var message_1 = 'Peek source is invalid because upstream source was used';
|
|
606
542
|
throw IllegalStateException_init_$Create$(toString(message_1));
|
|
@@ -608,35 +544,35 @@
|
|
|
608
544
|
if (byteCount.equals(new Long(0, 0)))
|
|
609
545
|
return new Long(0, 0);
|
|
610
546
|
// Inline function 'kotlin.Long.plus' call
|
|
611
|
-
var tmp$ret$3 = this.
|
|
612
|
-
if (!this.
|
|
547
|
+
var tmp$ret$3 = this.h1d_1.z2(toLong(1));
|
|
548
|
+
if (!this.c1d_1.f1b(tmp$ret$3))
|
|
613
549
|
return new Long(-1, -1);
|
|
614
|
-
if (this.
|
|
615
|
-
this.
|
|
616
|
-
this.
|
|
550
|
+
if (this.e1d_1 == null && !(this.d1d_1.z1a_1 == null)) {
|
|
551
|
+
this.e1d_1 = this.d1d_1.z1a_1;
|
|
552
|
+
this.f1d_1 = ensureNotNull(this.d1d_1.z1a_1).i1b_1;
|
|
617
553
|
}
|
|
618
554
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
619
|
-
var b = this.
|
|
555
|
+
var b = this.d1d_1.s().a3(this.h1d_1);
|
|
620
556
|
var toCopy = byteCount.e1(b) <= 0 ? byteCount : b;
|
|
621
|
-
this.
|
|
622
|
-
this.
|
|
557
|
+
this.d1d_1.u1b(sink, this.h1d_1, this.h1d_1.z2(toCopy));
|
|
558
|
+
this.h1d_1 = this.h1d_1.z2(toCopy);
|
|
623
559
|
return toCopy;
|
|
624
560
|
};
|
|
625
|
-
protoOf(PeekSource).
|
|
626
|
-
this.
|
|
561
|
+
protoOf(PeekSource).y1c = function () {
|
|
562
|
+
this.g1d_1 = true;
|
|
627
563
|
};
|
|
628
564
|
function RealSource(source) {
|
|
629
|
-
this.
|
|
630
|
-
this.
|
|
631
|
-
this.
|
|
565
|
+
this.i1d_1 = source;
|
|
566
|
+
this.j1d_1 = false;
|
|
567
|
+
this.k1d_1 = new Buffer();
|
|
632
568
|
}
|
|
633
|
-
protoOf(RealSource).
|
|
634
|
-
return this.
|
|
569
|
+
protoOf(RealSource).c1b = function () {
|
|
570
|
+
return this.k1d_1;
|
|
635
571
|
};
|
|
636
|
-
protoOf(RealSource).
|
|
572
|
+
protoOf(RealSource).c1c = function (sink, byteCount) {
|
|
637
573
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed' call
|
|
638
574
|
// Inline function 'kotlin.check' call
|
|
639
|
-
if (!!this.
|
|
575
|
+
if (!!this.j1d_1) {
|
|
640
576
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed.<anonymous>' call
|
|
641
577
|
var message = 'Source is closed.';
|
|
642
578
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
@@ -647,34 +583,34 @@
|
|
|
647
583
|
var message_0 = 'byteCount: ' + byteCount.toString();
|
|
648
584
|
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
649
585
|
}
|
|
650
|
-
if (this.
|
|
651
|
-
var read = this.
|
|
586
|
+
if (this.k1d_1.s().equals(new Long(0, 0))) {
|
|
587
|
+
var read = this.i1d_1.c1c(this.k1d_1, new Long(8192, 0));
|
|
652
588
|
if (read.equals(new Long(-1, -1)))
|
|
653
589
|
return new Long(-1, -1);
|
|
654
590
|
}
|
|
655
591
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
656
|
-
var b = this.
|
|
592
|
+
var b = this.k1d_1.s();
|
|
657
593
|
var toRead = byteCount.e1(b) <= 0 ? byteCount : b;
|
|
658
|
-
return this.
|
|
594
|
+
return this.k1d_1.c1c(sink, toRead);
|
|
659
595
|
};
|
|
660
|
-
protoOf(RealSource).
|
|
596
|
+
protoOf(RealSource).d1b = function () {
|
|
661
597
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed' call
|
|
662
598
|
// Inline function 'kotlin.check' call
|
|
663
|
-
if (!!this.
|
|
599
|
+
if (!!this.j1d_1) {
|
|
664
600
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed.<anonymous>' call
|
|
665
601
|
var message = 'Source is closed.';
|
|
666
602
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
667
603
|
}
|
|
668
|
-
return this.
|
|
604
|
+
return this.k1d_1.d1b() && this.i1d_1.c1c(this.k1d_1, new Long(8192, 0)).equals(new Long(-1, -1));
|
|
669
605
|
};
|
|
670
|
-
protoOf(RealSource).
|
|
671
|
-
if (!this.
|
|
606
|
+
protoOf(RealSource).e1b = function (byteCount) {
|
|
607
|
+
if (!this.f1b(byteCount))
|
|
672
608
|
throw EOFException_init_$Create$_0("Source doesn't contain required number of bytes (" + byteCount.toString() + ').');
|
|
673
609
|
};
|
|
674
|
-
protoOf(RealSource).
|
|
610
|
+
protoOf(RealSource).f1b = function (byteCount) {
|
|
675
611
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed' call
|
|
676
612
|
// Inline function 'kotlin.check' call
|
|
677
|
-
if (!!this.
|
|
613
|
+
if (!!this.j1d_1) {
|
|
678
614
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed.<anonymous>' call
|
|
679
615
|
var message = 'Source is closed.';
|
|
680
616
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
@@ -685,91 +621,87 @@
|
|
|
685
621
|
var message_0 = 'byteCount: ' + byteCount.toString();
|
|
686
622
|
throw IllegalArgumentException_init_$Create$(toString(message_0));
|
|
687
623
|
}
|
|
688
|
-
while (this.
|
|
689
|
-
if (this.
|
|
624
|
+
while (this.k1d_1.s().e1(byteCount) < 0) {
|
|
625
|
+
if (this.i1d_1.c1c(this.k1d_1, new Long(8192, 0)).equals(new Long(-1, -1)))
|
|
690
626
|
return false;
|
|
691
627
|
}
|
|
692
628
|
return true;
|
|
693
629
|
};
|
|
694
|
-
protoOf(RealSource).
|
|
695
|
-
this.h1e(new Long(1, 0));
|
|
696
|
-
return this.o1g_1.j1e();
|
|
697
|
-
};
|
|
698
|
-
protoOf(RealSource).e1f = function (sink, startIndex, endIndex) {
|
|
630
|
+
protoOf(RealSource).a1c = function (sink, startIndex, endIndex) {
|
|
699
631
|
// Inline function 'kotlinx.io.checkBounds' call
|
|
700
632
|
var size = sink.length;
|
|
701
633
|
checkBounds(toLong(size), toLong(startIndex), toLong(endIndex));
|
|
702
|
-
if (this.
|
|
703
|
-
var read = this.
|
|
634
|
+
if (this.k1d_1.s().equals(new Long(0, 0))) {
|
|
635
|
+
var read = this.i1d_1.c1c(this.k1d_1, new Long(8192, 0));
|
|
704
636
|
if (read.equals(new Long(-1, -1)))
|
|
705
637
|
return -1;
|
|
706
638
|
}
|
|
707
639
|
var tmp3 = endIndex - startIndex | 0;
|
|
708
640
|
// Inline function 'kotlinx.io.minOf' call
|
|
709
|
-
var b = this.
|
|
641
|
+
var b = this.k1d_1.s();
|
|
710
642
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
711
643
|
var a = toLong(tmp3);
|
|
712
644
|
var toRead = (a.e1(b) <= 0 ? a : b).j1();
|
|
713
|
-
return this.
|
|
645
|
+
return this.k1d_1.a1c(sink, startIndex, startIndex + toRead | 0);
|
|
714
646
|
};
|
|
715
|
-
protoOf(RealSource).
|
|
647
|
+
protoOf(RealSource).e1c = function (sink, byteCount) {
|
|
716
648
|
try {
|
|
717
|
-
this.
|
|
649
|
+
this.e1b(byteCount);
|
|
718
650
|
} catch ($p) {
|
|
719
651
|
if ($p instanceof EOFException) {
|
|
720
652
|
var e = $p;
|
|
721
|
-
sink.
|
|
653
|
+
sink.d1c(this.k1d_1, this.k1d_1.s());
|
|
722
654
|
throw e;
|
|
723
655
|
} else {
|
|
724
656
|
throw $p;
|
|
725
657
|
}
|
|
726
658
|
}
|
|
727
|
-
this.
|
|
659
|
+
this.k1d_1.e1c(sink, byteCount);
|
|
728
660
|
};
|
|
729
|
-
protoOf(RealSource).
|
|
661
|
+
protoOf(RealSource).f1c = function (sink) {
|
|
730
662
|
var totalBytesWritten = new Long(0, 0);
|
|
731
|
-
while (!this.
|
|
732
|
-
var emitByteCount = this.
|
|
663
|
+
while (!this.i1d_1.c1c(this.k1d_1, new Long(8192, 0)).equals(new Long(-1, -1))) {
|
|
664
|
+
var emitByteCount = this.k1d_1.y1b();
|
|
733
665
|
if (emitByteCount.e1(new Long(0, 0)) > 0) {
|
|
734
666
|
totalBytesWritten = totalBytesWritten.z2(emitByteCount);
|
|
735
|
-
sink.
|
|
667
|
+
sink.d1c(this.k1d_1, emitByteCount);
|
|
736
668
|
}
|
|
737
669
|
}
|
|
738
|
-
if (this.
|
|
739
|
-
totalBytesWritten = totalBytesWritten.z2(this.
|
|
740
|
-
sink.
|
|
670
|
+
if (this.k1d_1.s().e1(new Long(0, 0)) > 0) {
|
|
671
|
+
totalBytesWritten = totalBytesWritten.z2(this.k1d_1.s());
|
|
672
|
+
sink.d1c(this.k1d_1, this.k1d_1.s());
|
|
741
673
|
}
|
|
742
674
|
return totalBytesWritten;
|
|
743
675
|
};
|
|
744
|
-
protoOf(RealSource).
|
|
745
|
-
this.
|
|
746
|
-
return this.
|
|
676
|
+
protoOf(RealSource).r1b = function () {
|
|
677
|
+
this.e1b(new Long(2, 0));
|
|
678
|
+
return this.k1d_1.r1b();
|
|
747
679
|
};
|
|
748
|
-
protoOf(RealSource).
|
|
680
|
+
protoOf(RealSource).g1c = function () {
|
|
749
681
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed' call
|
|
750
682
|
// Inline function 'kotlin.check' call
|
|
751
|
-
if (!!this.
|
|
683
|
+
if (!!this.j1d_1) {
|
|
752
684
|
// Inline function 'kotlinx.io.RealSource.checkNotClosed.<anonymous>' call
|
|
753
685
|
var message = 'Source is closed.';
|
|
754
686
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
755
687
|
}
|
|
756
688
|
return buffered(new PeekSource(this));
|
|
757
689
|
};
|
|
758
|
-
protoOf(RealSource).
|
|
759
|
-
if (this.
|
|
690
|
+
protoOf(RealSource).y1c = function () {
|
|
691
|
+
if (this.j1d_1)
|
|
760
692
|
return Unit_instance;
|
|
761
|
-
this.
|
|
762
|
-
this.
|
|
763
|
-
this.
|
|
693
|
+
this.j1d_1 = true;
|
|
694
|
+
this.i1d_1.y1c();
|
|
695
|
+
this.k1d_1.e2();
|
|
764
696
|
};
|
|
765
697
|
protoOf(RealSource).toString = function () {
|
|
766
|
-
return 'buffered(' + toString(this.
|
|
698
|
+
return 'buffered(' + toString(this.i1d_1) + ')';
|
|
767
699
|
};
|
|
768
700
|
function Segment_init_$Init$($this) {
|
|
769
701
|
Segment.call($this);
|
|
770
|
-
$this.
|
|
771
|
-
$this.
|
|
772
|
-
$this.
|
|
702
|
+
$this.h1b_1 = new Int8Array(8192);
|
|
703
|
+
$this.l1b_1 = true;
|
|
704
|
+
$this.k1b_1 = null;
|
|
773
705
|
return $this;
|
|
774
706
|
}
|
|
775
707
|
function Segment_init_$Create$() {
|
|
@@ -777,90 +709,90 @@
|
|
|
777
709
|
}
|
|
778
710
|
function Segment_init_$Init$_0(data, pos, limit, shareToken, owner, $this) {
|
|
779
711
|
Segment.call($this);
|
|
780
|
-
$this.
|
|
781
|
-
$this.
|
|
782
|
-
$this.
|
|
783
|
-
$this.
|
|
784
|
-
$this.
|
|
712
|
+
$this.h1b_1 = data;
|
|
713
|
+
$this.i1b_1 = pos;
|
|
714
|
+
$this.j1b_1 = limit;
|
|
715
|
+
$this.k1b_1 = shareToken;
|
|
716
|
+
$this.l1b_1 = owner;
|
|
785
717
|
return $this;
|
|
786
718
|
}
|
|
787
719
|
function Segment_init_$Create$_0(data, pos, limit, shareToken, owner) {
|
|
788
720
|
return Segment_init_$Init$_0(data, pos, limit, shareToken, owner, objectCreate(protoOf(Segment)));
|
|
789
721
|
}
|
|
790
722
|
function Companion() {
|
|
791
|
-
this.
|
|
792
|
-
this.
|
|
723
|
+
this.l1d_1 = 8192;
|
|
724
|
+
this.m1d_1 = 1024;
|
|
793
725
|
}
|
|
794
|
-
protoOf(Companion).
|
|
726
|
+
protoOf(Companion).n1d = function () {
|
|
795
727
|
return Segment_init_$Create$();
|
|
796
728
|
};
|
|
797
729
|
var Companion_instance;
|
|
798
730
|
function Companion_getInstance() {
|
|
799
731
|
return Companion_instance;
|
|
800
732
|
}
|
|
801
|
-
protoOf(Segment).
|
|
802
|
-
var tmp1_safe_receiver = this.
|
|
803
|
-
var tmp0_elvis_lhs = tmp1_safe_receiver == null ? null : tmp1_safe_receiver.
|
|
733
|
+
protoOf(Segment).p1c = function () {
|
|
734
|
+
var tmp1_safe_receiver = this.k1b_1;
|
|
735
|
+
var tmp0_elvis_lhs = tmp1_safe_receiver == null ? null : tmp1_safe_receiver.o1d();
|
|
804
736
|
return tmp0_elvis_lhs == null ? false : tmp0_elvis_lhs;
|
|
805
737
|
};
|
|
806
|
-
protoOf(Segment).
|
|
807
|
-
var tmp0_elvis_lhs = this.
|
|
738
|
+
protoOf(Segment).v1b = function () {
|
|
739
|
+
var tmp0_elvis_lhs = this.k1b_1;
|
|
808
740
|
var tmp;
|
|
809
741
|
if (tmp0_elvis_lhs == null) {
|
|
810
742
|
// Inline function 'kotlin.also' call
|
|
811
|
-
var this_0 = SegmentPool_instance.
|
|
743
|
+
var this_0 = SegmentPool_instance.p1d();
|
|
812
744
|
// Inline function 'kotlinx.io.Segment.sharedCopy.<anonymous>' call
|
|
813
|
-
this.
|
|
745
|
+
this.k1b_1 = this_0;
|
|
814
746
|
tmp = this_0;
|
|
815
747
|
} else {
|
|
816
748
|
tmp = tmp0_elvis_lhs;
|
|
817
749
|
}
|
|
818
750
|
var t = tmp;
|
|
819
|
-
var tmp_0 = this.
|
|
820
|
-
var tmp_1 = this.
|
|
751
|
+
var tmp_0 = this.i1b_1;
|
|
752
|
+
var tmp_1 = this.j1b_1;
|
|
821
753
|
// Inline function 'kotlin.also' call
|
|
822
754
|
// Inline function 'kotlinx.io.Segment.sharedCopy.<anonymous>' call
|
|
823
|
-
t.
|
|
824
|
-
return Segment_init_$Create$_0(this.
|
|
755
|
+
t.q1d();
|
|
756
|
+
return Segment_init_$Create$_0(this.h1b_1, tmp_0, tmp_1, t, false);
|
|
825
757
|
};
|
|
826
|
-
protoOf(Segment).
|
|
827
|
-
var result = this.
|
|
828
|
-
if (!(this.
|
|
829
|
-
ensureNotNull(this.
|
|
758
|
+
protoOf(Segment).s1c = function () {
|
|
759
|
+
var result = this.m1b_1;
|
|
760
|
+
if (!(this.n1b_1 == null)) {
|
|
761
|
+
ensureNotNull(this.n1b_1).m1b_1 = this.m1b_1;
|
|
830
762
|
}
|
|
831
|
-
if (!(this.
|
|
832
|
-
ensureNotNull(this.
|
|
763
|
+
if (!(this.m1b_1 == null)) {
|
|
764
|
+
ensureNotNull(this.m1b_1).n1b_1 = this.n1b_1;
|
|
833
765
|
}
|
|
834
|
-
this.
|
|
835
|
-
this.
|
|
766
|
+
this.m1b_1 = null;
|
|
767
|
+
this.n1b_1 = null;
|
|
836
768
|
return result;
|
|
837
769
|
};
|
|
838
|
-
protoOf(Segment).
|
|
839
|
-
segment.
|
|
840
|
-
segment.
|
|
841
|
-
if (!(this.
|
|
842
|
-
ensureNotNull(this.
|
|
770
|
+
protoOf(Segment).w1b = function (segment) {
|
|
771
|
+
segment.n1b_1 = this;
|
|
772
|
+
segment.m1b_1 = this.m1b_1;
|
|
773
|
+
if (!(this.m1b_1 == null)) {
|
|
774
|
+
ensureNotNull(this.m1b_1).n1b_1 = segment;
|
|
843
775
|
}
|
|
844
|
-
this.
|
|
776
|
+
this.m1b_1 = segment;
|
|
845
777
|
return segment;
|
|
846
778
|
};
|
|
847
|
-
protoOf(Segment).
|
|
779
|
+
protoOf(Segment).q1c = function (byteCount) {
|
|
848
780
|
// Inline function 'kotlin.require' call
|
|
849
|
-
if (!(byteCount > 0 && byteCount <= (this.
|
|
781
|
+
if (!(byteCount > 0 && byteCount <= (this.j1b_1 - this.i1b_1 | 0))) {
|
|
850
782
|
// Inline function 'kotlinx.io.Segment.split.<anonymous>' call
|
|
851
783
|
var message = 'byteCount out of range';
|
|
852
784
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
853
785
|
}
|
|
854
786
|
var prefix;
|
|
855
787
|
if (byteCount >= 1024) {
|
|
856
|
-
prefix = this.
|
|
788
|
+
prefix = this.v1b();
|
|
857
789
|
} else {
|
|
858
|
-
prefix = SegmentPool_instance.
|
|
859
|
-
var tmp1 = this.
|
|
860
|
-
var tmp2 = prefix.
|
|
861
|
-
var tmp3 = this.
|
|
790
|
+
prefix = SegmentPool_instance.k1c();
|
|
791
|
+
var tmp1 = this.h1b_1;
|
|
792
|
+
var tmp2 = prefix.h1b_1;
|
|
793
|
+
var tmp3 = this.i1b_1;
|
|
862
794
|
// Inline function 'kotlin.collections.copyInto' call
|
|
863
|
-
var endIndex = this.
|
|
795
|
+
var endIndex = this.i1b_1 + byteCount | 0;
|
|
864
796
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
865
797
|
// Inline function 'kotlin.js.asDynamic' call
|
|
866
798
|
var tmp = tmp1;
|
|
@@ -868,63 +800,63 @@
|
|
|
868
800
|
// Inline function 'kotlin.js.asDynamic' call
|
|
869
801
|
arrayCopy(tmp, tmp2, 0, tmp3, endIndex);
|
|
870
802
|
}
|
|
871
|
-
prefix.
|
|
872
|
-
this.
|
|
873
|
-
if (!(this.
|
|
874
|
-
ensureNotNull(this.
|
|
803
|
+
prefix.j1b_1 = prefix.i1b_1 + byteCount | 0;
|
|
804
|
+
this.i1b_1 = this.i1b_1 + byteCount | 0;
|
|
805
|
+
if (!(this.n1b_1 == null)) {
|
|
806
|
+
ensureNotNull(this.n1b_1).w1b(prefix);
|
|
875
807
|
} else {
|
|
876
|
-
prefix.
|
|
877
|
-
this.
|
|
808
|
+
prefix.m1b_1 = this;
|
|
809
|
+
this.n1b_1 = prefix;
|
|
878
810
|
}
|
|
879
811
|
return prefix;
|
|
880
812
|
};
|
|
881
|
-
protoOf(Segment).
|
|
813
|
+
protoOf(Segment).x1b = function () {
|
|
882
814
|
// Inline function 'kotlin.check' call
|
|
883
|
-
if (!!(this.
|
|
815
|
+
if (!!(this.n1b_1 == null)) {
|
|
884
816
|
// Inline function 'kotlinx.io.Segment.compact.<anonymous>' call
|
|
885
817
|
var message = 'cannot compact';
|
|
886
818
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
887
819
|
}
|
|
888
|
-
if (!ensureNotNull(this.
|
|
820
|
+
if (!ensureNotNull(this.n1b_1).l1b_1)
|
|
889
821
|
return this;
|
|
890
|
-
var byteCount = this.
|
|
891
|
-
var availableByteCount = (8192 - ensureNotNull(this.
|
|
822
|
+
var byteCount = this.j1b_1 - this.i1b_1 | 0;
|
|
823
|
+
var availableByteCount = (8192 - ensureNotNull(this.n1b_1).j1b_1 | 0) + (ensureNotNull(this.n1b_1).p1c() ? 0 : ensureNotNull(this.n1b_1).i1b_1) | 0;
|
|
892
824
|
if (byteCount > availableByteCount)
|
|
893
825
|
return this;
|
|
894
|
-
var predecessor = this.
|
|
895
|
-
this.
|
|
896
|
-
var successor = this.
|
|
826
|
+
var predecessor = this.n1b_1;
|
|
827
|
+
this.r1c(ensureNotNull(predecessor), byteCount);
|
|
828
|
+
var successor = this.s1c();
|
|
897
829
|
// Inline function 'kotlin.check' call
|
|
898
830
|
if (!(successor == null)) {
|
|
899
831
|
throw IllegalStateException_init_$Create$('Check failed.');
|
|
900
832
|
}
|
|
901
|
-
SegmentPool_instance.
|
|
833
|
+
SegmentPool_instance.a1d(this);
|
|
902
834
|
return predecessor;
|
|
903
835
|
};
|
|
904
|
-
protoOf(Segment).
|
|
905
|
-
var _unary__edvuaz = this.
|
|
906
|
-
this.
|
|
907
|
-
this.
|
|
836
|
+
protoOf(Segment).v1c = function (byte) {
|
|
837
|
+
var _unary__edvuaz = this.j1b_1;
|
|
838
|
+
this.j1b_1 = _unary__edvuaz + 1 | 0;
|
|
839
|
+
this.h1b_1[_unary__edvuaz] = byte;
|
|
908
840
|
};
|
|
909
|
-
protoOf(Segment).
|
|
910
|
-
var data = this.
|
|
911
|
-
var limit = this.
|
|
841
|
+
protoOf(Segment).x1c = function (short) {
|
|
842
|
+
var data = this.h1b_1;
|
|
843
|
+
var limit = this.j1b_1;
|
|
912
844
|
var _unary__edvuaz = limit;
|
|
913
845
|
limit = _unary__edvuaz + 1 | 0;
|
|
914
846
|
data[_unary__edvuaz] = toByte((short >>> 8 | 0) & 255);
|
|
915
847
|
var _unary__edvuaz_0 = limit;
|
|
916
848
|
limit = _unary__edvuaz_0 + 1 | 0;
|
|
917
849
|
data[_unary__edvuaz_0] = toByte(short & 255);
|
|
918
|
-
this.
|
|
850
|
+
this.j1b_1 = limit;
|
|
919
851
|
};
|
|
920
|
-
protoOf(Segment).
|
|
921
|
-
var _unary__edvuaz = this.
|
|
922
|
-
this.
|
|
923
|
-
return this.
|
|
852
|
+
protoOf(Segment).q1b = function () {
|
|
853
|
+
var _unary__edvuaz = this.i1b_1;
|
|
854
|
+
this.i1b_1 = _unary__edvuaz + 1 | 0;
|
|
855
|
+
return this.h1b_1[_unary__edvuaz];
|
|
924
856
|
};
|
|
925
|
-
protoOf(Segment).
|
|
926
|
-
var data = this.
|
|
927
|
-
var pos = this.
|
|
857
|
+
protoOf(Segment).s1b = function () {
|
|
858
|
+
var data = this.h1b_1;
|
|
859
|
+
var pos = this.i1b_1;
|
|
928
860
|
var _unary__edvuaz = pos;
|
|
929
861
|
pos = _unary__edvuaz + 1 | 0;
|
|
930
862
|
// Inline function 'kotlinx.io.and' call
|
|
@@ -934,133 +866,133 @@
|
|
|
934
866
|
// Inline function 'kotlinx.io.and' call
|
|
935
867
|
var tmp$ret$1 = data[_unary__edvuaz_0] & 255;
|
|
936
868
|
var s = toShort(tmp | tmp$ret$1);
|
|
937
|
-
this.
|
|
869
|
+
this.i1b_1 = pos;
|
|
938
870
|
return s;
|
|
939
871
|
};
|
|
940
|
-
protoOf(Segment).
|
|
872
|
+
protoOf(Segment).r1c = function (sink, byteCount) {
|
|
941
873
|
// Inline function 'kotlin.check' call
|
|
942
|
-
if (!sink.
|
|
874
|
+
if (!sink.l1b_1) {
|
|
943
875
|
// Inline function 'kotlinx.io.Segment.writeTo.<anonymous>' call
|
|
944
876
|
var message = 'only owner can write';
|
|
945
877
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
946
878
|
}
|
|
947
|
-
if ((sink.
|
|
948
|
-
if (sink.
|
|
879
|
+
if ((sink.j1b_1 + byteCount | 0) > 8192) {
|
|
880
|
+
if (sink.p1c())
|
|
949
881
|
throw IllegalArgumentException_init_$Create$_0();
|
|
950
|
-
if (((sink.
|
|
882
|
+
if (((sink.j1b_1 + byteCount | 0) - sink.i1b_1 | 0) > 8192)
|
|
951
883
|
throw IllegalArgumentException_init_$Create$_0();
|
|
952
|
-
var tmp1 = sink.
|
|
953
|
-
var tmp2 = sink.
|
|
954
|
-
var tmp3 = sink.
|
|
884
|
+
var tmp1 = sink.h1b_1;
|
|
885
|
+
var tmp2 = sink.h1b_1;
|
|
886
|
+
var tmp3 = sink.i1b_1;
|
|
955
887
|
// Inline function 'kotlin.collections.copyInto' call
|
|
956
|
-
var endIndex = sink.
|
|
888
|
+
var endIndex = sink.j1b_1;
|
|
957
889
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
958
890
|
// Inline function 'kotlin.js.asDynamic' call
|
|
959
891
|
var tmp = tmp1;
|
|
960
892
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
961
893
|
// Inline function 'kotlin.js.asDynamic' call
|
|
962
894
|
arrayCopy(tmp, tmp2, 0, tmp3, endIndex);
|
|
963
|
-
sink.
|
|
964
|
-
sink.
|
|
895
|
+
sink.j1b_1 = sink.j1b_1 - sink.i1b_1 | 0;
|
|
896
|
+
sink.i1b_1 = 0;
|
|
965
897
|
}
|
|
966
|
-
var tmp6 = this.
|
|
967
|
-
var tmp7 = sink.
|
|
968
|
-
var tmp8 = sink.
|
|
969
|
-
var tmp9 = this.
|
|
898
|
+
var tmp6 = this.h1b_1;
|
|
899
|
+
var tmp7 = sink.h1b_1;
|
|
900
|
+
var tmp8 = sink.j1b_1;
|
|
901
|
+
var tmp9 = this.i1b_1;
|
|
970
902
|
// Inline function 'kotlin.collections.copyInto' call
|
|
971
|
-
var endIndex_0 = this.
|
|
903
|
+
var endIndex_0 = this.i1b_1 + byteCount | 0;
|
|
972
904
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
973
905
|
// Inline function 'kotlin.js.asDynamic' call
|
|
974
906
|
var tmp_0 = tmp6;
|
|
975
907
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
976
908
|
// Inline function 'kotlin.js.asDynamic' call
|
|
977
909
|
arrayCopy(tmp_0, tmp7, tmp8, tmp9, endIndex_0);
|
|
978
|
-
sink.
|
|
979
|
-
this.
|
|
910
|
+
sink.j1b_1 = sink.j1b_1 + byteCount | 0;
|
|
911
|
+
this.i1b_1 = this.i1b_1 + byteCount | 0;
|
|
980
912
|
};
|
|
981
|
-
protoOf(Segment).
|
|
913
|
+
protoOf(Segment).b1c = function (dst, dstStartOffset, dstEndOffset) {
|
|
982
914
|
var len = dstEndOffset - dstStartOffset | 0;
|
|
983
|
-
var tmp0 = this.
|
|
984
|
-
var tmp3 = this.
|
|
915
|
+
var tmp0 = this.h1b_1;
|
|
916
|
+
var tmp3 = this.i1b_1;
|
|
985
917
|
// Inline function 'kotlin.collections.copyInto' call
|
|
986
|
-
var endIndex = this.
|
|
918
|
+
var endIndex = this.i1b_1 + len | 0;
|
|
987
919
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
988
920
|
// Inline function 'kotlin.js.asDynamic' call
|
|
989
921
|
var tmp = tmp0;
|
|
990
922
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
991
923
|
// Inline function 'kotlin.js.asDynamic' call
|
|
992
924
|
arrayCopy(tmp, dst, dstStartOffset, tmp3, endIndex);
|
|
993
|
-
this.
|
|
925
|
+
this.i1b_1 = this.i1b_1 + len | 0;
|
|
994
926
|
};
|
|
995
|
-
protoOf(Segment).
|
|
996
|
-
var tmp1 = this.
|
|
927
|
+
protoOf(Segment).n1c = function (src, srcStartOffset, srcEndOffset) {
|
|
928
|
+
var tmp1 = this.h1b_1;
|
|
997
929
|
// Inline function 'kotlin.collections.copyInto' call
|
|
998
|
-
var destinationOffset = this.
|
|
930
|
+
var destinationOffset = this.j1b_1;
|
|
999
931
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
1000
932
|
// Inline function 'kotlin.js.asDynamic' call
|
|
1001
933
|
var tmp = src;
|
|
1002
934
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
1003
935
|
// Inline function 'kotlin.js.asDynamic' call
|
|
1004
936
|
arrayCopy(tmp, tmp1, destinationOffset, srcStartOffset, srcEndOffset);
|
|
1005
|
-
this.
|
|
937
|
+
this.j1b_1 = this.j1b_1 + (srcEndOffset - srcStartOffset | 0) | 0;
|
|
1006
938
|
};
|
|
1007
|
-
protoOf(Segment).
|
|
1008
|
-
return this.
|
|
939
|
+
protoOf(Segment).o1b = function () {
|
|
940
|
+
return this.j1b_1 - this.i1b_1 | 0;
|
|
1009
941
|
};
|
|
1010
|
-
protoOf(Segment).
|
|
1011
|
-
return this.
|
|
942
|
+
protoOf(Segment).m1c = function () {
|
|
943
|
+
return this.h1b_1.length - this.j1b_1 | 0;
|
|
1012
944
|
};
|
|
1013
|
-
protoOf(Segment).
|
|
1014
|
-
return this.
|
|
945
|
+
protoOf(Segment).r1d = function (readOnly) {
|
|
946
|
+
return this.h1b_1;
|
|
1015
947
|
};
|
|
1016
|
-
protoOf(Segment).
|
|
1017
|
-
return this.
|
|
948
|
+
protoOf(Segment).s1d = function (index) {
|
|
949
|
+
return this.h1b_1[this.i1b_1 + index | 0];
|
|
1018
950
|
};
|
|
1019
|
-
protoOf(Segment).
|
|
1020
|
-
this.
|
|
951
|
+
protoOf(Segment).t1d = function (index, value) {
|
|
952
|
+
this.h1b_1[this.j1b_1 + index | 0] = value;
|
|
1021
953
|
};
|
|
1022
|
-
protoOf(Segment).
|
|
1023
|
-
var d = this.
|
|
1024
|
-
var l = this.
|
|
954
|
+
protoOf(Segment).u1d = function (index, b0, b1) {
|
|
955
|
+
var d = this.h1b_1;
|
|
956
|
+
var l = this.j1b_1;
|
|
1025
957
|
d[l + index | 0] = b0;
|
|
1026
958
|
d[(l + index | 0) + 1 | 0] = b1;
|
|
1027
959
|
};
|
|
1028
|
-
protoOf(Segment).
|
|
1029
|
-
var d = this.
|
|
1030
|
-
var l = this.
|
|
960
|
+
protoOf(Segment).v1d = function (index, b0, b1, b2) {
|
|
961
|
+
var d = this.h1b_1;
|
|
962
|
+
var l = this.j1b_1;
|
|
1031
963
|
d[l + index | 0] = b0;
|
|
1032
964
|
d[(l + index | 0) + 1 | 0] = b1;
|
|
1033
965
|
d[(l + index | 0) + 2 | 0] = b2;
|
|
1034
966
|
};
|
|
1035
|
-
protoOf(Segment).
|
|
1036
|
-
var d = this.
|
|
1037
|
-
var l = this.
|
|
967
|
+
protoOf(Segment).w1d = function (index, b0, b1, b2, b3) {
|
|
968
|
+
var d = this.h1b_1;
|
|
969
|
+
var l = this.j1b_1;
|
|
1038
970
|
d[l + index | 0] = b0;
|
|
1039
971
|
d[(l + index | 0) + 1 | 0] = b1;
|
|
1040
972
|
d[(l + index | 0) + 2 | 0] = b2;
|
|
1041
973
|
d[(l + index | 0) + 3 | 0] = b3;
|
|
1042
974
|
};
|
|
1043
975
|
function Segment() {
|
|
1044
|
-
this.
|
|
1045
|
-
this.
|
|
1046
|
-
this.
|
|
1047
|
-
this.
|
|
1048
|
-
this.
|
|
1049
|
-
this.
|
|
976
|
+
this.i1b_1 = 0;
|
|
977
|
+
this.j1b_1 = 0;
|
|
978
|
+
this.k1b_1 = null;
|
|
979
|
+
this.l1b_1 = false;
|
|
980
|
+
this.m1b_1 = null;
|
|
981
|
+
this.n1b_1 = null;
|
|
1050
982
|
}
|
|
1051
983
|
function SegmentCopyTracker() {
|
|
1052
984
|
}
|
|
1053
985
|
function isEmpty(_this__u8e3s4) {
|
|
1054
|
-
return _this__u8e3s4.
|
|
986
|
+
return _this__u8e3s4.o1b() === 0;
|
|
1055
987
|
}
|
|
1056
988
|
function AlwaysSharedCopyTracker() {
|
|
1057
989
|
AlwaysSharedCopyTracker_instance = this;
|
|
1058
990
|
SegmentCopyTracker.call(this);
|
|
1059
991
|
}
|
|
1060
|
-
protoOf(AlwaysSharedCopyTracker).
|
|
992
|
+
protoOf(AlwaysSharedCopyTracker).o1d = function () {
|
|
1061
993
|
return true;
|
|
1062
994
|
};
|
|
1063
|
-
protoOf(AlwaysSharedCopyTracker).
|
|
995
|
+
protoOf(AlwaysSharedCopyTracker).q1d = function () {
|
|
1064
996
|
return Unit_instance;
|
|
1065
997
|
};
|
|
1066
998
|
var AlwaysSharedCopyTracker_instance;
|
|
@@ -1080,22 +1012,22 @@
|
|
|
1080
1012
|
var arraySize = size;
|
|
1081
1013
|
if (size === -1) {
|
|
1082
1014
|
var fetchSize = new Long(2147483647, 0);
|
|
1083
|
-
while (_this__u8e3s4.
|
|
1015
|
+
while (_this__u8e3s4.c1b().s().e1(new Long(2147483647, 0)) < 0 && _this__u8e3s4.f1b(fetchSize)) {
|
|
1084
1016
|
// Inline function 'kotlin.Long.times' call
|
|
1085
1017
|
fetchSize = fetchSize.b3(toLong(2));
|
|
1086
1018
|
}
|
|
1087
1019
|
// Inline function 'kotlin.check' call
|
|
1088
|
-
if (!(_this__u8e3s4.
|
|
1020
|
+
if (!(_this__u8e3s4.c1b().s().e1(new Long(2147483647, 0)) < 0)) {
|
|
1089
1021
|
// Inline function 'kotlinx.io.readByteArrayImpl.<anonymous>' call
|
|
1090
|
-
var message = "Can't create an array of size " + _this__u8e3s4.
|
|
1022
|
+
var message = "Can't create an array of size " + _this__u8e3s4.c1b().s().toString();
|
|
1091
1023
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
1092
1024
|
}
|
|
1093
|
-
arraySize = _this__u8e3s4.
|
|
1025
|
+
arraySize = _this__u8e3s4.c1b().s().j1();
|
|
1094
1026
|
} else {
|
|
1095
|
-
_this__u8e3s4.
|
|
1027
|
+
_this__u8e3s4.e1b(toLong(size));
|
|
1096
1028
|
}
|
|
1097
1029
|
var array = new Int8Array(arraySize);
|
|
1098
|
-
readTo(_this__u8e3s4.
|
|
1030
|
+
readTo(_this__u8e3s4.c1b(), array);
|
|
1099
1031
|
return array;
|
|
1100
1032
|
}
|
|
1101
1033
|
function readTo(_this__u8e3s4, sink, startIndex, endIndex) {
|
|
@@ -1106,7 +1038,7 @@
|
|
|
1106
1038
|
checkBounds(toLong(size), toLong(startIndex), toLong(endIndex));
|
|
1107
1039
|
var offset = startIndex;
|
|
1108
1040
|
while (offset < endIndex) {
|
|
1109
|
-
var bytesRead = _this__u8e3s4.
|
|
1041
|
+
var bytesRead = _this__u8e3s4.a1c(sink, offset, endIndex);
|
|
1110
1042
|
if (bytesRead === -1) {
|
|
1111
1043
|
throw EOFException_init_$Create$_0('Source exhausted before reading ' + (endIndex - startIndex | 0) + ' bytes. ' + ('Only ' + bytesRead + ' bytes were read.'));
|
|
1112
1044
|
}
|
|
@@ -1125,36 +1057,33 @@
|
|
|
1125
1057
|
return readByteArrayImpl(_this__u8e3s4, byteCount);
|
|
1126
1058
|
}
|
|
1127
1059
|
function readString(_this__u8e3s4) {
|
|
1128
|
-
_this__u8e3s4.
|
|
1129
|
-
return commonReadUtf8(_this__u8e3s4.
|
|
1060
|
+
_this__u8e3s4.f1b(new Long(-1, 2147483647));
|
|
1061
|
+
return commonReadUtf8(_this__u8e3s4.c1b(), _this__u8e3s4.c1b().s());
|
|
1130
1062
|
}
|
|
1131
1063
|
function readString_0(_this__u8e3s4, byteCount) {
|
|
1132
|
-
_this__u8e3s4.
|
|
1133
|
-
return commonReadUtf8(_this__u8e3s4.
|
|
1134
|
-
}
|
|
1135
|
-
function readString_1(_this__u8e3s4) {
|
|
1136
|
-
return commonReadUtf8(_this__u8e3s4, _this__u8e3s4.s());
|
|
1064
|
+
_this__u8e3s4.e1b(byteCount);
|
|
1065
|
+
return commonReadUtf8(_this__u8e3s4.c1b(), byteCount);
|
|
1137
1066
|
}
|
|
1138
1067
|
function commonReadUtf8(_this__u8e3s4, byteCount) {
|
|
1139
1068
|
if (byteCount.equals(new Long(0, 0)))
|
|
1140
1069
|
return '';
|
|
1141
1070
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.forEachSegment' call
|
|
1142
|
-
var curr = _this__u8e3s4.
|
|
1071
|
+
var curr = _this__u8e3s4.z1a_1;
|
|
1143
1072
|
while (!(curr == null)) {
|
|
1144
1073
|
get_SegmentReadContextImpl();
|
|
1145
1074
|
// Inline function 'kotlinx.io.commonReadUtf8.<anonymous>' call
|
|
1146
|
-
if (toLong(curr.
|
|
1075
|
+
if (toLong(curr.o1b()).e1(byteCount) >= 0) {
|
|
1147
1076
|
var result = '';
|
|
1148
1077
|
// Inline function 'kotlinx.io.unsafe.withData' call
|
|
1149
|
-
var tmp2 = curr.
|
|
1150
|
-
var tmp3 = curr.
|
|
1078
|
+
var tmp2 = curr.r1d(true);
|
|
1079
|
+
var tmp3 = curr.i1b_1;
|
|
1151
1080
|
// Inline function 'kotlinx.io.commonReadUtf8.<anonymous>.<anonymous>' call
|
|
1152
|
-
var tmp0 = curr.
|
|
1081
|
+
var tmp0 = curr.j1b_1;
|
|
1153
1082
|
// Inline function 'kotlin.math.min' call
|
|
1154
1083
|
var b = tmp3 + byteCount.j1() | 0;
|
|
1155
1084
|
var tmp$ret$0 = Math.min(tmp0, b);
|
|
1156
1085
|
result = commonToUtf8String(tmp2, tmp3, tmp$ret$0);
|
|
1157
|
-
_this__u8e3s4.
|
|
1086
|
+
_this__u8e3s4.z1b(byteCount);
|
|
1158
1087
|
return result;
|
|
1159
1088
|
}
|
|
1160
1089
|
return commonToUtf8String(readByteArray_0(_this__u8e3s4, byteCount.j1()));
|
|
@@ -1172,7 +1101,7 @@
|
|
|
1172
1101
|
// Inline function 'kotlinx.io.writeToInternalBuffer' call
|
|
1173
1102
|
// Inline function 'kotlinx.io.writeString.<anonymous>' call
|
|
1174
1103
|
// Inline function 'kotlinx.io.commonWriteUtf8' call
|
|
1175
|
-
var this_0 = _this__u8e3s4.
|
|
1104
|
+
var this_0 = _this__u8e3s4.c1b();
|
|
1176
1105
|
var i = startIndex;
|
|
1177
1106
|
while (i < endIndex) {
|
|
1178
1107
|
// Inline function 'kotlinx.io.writeString.<anonymous>.stub_for_inlining' call
|
|
@@ -1183,16 +1112,16 @@
|
|
|
1183
1112
|
if (c < 128) {
|
|
1184
1113
|
$l$block_0: {
|
|
1185
1114
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail' call
|
|
1186
|
-
var tail = this_0.
|
|
1115
|
+
var tail = this_0.h1c(1);
|
|
1187
1116
|
// Inline function 'kotlinx.io.commonWriteUtf8.<anonymous>' call
|
|
1188
1117
|
var ctx = get_SegmentWriteContextImpl();
|
|
1189
1118
|
var segmentOffset = -i | 0;
|
|
1190
1119
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
1191
|
-
var b = i + tail.
|
|
1120
|
+
var b = i + tail.m1c() | 0;
|
|
1192
1121
|
var runLimit = Math.min(endIndex, b);
|
|
1193
1122
|
var _unary__edvuaz = i;
|
|
1194
1123
|
i = _unary__edvuaz + 1 | 0;
|
|
1195
|
-
ctx.
|
|
1124
|
+
ctx.a1e(tail, segmentOffset + _unary__edvuaz | 0, toByte(c));
|
|
1196
1125
|
$l$loop: while (i < runLimit) {
|
|
1197
1126
|
// Inline function 'kotlinx.io.writeString.<anonymous>.stub_for_inlining' call
|
|
1198
1127
|
var p0_0 = i;
|
|
@@ -1203,94 +1132,94 @@
|
|
|
1203
1132
|
break $l$loop;
|
|
1204
1133
|
var _unary__edvuaz_0 = i;
|
|
1205
1134
|
i = _unary__edvuaz_0 + 1 | 0;
|
|
1206
|
-
ctx.
|
|
1135
|
+
ctx.a1e(tail, segmentOffset + _unary__edvuaz_0 | 0, toByte(c));
|
|
1207
1136
|
}
|
|
1208
1137
|
var bytesWritten = i + segmentOffset | 0;
|
|
1209
1138
|
if (bytesWritten === 1) {
|
|
1210
|
-
tail.
|
|
1139
|
+
tail.j1b_1 = tail.j1b_1 + bytesWritten | 0;
|
|
1211
1140
|
var tmp = this_0;
|
|
1212
1141
|
// Inline function 'kotlin.Long.plus' call
|
|
1213
|
-
tmp.
|
|
1142
|
+
tmp.b1b_1 = this_0.b1b_1.z2(toLong(bytesWritten));
|
|
1214
1143
|
break $l$block_0;
|
|
1215
1144
|
}
|
|
1216
1145
|
// Inline function 'kotlin.check' call
|
|
1217
|
-
if (!(0 <= bytesWritten ? bytesWritten <= tail.
|
|
1146
|
+
if (!(0 <= bytesWritten ? bytesWritten <= tail.m1c() : false)) {
|
|
1218
1147
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail.<anonymous>' call
|
|
1219
|
-
var message = 'Invalid number of bytes written: ' + bytesWritten + '. Should be in 0..' + tail.
|
|
1148
|
+
var message = 'Invalid number of bytes written: ' + bytesWritten + '. Should be in 0..' + tail.m1c();
|
|
1220
1149
|
throw IllegalStateException_init_$Create$(toString(message));
|
|
1221
1150
|
}
|
|
1222
1151
|
if (!(bytesWritten === 0)) {
|
|
1223
|
-
tail.
|
|
1152
|
+
tail.j1b_1 = tail.j1b_1 + bytesWritten | 0;
|
|
1224
1153
|
var tmp_0 = this_0;
|
|
1225
1154
|
// Inline function 'kotlin.Long.plus' call
|
|
1226
|
-
tmp_0.
|
|
1155
|
+
tmp_0.b1b_1 = this_0.b1b_1.z2(toLong(bytesWritten));
|
|
1227
1156
|
break $l$block_0;
|
|
1228
1157
|
}
|
|
1229
1158
|
if (isEmpty(tail)) {
|
|
1230
|
-
this_0.
|
|
1159
|
+
this_0.b1d();
|
|
1231
1160
|
}
|
|
1232
1161
|
}
|
|
1233
1162
|
} else if (c < 2048) {
|
|
1234
1163
|
$l$block_2: {
|
|
1235
1164
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail' call
|
|
1236
|
-
var tail_0 = this_0.
|
|
1165
|
+
var tail_0 = this_0.h1c(2);
|
|
1237
1166
|
// Inline function 'kotlinx.io.commonWriteUtf8.<anonymous>' call
|
|
1238
|
-
get_SegmentWriteContextImpl().
|
|
1167
|
+
get_SegmentWriteContextImpl().z1d(tail_0, 0, toByte(c >> 6 | 192), toByte(c & 63 | 128));
|
|
1239
1168
|
var bytesWritten_0 = 2;
|
|
1240
1169
|
if (bytesWritten_0 === 2) {
|
|
1241
|
-
tail_0.
|
|
1170
|
+
tail_0.j1b_1 = tail_0.j1b_1 + bytesWritten_0 | 0;
|
|
1242
1171
|
var tmp_1 = this_0;
|
|
1243
1172
|
// Inline function 'kotlin.Long.plus' call
|
|
1244
|
-
tmp_1.
|
|
1173
|
+
tmp_1.b1b_1 = this_0.b1b_1.z2(toLong(bytesWritten_0));
|
|
1245
1174
|
break $l$block_2;
|
|
1246
1175
|
}
|
|
1247
1176
|
// Inline function 'kotlin.check' call
|
|
1248
|
-
if (!(0 <= bytesWritten_0 ? bytesWritten_0 <= tail_0.
|
|
1177
|
+
if (!(0 <= bytesWritten_0 ? bytesWritten_0 <= tail_0.m1c() : false)) {
|
|
1249
1178
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail.<anonymous>' call
|
|
1250
|
-
var message_0 = 'Invalid number of bytes written: ' + bytesWritten_0 + '. Should be in 0..' + tail_0.
|
|
1179
|
+
var message_0 = 'Invalid number of bytes written: ' + bytesWritten_0 + '. Should be in 0..' + tail_0.m1c();
|
|
1251
1180
|
throw IllegalStateException_init_$Create$(toString(message_0));
|
|
1252
1181
|
}
|
|
1253
1182
|
if (!(bytesWritten_0 === 0)) {
|
|
1254
|
-
tail_0.
|
|
1183
|
+
tail_0.j1b_1 = tail_0.j1b_1 + bytesWritten_0 | 0;
|
|
1255
1184
|
var tmp_2 = this_0;
|
|
1256
1185
|
// Inline function 'kotlin.Long.plus' call
|
|
1257
|
-
tmp_2.
|
|
1186
|
+
tmp_2.b1b_1 = this_0.b1b_1.z2(toLong(bytesWritten_0));
|
|
1258
1187
|
break $l$block_2;
|
|
1259
1188
|
}
|
|
1260
1189
|
if (isEmpty(tail_0)) {
|
|
1261
|
-
this_0.
|
|
1190
|
+
this_0.b1d();
|
|
1262
1191
|
}
|
|
1263
1192
|
}
|
|
1264
1193
|
i = i + 1 | 0;
|
|
1265
1194
|
} else if (c < 55296 || c > 57343) {
|
|
1266
1195
|
$l$block_4: {
|
|
1267
1196
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail' call
|
|
1268
|
-
var tail_1 = this_0.
|
|
1197
|
+
var tail_1 = this_0.h1c(3);
|
|
1269
1198
|
// Inline function 'kotlinx.io.commonWriteUtf8.<anonymous>' call
|
|
1270
|
-
get_SegmentWriteContextImpl().
|
|
1199
|
+
get_SegmentWriteContextImpl().y1d(tail_1, 0, toByte(c >> 12 | 224), toByte(c >> 6 & 63 | 128), toByte(c & 63 | 128));
|
|
1271
1200
|
var bytesWritten_1 = 3;
|
|
1272
1201
|
if (bytesWritten_1 === 3) {
|
|
1273
|
-
tail_1.
|
|
1202
|
+
tail_1.j1b_1 = tail_1.j1b_1 + bytesWritten_1 | 0;
|
|
1274
1203
|
var tmp_3 = this_0;
|
|
1275
1204
|
// Inline function 'kotlin.Long.plus' call
|
|
1276
|
-
tmp_3.
|
|
1205
|
+
tmp_3.b1b_1 = this_0.b1b_1.z2(toLong(bytesWritten_1));
|
|
1277
1206
|
break $l$block_4;
|
|
1278
1207
|
}
|
|
1279
1208
|
// Inline function 'kotlin.check' call
|
|
1280
|
-
if (!(0 <= bytesWritten_1 ? bytesWritten_1 <= tail_1.
|
|
1209
|
+
if (!(0 <= bytesWritten_1 ? bytesWritten_1 <= tail_1.m1c() : false)) {
|
|
1281
1210
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail.<anonymous>' call
|
|
1282
|
-
var message_1 = 'Invalid number of bytes written: ' + bytesWritten_1 + '. Should be in 0..' + tail_1.
|
|
1211
|
+
var message_1 = 'Invalid number of bytes written: ' + bytesWritten_1 + '. Should be in 0..' + tail_1.m1c();
|
|
1283
1212
|
throw IllegalStateException_init_$Create$(toString(message_1));
|
|
1284
1213
|
}
|
|
1285
1214
|
if (!(bytesWritten_1 === 0)) {
|
|
1286
|
-
tail_1.
|
|
1215
|
+
tail_1.j1b_1 = tail_1.j1b_1 + bytesWritten_1 | 0;
|
|
1287
1216
|
var tmp_4 = this_0;
|
|
1288
1217
|
// Inline function 'kotlin.Long.plus' call
|
|
1289
|
-
tmp_4.
|
|
1218
|
+
tmp_4.b1b_1 = this_0.b1b_1.z2(toLong(bytesWritten_1));
|
|
1290
1219
|
break $l$block_4;
|
|
1291
1220
|
}
|
|
1292
1221
|
if (isEmpty(tail_1)) {
|
|
1293
|
-
this_0.
|
|
1222
|
+
this_0.b1d();
|
|
1294
1223
|
}
|
|
1295
1224
|
}
|
|
1296
1225
|
i = i + 1 | 0;
|
|
@@ -1310,45 +1239,45 @@
|
|
|
1310
1239
|
// Inline function 'kotlin.code' call
|
|
1311
1240
|
var this_4 = _Char___init__impl__6a9atx(63);
|
|
1312
1241
|
var tmp$ret$23 = Char__toInt_impl_vasixd(this_4);
|
|
1313
|
-
this_0.
|
|
1242
|
+
this_0.u1c(toByte(tmp$ret$23));
|
|
1314
1243
|
i = i + 1 | 0;
|
|
1315
1244
|
} else {
|
|
1316
1245
|
var codePoint = 65536 + ((c & 1023) << 10 | low & 1023) | 0;
|
|
1317
1246
|
$l$block_6: {
|
|
1318
1247
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail' call
|
|
1319
|
-
var tail_2 = this_0.
|
|
1248
|
+
var tail_2 = this_0.h1c(4);
|
|
1320
1249
|
// Inline function 'kotlinx.io.commonWriteUtf8.<anonymous>' call
|
|
1321
|
-
get_SegmentWriteContextImpl().
|
|
1250
|
+
get_SegmentWriteContextImpl().x1d(tail_2, 0, toByte(codePoint >> 18 | 240), toByte(codePoint >> 12 & 63 | 128), toByte(codePoint >> 6 & 63 | 128), toByte(codePoint & 63 | 128));
|
|
1322
1251
|
var bytesWritten_2 = 4;
|
|
1323
1252
|
if (bytesWritten_2 === 4) {
|
|
1324
|
-
tail_2.
|
|
1253
|
+
tail_2.j1b_1 = tail_2.j1b_1 + bytesWritten_2 | 0;
|
|
1325
1254
|
var tmp_6 = this_0;
|
|
1326
1255
|
// Inline function 'kotlin.Long.plus' call
|
|
1327
|
-
tmp_6.
|
|
1256
|
+
tmp_6.b1b_1 = this_0.b1b_1.z2(toLong(bytesWritten_2));
|
|
1328
1257
|
break $l$block_6;
|
|
1329
1258
|
}
|
|
1330
1259
|
// Inline function 'kotlin.check' call
|
|
1331
|
-
if (!(0 <= bytesWritten_2 ? bytesWritten_2 <= tail_2.
|
|
1260
|
+
if (!(0 <= bytesWritten_2 ? bytesWritten_2 <= tail_2.m1c() : false)) {
|
|
1332
1261
|
// Inline function 'kotlinx.io.unsafe.UnsafeBufferOperations.writeToTail.<anonymous>' call
|
|
1333
|
-
var message_2 = 'Invalid number of bytes written: ' + bytesWritten_2 + '. Should be in 0..' + tail_2.
|
|
1262
|
+
var message_2 = 'Invalid number of bytes written: ' + bytesWritten_2 + '. Should be in 0..' + tail_2.m1c();
|
|
1334
1263
|
throw IllegalStateException_init_$Create$(toString(message_2));
|
|
1335
1264
|
}
|
|
1336
1265
|
if (!(bytesWritten_2 === 0)) {
|
|
1337
|
-
tail_2.
|
|
1266
|
+
tail_2.j1b_1 = tail_2.j1b_1 + bytesWritten_2 | 0;
|
|
1338
1267
|
var tmp_7 = this_0;
|
|
1339
1268
|
// Inline function 'kotlin.Long.plus' call
|
|
1340
|
-
tmp_7.
|
|
1269
|
+
tmp_7.b1b_1 = this_0.b1b_1.z2(toLong(bytesWritten_2));
|
|
1341
1270
|
break $l$block_6;
|
|
1342
1271
|
}
|
|
1343
1272
|
if (isEmpty(tail_2)) {
|
|
1344
|
-
this_0.
|
|
1273
|
+
this_0.b1d();
|
|
1345
1274
|
}
|
|
1346
1275
|
}
|
|
1347
1276
|
i = i + 2 | 0;
|
|
1348
1277
|
}
|
|
1349
1278
|
}
|
|
1350
1279
|
}
|
|
1351
|
-
_this__u8e3s4.
|
|
1280
|
+
_this__u8e3s4.t1b();
|
|
1352
1281
|
}
|
|
1353
1282
|
function commonToUtf8String(_this__u8e3s4, beginIndex, endIndex) {
|
|
1354
1283
|
beginIndex = beginIndex === VOID ? 0 : beginIndex;
|
|
@@ -1767,27 +1696,27 @@
|
|
|
1767
1696
|
}
|
|
1768
1697
|
function SegmentReadContextImpl$1() {
|
|
1769
1698
|
}
|
|
1770
|
-
protoOf(SegmentReadContextImpl$1).
|
|
1771
|
-
return segment.
|
|
1699
|
+
protoOf(SegmentReadContextImpl$1).z1c = function (segment, offset) {
|
|
1700
|
+
return segment.s1d(offset);
|
|
1772
1701
|
};
|
|
1773
1702
|
function SegmentWriteContextImpl$1() {
|
|
1774
1703
|
}
|
|
1775
|
-
protoOf(SegmentWriteContextImpl$1).
|
|
1776
|
-
segment.
|
|
1704
|
+
protoOf(SegmentWriteContextImpl$1).a1e = function (segment, offset, value) {
|
|
1705
|
+
segment.t1d(offset, value);
|
|
1777
1706
|
};
|
|
1778
|
-
protoOf(SegmentWriteContextImpl$1).
|
|
1779
|
-
segment.
|
|
1707
|
+
protoOf(SegmentWriteContextImpl$1).z1d = function (segment, offset, b0, b1) {
|
|
1708
|
+
segment.u1d(offset, b0, b1);
|
|
1780
1709
|
};
|
|
1781
|
-
protoOf(SegmentWriteContextImpl$1).
|
|
1782
|
-
segment.
|
|
1710
|
+
protoOf(SegmentWriteContextImpl$1).y1d = function (segment, offset, b0, b1, b2) {
|
|
1711
|
+
segment.v1d(offset, b0, b1, b2);
|
|
1783
1712
|
};
|
|
1784
|
-
protoOf(SegmentWriteContextImpl$1).
|
|
1785
|
-
segment.
|
|
1713
|
+
protoOf(SegmentWriteContextImpl$1).x1d = function (segment, offset, b0, b1, b2, b3) {
|
|
1714
|
+
segment.w1d(offset, b0, b1, b2, b3);
|
|
1786
1715
|
};
|
|
1787
1716
|
function BufferIterationContextImpl$1() {
|
|
1788
1717
|
}
|
|
1789
|
-
protoOf(BufferIterationContextImpl$1).
|
|
1790
|
-
return get_SegmentReadContextImpl().
|
|
1718
|
+
protoOf(BufferIterationContextImpl$1).z1c = function (segment, offset) {
|
|
1719
|
+
return get_SegmentReadContextImpl().z1c(segment, offset);
|
|
1791
1720
|
};
|
|
1792
1721
|
var properties_initialized_UnsafeBufferOperations_kt_2xfgoc;
|
|
1793
1722
|
function _init_properties_UnsafeBufferOperations_kt__xw75gy() {
|
|
@@ -1855,15 +1784,15 @@
|
|
|
1855
1784
|
captureStack(this, EOFException);
|
|
1856
1785
|
}
|
|
1857
1786
|
function SegmentPool() {
|
|
1858
|
-
this.
|
|
1859
|
-
this.
|
|
1787
|
+
this.i1c_1 = 0;
|
|
1788
|
+
this.j1c_1 = 0;
|
|
1860
1789
|
}
|
|
1861
|
-
protoOf(SegmentPool).
|
|
1862
|
-
return Companion_instance.
|
|
1790
|
+
protoOf(SegmentPool).k1c = function () {
|
|
1791
|
+
return Companion_instance.n1d();
|
|
1863
1792
|
};
|
|
1864
|
-
protoOf(SegmentPool).
|
|
1793
|
+
protoOf(SegmentPool).a1d = function (segment) {
|
|
1865
1794
|
};
|
|
1866
|
-
protoOf(SegmentPool).
|
|
1795
|
+
protoOf(SegmentPool).p1d = function () {
|
|
1867
1796
|
return AlwaysSharedCopyTracker_getInstance();
|
|
1868
1797
|
};
|
|
1869
1798
|
var SegmentPool_instance;
|
|
@@ -1871,7 +1800,7 @@
|
|
|
1871
1800
|
return SegmentPool_instance;
|
|
1872
1801
|
}
|
|
1873
1802
|
//region block: post-declaration
|
|
1874
|
-
protoOf(Buffer).
|
|
1803
|
+
protoOf(Buffer).o1c = write$default;
|
|
1875
1804
|
//endregion
|
|
1876
1805
|
//region block: init
|
|
1877
1806
|
Companion_instance = new Companion();
|
|
@@ -1890,11 +1819,9 @@
|
|
|
1890
1819
|
_.$_$.h = Source;
|
|
1891
1820
|
_.$_$.i = readByteArray_0;
|
|
1892
1821
|
_.$_$.j = readByteArray;
|
|
1893
|
-
_.$_$.k =
|
|
1894
|
-
_.$_$.l =
|
|
1895
|
-
_.$_$.m =
|
|
1896
|
-
_.$_$.n = readString_1;
|
|
1897
|
-
_.$_$.o = writeString;
|
|
1822
|
+
_.$_$.k = readString;
|
|
1823
|
+
_.$_$.l = readString_0;
|
|
1824
|
+
_.$_$.m = writeString;
|
|
1898
1825
|
//endregion
|
|
1899
1826
|
return _;
|
|
1900
|
-
}(module.exports, require('./kotlin-kotlin-stdlib.js')
|
|
1827
|
+
}(module.exports, require('./kotlin-kotlin-stdlib.js')));
|