@doordeck/doordeck-headless-sdk 0.45.0 → 0.46.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/kotlin/Kotlin-DateTime-library-kotlinx-datetime.js +1394 -1464
- package/kotlin/KotlinMultiplatformLibsodium-multiplatform-crypto-libsodium-bindings.js +19 -21
- package/kotlin/MultiplatformSettings-multiplatform-settings.js +6 -8
- package/kotlin/Stately-stately-concurrency.js +6 -8
- package/kotlin/Stately-stately-concurrent-collections.js +53 -55
- package/kotlin/Stately-stately-strict.js +0 -2
- package/kotlin/doordeck-sdk.js +11742 -11209
- package/kotlin/kotlin-kotlin-stdlib.js +1932 -1918
- package/kotlin/kotlin-kotlinx-atomicfu-runtime.js +0 -2
- package/kotlin/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js +0 -2
- package/kotlin/kotlinx-atomicfu.js +13 -15
- package/kotlin/kotlinx-coroutines-core.js +2056 -2094
- package/kotlin/kotlinx-io-kotlinx-io-bytestring.js +0 -2
- package/kotlin/kotlinx-io-kotlinx-io-core.js +559 -550
- package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js +1849 -1872
- package/kotlin/kotlinx-serialization-kotlinx-serialization-json-io.js +0 -2
- package/kotlin/kotlinx-serialization-kotlinx-serialization-json.js +1523 -1523
- package/kotlin/ktor-ktor-client-ktor-client-core.js +2832 -2843
- package/kotlin/ktor-ktor-client-ktor-client-js.js +0 -2
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-auth.js +388 -391
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-content-negotiation.js +198 -199
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-encoding.js +0 -2
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-logging.js +0 -2
- package/kotlin/ktor-ktor-http.js +833 -860
- package/kotlin/ktor-ktor-io.js +641 -653
- package/kotlin/ktor-ktor-shared-ktor-events.js +7 -10
- package/kotlin/ktor-ktor-shared-ktor-serialization-ktor-serialization-kotlinx-ktor-serialization-kotlinx-json.js +7 -9
- package/kotlin/ktor-ktor-shared-ktor-serialization-ktor-serialization-kotlinx.js +266 -263
- package/kotlin/ktor-ktor-shared-ktor-serialization.js +113 -111
- package/kotlin/ktor-ktor-shared-ktor-sse.js +0 -2
- package/kotlin/ktor-ktor-shared-ktor-websocket-serialization.js +0 -2
- package/kotlin/ktor-ktor-shared-ktor-websockets.js +46 -46
- package/kotlin/ktor-ktor-utils.js +590 -606
- package/kotlin/projects-core-koin-core.js +299 -316
- package/package.json +4 -3
- package/kotlin/Kotlin-DateTime-library-kotlinx-datetime.js.map +0 -1
- package/kotlin/KotlinMultiplatformLibsodium-multiplatform-crypto-libsodium-bindings.js.map +0 -1
- package/kotlin/MultiplatformSettings-multiplatform-settings.js.map +0 -1
- package/kotlin/Stately-stately-concurrency.js.map +0 -1
- package/kotlin/Stately-stately-concurrent-collections.js.map +0 -1
- package/kotlin/Stately-stately-strict.js.map +0 -1
- package/kotlin/doordeck-sdk.js.map +0 -1
- package/kotlin/kotlin-kotlin-stdlib.js.map +0 -1
- package/kotlin/kotlin-kotlinx-atomicfu-runtime.js.map +0 -1
- package/kotlin/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js.map +0 -1
- package/kotlin/kotlinx-atomicfu.js.map +0 -1
- package/kotlin/kotlinx-coroutines-core.js.map +0 -1
- package/kotlin/kotlinx-io-kotlinx-io-bytestring.js.map +0 -1
- package/kotlin/kotlinx-io-kotlinx-io-core.js.map +0 -1
- package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js.map +0 -1
- package/kotlin/kotlinx-serialization-kotlinx-serialization-json-io.js.map +0 -1
- package/kotlin/kotlinx-serialization-kotlinx-serialization-json.js.map +0 -1
- package/kotlin/ktor-ktor-client-ktor-client-core.js.map +0 -1
- package/kotlin/ktor-ktor-client-ktor-client-js.js.map +0 -1
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-auth.js.map +0 -1
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-content-negotiation.js.map +0 -1
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-encoding.js.map +0 -1
- package/kotlin/ktor-ktor-client-ktor-client-plugins-ktor-client-logging.js.map +0 -1
- package/kotlin/ktor-ktor-http.js.map +0 -1
- package/kotlin/ktor-ktor-io.js.map +0 -1
- package/kotlin/ktor-ktor-shared-ktor-events.js.map +0 -1
- package/kotlin/ktor-ktor-shared-ktor-serialization-ktor-serialization-kotlinx-ktor-serialization-kotlinx-json.js.map +0 -1
- package/kotlin/ktor-ktor-shared-ktor-serialization-ktor-serialization-kotlinx.js.map +0 -1
- package/kotlin/ktor-ktor-shared-ktor-serialization.js.map +0 -1
- package/kotlin/ktor-ktor-shared-ktor-sse.js.map +0 -1
- package/kotlin/ktor-ktor-shared-ktor-websocket-serialization.js.map +0 -1
- package/kotlin/ktor-ktor-shared-ktor-websockets.js.map +0 -1
- package/kotlin/ktor-ktor-utils.js.map +0 -1
- package/kotlin/projects-core-koin-core.js.map +0 -1
package/kotlin/ktor-ktor-io.js
CHANGED
|
@@ -51,12 +51,12 @@
|
|
|
51
51
|
var CancellationException = kotlin_kotlin.$_$.b9;
|
|
52
52
|
var readString = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.k;
|
|
53
53
|
var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.i1;
|
|
54
|
-
var toString_0 = kotlin_kotlin.$_$.tb;
|
|
55
54
|
var IllegalStateException_init_$Create$ = kotlin_kotlin.$_$.a2;
|
|
56
55
|
var charSequenceLength = kotlin_kotlin.$_$.ea;
|
|
57
56
|
var readByteArray = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.i;
|
|
58
57
|
var readString_0 = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.l;
|
|
59
58
|
var encodeToByteArray = kotlin_kotlin.$_$.oc;
|
|
59
|
+
var toString_0 = kotlin_kotlin.$_$.tb;
|
|
60
60
|
var writeString = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.m;
|
|
61
61
|
var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.t2;
|
|
62
62
|
var replace = kotlin_kotlin.$_$.gd;
|
|
@@ -79,23 +79,22 @@
|
|
|
79
79
|
initMetadataForObject(Empty, 'Empty');
|
|
80
80
|
initMetadataForClass(Closed, 'Closed');
|
|
81
81
|
function resume() {
|
|
82
|
-
return this.
|
|
82
|
+
return this.w1e().p9(Companion_getInstance().u1e_1);
|
|
83
83
|
}
|
|
84
84
|
function resume_0(throwable) {
|
|
85
|
-
var tmp = this.
|
|
85
|
+
var tmp = this.w1e();
|
|
86
86
|
var tmp_0;
|
|
87
87
|
if (throwable == null) {
|
|
88
88
|
tmp_0 = null;
|
|
89
89
|
} else {
|
|
90
90
|
// Inline function 'kotlin.let' call
|
|
91
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
92
91
|
// Inline function 'io.ktor.utils.io.Task.resume.<anonymous>' call
|
|
93
92
|
// Inline function 'kotlin.Companion.failure' call
|
|
94
93
|
var tmp$ret$2 = _Result___init__impl__xyqfz8(createFailure(throwable));
|
|
95
94
|
tmp_0 = new Result(tmp$ret$2);
|
|
96
95
|
}
|
|
97
96
|
var tmp1_elvis_lhs = tmp_0;
|
|
98
|
-
return tmp.
|
|
97
|
+
return tmp.p9(tmp1_elvis_lhs == null ? Companion_getInstance().u1e_1 : tmp1_elvis_lhs.xk_1);
|
|
99
98
|
}
|
|
100
99
|
initMetadataForInterface(Task, 'Task');
|
|
101
100
|
initMetadataForClass(Read, 'Read', VOID, VOID, [Task]);
|
|
@@ -105,7 +104,7 @@
|
|
|
105
104
|
initMetadataForCoroutine($flushAndCloseCOROUTINE$2, CoroutineImpl);
|
|
106
105
|
function awaitContent$default(min, $completion, $super) {
|
|
107
106
|
min = min === VOID ? 1 : min;
|
|
108
|
-
return $super === VOID ? this.
|
|
107
|
+
return $super === VOID ? this.e1h(min, $completion) : $super.e1h.call(this, min, $completion);
|
|
109
108
|
}
|
|
110
109
|
initMetadataForInterface(ByteReadChannel_1, 'ByteReadChannel', VOID, VOID, VOID, [1]);
|
|
111
110
|
initMetadataForClass(ByteChannel, 'ByteChannel', ByteChannel, VOID, [ByteReadChannel_1], [1, 0]);
|
|
@@ -142,10 +141,10 @@
|
|
|
142
141
|
//endregion
|
|
143
142
|
function Companion() {
|
|
144
143
|
Companion_instance_0 = this;
|
|
145
|
-
this.
|
|
144
|
+
this.t1e_1 = new Closed(null);
|
|
146
145
|
var tmp = this;
|
|
147
146
|
// Inline function 'kotlin.Companion.success' call
|
|
148
|
-
tmp.
|
|
147
|
+
tmp.u1e_1 = _Result___init__impl__xyqfz8(Unit_instance);
|
|
149
148
|
}
|
|
150
149
|
var Companion_instance_0;
|
|
151
150
|
function Companion_getInstance() {
|
|
@@ -174,13 +173,13 @@
|
|
|
174
173
|
return Empty_instance;
|
|
175
174
|
}
|
|
176
175
|
function Closed(cause) {
|
|
177
|
-
this.
|
|
176
|
+
this.v1e_1 = cause;
|
|
178
177
|
}
|
|
179
178
|
protoOf(Closed).toString = function () {
|
|
180
|
-
return 'Closed(cause=' + toString(this.
|
|
179
|
+
return 'Closed(cause=' + toString(this.v1e_1) + ')';
|
|
181
180
|
};
|
|
182
181
|
protoOf(Closed).hashCode = function () {
|
|
183
|
-
return this.
|
|
182
|
+
return this.v1e_1 == null ? 0 : hashCode(this.v1e_1);
|
|
184
183
|
};
|
|
185
184
|
protoOf(Closed).equals = function (other) {
|
|
186
185
|
if (this === other)
|
|
@@ -188,101 +187,103 @@
|
|
|
188
187
|
if (!(other instanceof Closed))
|
|
189
188
|
return false;
|
|
190
189
|
var tmp0_other_with_cast = other instanceof Closed ? other : THROW_CCE();
|
|
191
|
-
if (!equals(this.
|
|
190
|
+
if (!equals(this.v1e_1, tmp0_other_with_cast.v1e_1))
|
|
192
191
|
return false;
|
|
193
192
|
return true;
|
|
194
193
|
};
|
|
195
194
|
function Task() {
|
|
196
195
|
}
|
|
197
196
|
function Read(continuation) {
|
|
198
|
-
this.
|
|
197
|
+
this.a1f_1 = continuation;
|
|
199
198
|
}
|
|
200
|
-
protoOf(Read).
|
|
201
|
-
return this.
|
|
199
|
+
protoOf(Read).w1e = function () {
|
|
200
|
+
return this.a1f_1;
|
|
202
201
|
};
|
|
203
|
-
protoOf(Read).
|
|
202
|
+
protoOf(Read).x1e = function () {
|
|
204
203
|
return 'read';
|
|
205
204
|
};
|
|
206
205
|
function Write(continuation) {
|
|
207
|
-
this.
|
|
206
|
+
this.b1f_1 = continuation;
|
|
208
207
|
}
|
|
209
|
-
protoOf(Write).
|
|
210
|
-
return this.
|
|
208
|
+
protoOf(Write).w1e = function () {
|
|
209
|
+
return this.b1f_1;
|
|
211
210
|
};
|
|
212
|
-
protoOf(Write).
|
|
211
|
+
protoOf(Write).x1e = function () {
|
|
213
212
|
return 'write';
|
|
214
213
|
};
|
|
215
214
|
function moveFlushToReadBuffer($this) {
|
|
216
215
|
// Inline function 'io.ktor.utils.io.locks.synchronized' call
|
|
217
|
-
$this.
|
|
218
|
-
|
|
219
|
-
$this.
|
|
216
|
+
$this.f1f_1;
|
|
217
|
+
// Inline function 'io.ktor.utils.io.ByteChannel.moveFlushToReadBuffer.<anonymous>' call
|
|
218
|
+
$this.d1f_1.x1c($this.h1f_1);
|
|
219
|
+
$this.e1f_1 = 0;
|
|
220
220
|
// Inline function 'io.ktor.utils.io.ByteChannel.resumeSlot' call
|
|
221
|
-
var current = $this.
|
|
221
|
+
var current = $this.g1f_1.kotlinx$atomicfu$value;
|
|
222
222
|
var tmp;
|
|
223
223
|
if (current instanceof Write) {
|
|
224
|
-
tmp = $this.
|
|
224
|
+
tmp = $this.g1f_1.atomicfu$compareAndSet(current, Empty_instance);
|
|
225
225
|
} else {
|
|
226
226
|
tmp = false;
|
|
227
227
|
}
|
|
228
228
|
if (tmp) {
|
|
229
|
-
current.
|
|
229
|
+
current.y1e();
|
|
230
230
|
}
|
|
231
231
|
}
|
|
232
232
|
function closeSlot($this, cause) {
|
|
233
|
-
var closeContinuation = !(cause == null) ? new Closed(cause) : Companion_getInstance().
|
|
234
|
-
var continuation = $this.
|
|
233
|
+
var closeContinuation = !(cause == null) ? new Closed(cause) : Companion_getInstance().t1e_1;
|
|
234
|
+
var continuation = $this.g1f_1.atomicfu$getAndSet(closeContinuation);
|
|
235
235
|
if (!isInterface(continuation, Task))
|
|
236
236
|
return Unit_instance;
|
|
237
|
-
continuation.
|
|
237
|
+
continuation.z1e(cause);
|
|
238
238
|
}
|
|
239
239
|
function $awaitContentCOROUTINE$0(_this__u8e3s4, min, resultContinuation) {
|
|
240
240
|
CoroutineImpl.call(this, resultContinuation);
|
|
241
|
-
this.
|
|
242
|
-
this.
|
|
241
|
+
this.s1f_1 = _this__u8e3s4;
|
|
242
|
+
this.t1f_1 = min;
|
|
243
243
|
}
|
|
244
|
-
protoOf($awaitContentCOROUTINE$0).
|
|
245
|
-
var suspendResult = this.
|
|
244
|
+
protoOf($awaitContentCOROUTINE$0).m9 = function () {
|
|
245
|
+
var suspendResult = this.g9_1;
|
|
246
246
|
$sm: do
|
|
247
247
|
try {
|
|
248
|
-
var tmp = this.
|
|
248
|
+
var tmp = this.e9_1;
|
|
249
249
|
switch (tmp) {
|
|
250
250
|
case 0:
|
|
251
|
-
this.
|
|
252
|
-
rethrowCloseCauseIfNeeded_1(this.
|
|
253
|
-
if (numberToLong(this.
|
|
251
|
+
this.f9_1 = 4;
|
|
252
|
+
rethrowCloseCauseIfNeeded_1(this.s1f_1);
|
|
253
|
+
if (numberToLong(this.s1f_1.e1f_1).z2(this.s1f_1.h1f_1.s()).e1(toLong(this.t1f_1)) >= 0)
|
|
254
254
|
return true;
|
|
255
255
|
var tmp_0 = this;
|
|
256
|
-
tmp_0.
|
|
257
|
-
this.
|
|
256
|
+
tmp_0.u1f_1 = this.s1f_1;
|
|
257
|
+
this.v1f_1 = this.u1f_1;
|
|
258
|
+
this.e9_1 = 1;
|
|
258
259
|
continue $sm;
|
|
259
260
|
case 1:
|
|
260
|
-
if (!(numberToLong(this.
|
|
261
|
-
this.
|
|
261
|
+
if (!(numberToLong(this.s1f_1.e1f_1).z2(this.s1f_1.h1f_1.s()).e1(toLong(this.t1f_1)) < 0 && this.s1f_1.j1f_1.kotlinx$atomicfu$value == null)) {
|
|
262
|
+
this.e9_1 = 3;
|
|
262
263
|
continue $sm;
|
|
263
264
|
}
|
|
264
265
|
|
|
265
|
-
this.
|
|
266
|
+
this.e9_1 = 2;
|
|
266
267
|
var cancellable = new CancellableContinuationImpl(intercepted(this), 1);
|
|
267
|
-
cancellable.
|
|
268
|
+
cancellable.qs();
|
|
269
|
+
var tmp0 = this.v1f_1;
|
|
270
|
+
var tmp1 = new Read(cancellable);
|
|
268
271
|
l$ret$1: do {
|
|
269
|
-
var
|
|
270
|
-
var slot = new Read(cancellable);
|
|
271
|
-
var previous = this_0.f1e_1.kotlinx$atomicfu$value;
|
|
272
|
+
var previous = tmp0.g1f_1.kotlinx$atomicfu$value;
|
|
272
273
|
if (!(previous instanceof Closed)) {
|
|
273
|
-
if (!
|
|
274
|
-
|
|
274
|
+
if (!tmp0.g1f_1.atomicfu$compareAndSet(previous, tmp1)) {
|
|
275
|
+
tmp1.y1e();
|
|
275
276
|
break l$ret$1;
|
|
276
277
|
}
|
|
277
278
|
}
|
|
278
279
|
if (previous instanceof Read) {
|
|
279
|
-
previous.
|
|
280
|
+
previous.z1e(new ConcurrentIOException(tmp1.x1e()));
|
|
280
281
|
} else {
|
|
281
282
|
if (isInterface(previous, Task)) {
|
|
282
|
-
previous.
|
|
283
|
+
previous.y1e();
|
|
283
284
|
} else {
|
|
284
285
|
if (previous instanceof Closed) {
|
|
285
|
-
|
|
286
|
+
tmp1.z1e(previous.v1e_1);
|
|
286
287
|
break l$ret$1;
|
|
287
288
|
} else {
|
|
288
289
|
if (!equals(previous, Empty_instance)) {
|
|
@@ -291,96 +292,97 @@
|
|
|
291
292
|
}
|
|
292
293
|
}
|
|
293
294
|
}
|
|
294
|
-
if (!(numberToLong(this.
|
|
295
|
-
var current =
|
|
295
|
+
if (!(numberToLong(this.s1f_1.e1f_1).z2(this.s1f_1.h1f_1.s()).e1(toLong(this.t1f_1)) < 0 && this.s1f_1.j1f_1.kotlinx$atomicfu$value == null)) {
|
|
296
|
+
var current = tmp0.g1f_1.kotlinx$atomicfu$value;
|
|
296
297
|
var tmp_1;
|
|
297
298
|
if (current instanceof Read) {
|
|
298
|
-
tmp_1 =
|
|
299
|
+
tmp_1 = tmp0.g1f_1.atomicfu$compareAndSet(current, Empty_instance);
|
|
299
300
|
} else {
|
|
300
301
|
tmp_1 = false;
|
|
301
302
|
}
|
|
302
303
|
if (tmp_1) {
|
|
303
|
-
current.
|
|
304
|
+
current.y1e();
|
|
304
305
|
}
|
|
305
306
|
}
|
|
306
307
|
}
|
|
307
308
|
while (false);
|
|
308
|
-
suspendResult = returnIfSuspended(cancellable.
|
|
309
|
+
suspendResult = returnIfSuspended(cancellable.ys(), this);
|
|
309
310
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
310
311
|
return suspendResult;
|
|
311
312
|
}
|
|
312
313
|
|
|
313
314
|
continue $sm;
|
|
314
315
|
case 2:
|
|
315
|
-
this.
|
|
316
|
+
this.e9_1 = 1;
|
|
316
317
|
continue $sm;
|
|
317
318
|
case 3:
|
|
318
|
-
if (this.
|
|
319
|
-
moveFlushToReadBuffer(this.
|
|
319
|
+
if (this.s1f_1.h1f_1.s().e1(new Long(1048576, 0)) < 0) {
|
|
320
|
+
moveFlushToReadBuffer(this.s1f_1);
|
|
320
321
|
}
|
|
321
322
|
|
|
322
|
-
return this.
|
|
323
|
+
return this.s1f_1.h1f_1.s().e1(toLong(this.t1f_1)) >= 0;
|
|
323
324
|
case 4:
|
|
324
|
-
throw this.
|
|
325
|
+
throw this.h9_1;
|
|
325
326
|
}
|
|
326
327
|
} catch ($p) {
|
|
327
328
|
var e = $p;
|
|
328
|
-
if (this.
|
|
329
|
+
if (this.f9_1 === 4) {
|
|
329
330
|
throw e;
|
|
330
331
|
} else {
|
|
331
|
-
this.
|
|
332
|
-
this.
|
|
332
|
+
this.e9_1 = this.f9_1;
|
|
333
|
+
this.h9_1 = e;
|
|
333
334
|
}
|
|
334
335
|
}
|
|
335
336
|
while (true);
|
|
336
337
|
};
|
|
337
338
|
function $flushCOROUTINE$1(_this__u8e3s4, resultContinuation) {
|
|
338
339
|
CoroutineImpl.call(this, resultContinuation);
|
|
339
|
-
this.
|
|
340
|
+
this.e1g_1 = _this__u8e3s4;
|
|
340
341
|
}
|
|
341
|
-
protoOf($flushCOROUTINE$1).
|
|
342
|
-
var suspendResult = this.
|
|
342
|
+
protoOf($flushCOROUTINE$1).m9 = function () {
|
|
343
|
+
var suspendResult = this.g9_1;
|
|
343
344
|
$sm: do
|
|
344
345
|
try {
|
|
345
|
-
var tmp = this.
|
|
346
|
+
var tmp = this.e9_1;
|
|
346
347
|
switch (tmp) {
|
|
347
348
|
case 0:
|
|
348
|
-
this.
|
|
349
|
-
rethrowCloseCauseIfNeeded_1(this.
|
|
350
|
-
this.
|
|
351
|
-
if (this.
|
|
349
|
+
this.f9_1 = 4;
|
|
350
|
+
rethrowCloseCauseIfNeeded_1(this.e1g_1);
|
|
351
|
+
this.e1g_1.h1g();
|
|
352
|
+
if (this.e1g_1.e1f_1 < 1048576)
|
|
352
353
|
return Unit_instance;
|
|
353
354
|
var tmp_0 = this;
|
|
354
|
-
tmp_0.
|
|
355
|
-
this.
|
|
355
|
+
tmp_0.f1g_1 = this.e1g_1;
|
|
356
|
+
this.g1g_1 = this.f1g_1;
|
|
357
|
+
this.e9_1 = 1;
|
|
356
358
|
continue $sm;
|
|
357
359
|
case 1:
|
|
358
|
-
if (!(this.
|
|
359
|
-
this.
|
|
360
|
+
if (!(this.e1g_1.e1f_1 >= 1048576 && this.e1g_1.j1f_1.kotlinx$atomicfu$value == null)) {
|
|
361
|
+
this.e9_1 = 3;
|
|
360
362
|
continue $sm;
|
|
361
363
|
}
|
|
362
364
|
|
|
363
|
-
this.
|
|
365
|
+
this.e9_1 = 2;
|
|
364
366
|
var cancellable = new CancellableContinuationImpl(intercepted(this), 1);
|
|
365
|
-
cancellable.
|
|
367
|
+
cancellable.qs();
|
|
368
|
+
var tmp0 = this.g1g_1;
|
|
369
|
+
var tmp1 = new Write(cancellable);
|
|
366
370
|
l$ret$1: do {
|
|
367
|
-
var
|
|
368
|
-
var slot = new Write(cancellable);
|
|
369
|
-
var previous = this_0.f1e_1.kotlinx$atomicfu$value;
|
|
371
|
+
var previous = tmp0.g1f_1.kotlinx$atomicfu$value;
|
|
370
372
|
if (!(previous instanceof Closed)) {
|
|
371
|
-
if (!
|
|
372
|
-
|
|
373
|
+
if (!tmp0.g1f_1.atomicfu$compareAndSet(previous, tmp1)) {
|
|
374
|
+
tmp1.y1e();
|
|
373
375
|
break l$ret$1;
|
|
374
376
|
}
|
|
375
377
|
}
|
|
376
378
|
if (previous instanceof Write) {
|
|
377
|
-
previous.
|
|
379
|
+
previous.z1e(new ConcurrentIOException(tmp1.x1e()));
|
|
378
380
|
} else {
|
|
379
381
|
if (isInterface(previous, Task)) {
|
|
380
|
-
previous.
|
|
382
|
+
previous.y1e();
|
|
381
383
|
} else {
|
|
382
384
|
if (previous instanceof Closed) {
|
|
383
|
-
|
|
385
|
+
tmp1.z1e(previous.v1e_1);
|
|
384
386
|
break l$ret$1;
|
|
385
387
|
} else {
|
|
386
388
|
if (!equals(previous, Empty_instance)) {
|
|
@@ -389,202 +391,205 @@
|
|
|
389
391
|
}
|
|
390
392
|
}
|
|
391
393
|
}
|
|
392
|
-
if (!(this.
|
|
393
|
-
var current =
|
|
394
|
+
if (!(this.e1g_1.e1f_1 >= 1048576 && this.e1g_1.j1f_1.kotlinx$atomicfu$value == null)) {
|
|
395
|
+
var current = tmp0.g1f_1.kotlinx$atomicfu$value;
|
|
394
396
|
var tmp_1;
|
|
395
397
|
if (current instanceof Write) {
|
|
396
|
-
tmp_1 =
|
|
398
|
+
tmp_1 = tmp0.g1f_1.atomicfu$compareAndSet(current, Empty_instance);
|
|
397
399
|
} else {
|
|
398
400
|
tmp_1 = false;
|
|
399
401
|
}
|
|
400
402
|
if (tmp_1) {
|
|
401
|
-
current.
|
|
403
|
+
current.y1e();
|
|
402
404
|
}
|
|
403
405
|
}
|
|
404
406
|
}
|
|
405
407
|
while (false);
|
|
406
|
-
suspendResult = returnIfSuspended(cancellable.
|
|
408
|
+
suspendResult = returnIfSuspended(cancellable.ys(), this);
|
|
407
409
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
408
410
|
return suspendResult;
|
|
409
411
|
}
|
|
410
412
|
|
|
411
413
|
continue $sm;
|
|
412
414
|
case 2:
|
|
413
|
-
this.
|
|
415
|
+
this.e9_1 = 1;
|
|
414
416
|
continue $sm;
|
|
415
417
|
case 3:
|
|
416
418
|
return Unit_instance;
|
|
417
419
|
case 4:
|
|
418
|
-
throw this.
|
|
420
|
+
throw this.h9_1;
|
|
419
421
|
}
|
|
420
422
|
} catch ($p) {
|
|
421
423
|
var e = $p;
|
|
422
|
-
if (this.
|
|
424
|
+
if (this.f9_1 === 4) {
|
|
423
425
|
throw e;
|
|
424
426
|
} else {
|
|
425
|
-
this.
|
|
426
|
-
this.
|
|
427
|
+
this.e9_1 = this.f9_1;
|
|
428
|
+
this.h9_1 = e;
|
|
427
429
|
}
|
|
428
430
|
}
|
|
429
431
|
while (true);
|
|
430
432
|
};
|
|
431
433
|
function $flushAndCloseCOROUTINE$2(_this__u8e3s4, resultContinuation) {
|
|
432
434
|
CoroutineImpl.call(this, resultContinuation);
|
|
433
|
-
this.
|
|
435
|
+
this.q1g_1 = _this__u8e3s4;
|
|
434
436
|
}
|
|
435
|
-
protoOf($flushAndCloseCOROUTINE$2).
|
|
436
|
-
var suspendResult = this.
|
|
437
|
+
protoOf($flushAndCloseCOROUTINE$2).m9 = function () {
|
|
438
|
+
var suspendResult = this.g9_1;
|
|
437
439
|
$sm: do
|
|
438
440
|
try {
|
|
439
|
-
var tmp = this.
|
|
441
|
+
var tmp = this.e9_1;
|
|
440
442
|
switch (tmp) {
|
|
441
443
|
case 0:
|
|
442
|
-
this.
|
|
444
|
+
this.f9_1 = 4;
|
|
443
445
|
var tmp_0 = this;
|
|
444
|
-
tmp_0.
|
|
445
|
-
this.
|
|
446
|
+
tmp_0.r1g_1 = this.q1g_1;
|
|
447
|
+
this.s1g_1 = this.r1g_1;
|
|
448
|
+
this.f9_1 = 2;
|
|
446
449
|
var tmp_1 = this;
|
|
447
|
-
tmp_1.
|
|
450
|
+
tmp_1.u1g_1 = Companion_instance;
|
|
448
451
|
var tmp_2 = this;
|
|
449
|
-
tmp_2.
|
|
450
|
-
this.
|
|
451
|
-
|
|
452
|
+
tmp_2.v1g_1 = this.s1g_1;
|
|
453
|
+
this.w1g_1 = this.v1g_1;
|
|
454
|
+
this.e9_1 = 1;
|
|
455
|
+
suspendResult = this.w1g_1.x1g(this);
|
|
452
456
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
453
457
|
return suspendResult;
|
|
454
458
|
}
|
|
455
459
|
|
|
456
460
|
continue $sm;
|
|
457
461
|
case 1:
|
|
458
|
-
|
|
459
|
-
this.
|
|
460
|
-
|
|
462
|
+
var tmp_3 = this;
|
|
463
|
+
this.u1g_1;
|
|
464
|
+
tmp_3.t1g_1 = _Result___init__impl__xyqfz8(Unit_instance);
|
|
465
|
+
this.f9_1 = 4;
|
|
466
|
+
this.e9_1 = 3;
|
|
461
467
|
continue $sm;
|
|
462
468
|
case 2:
|
|
463
|
-
this.
|
|
464
|
-
var
|
|
465
|
-
if (
|
|
466
|
-
var e = this.
|
|
467
|
-
var
|
|
468
|
-
|
|
469
|
-
this.
|
|
469
|
+
this.f9_1 = 4;
|
|
470
|
+
var tmp_4 = this.h9_1;
|
|
471
|
+
if (tmp_4 instanceof Error) {
|
|
472
|
+
var e = this.h9_1;
|
|
473
|
+
var tmp_5 = this;
|
|
474
|
+
tmp_5.t1g_1 = _Result___init__impl__xyqfz8(createFailure(e));
|
|
475
|
+
this.e9_1 = 3;
|
|
470
476
|
continue $sm;
|
|
471
477
|
} else {
|
|
472
|
-
throw this.
|
|
478
|
+
throw this.h9_1;
|
|
473
479
|
}
|
|
474
480
|
|
|
475
481
|
case 3:
|
|
476
|
-
this.
|
|
477
|
-
if (!this.
|
|
482
|
+
this.f9_1 = 4;
|
|
483
|
+
if (!this.q1g_1.j1f_1.atomicfu$compareAndSet(null, get_CLOSED()))
|
|
478
484
|
return Unit_instance;
|
|
479
|
-
closeSlot(this.
|
|
485
|
+
closeSlot(this.q1g_1, null);
|
|
480
486
|
return Unit_instance;
|
|
481
487
|
case 4:
|
|
482
|
-
throw this.
|
|
488
|
+
throw this.h9_1;
|
|
483
489
|
}
|
|
484
490
|
} catch ($p) {
|
|
485
491
|
var e_0 = $p;
|
|
486
|
-
if (this.
|
|
492
|
+
if (this.f9_1 === 4) {
|
|
487
493
|
throw e_0;
|
|
488
494
|
} else {
|
|
489
|
-
this.
|
|
490
|
-
this.
|
|
495
|
+
this.e9_1 = this.f9_1;
|
|
496
|
+
this.h9_1 = e_0;
|
|
491
497
|
}
|
|
492
498
|
}
|
|
493
499
|
while (true);
|
|
494
500
|
};
|
|
495
501
|
function ByteChannel(autoFlush) {
|
|
496
502
|
autoFlush = autoFlush === VOID ? false : autoFlush;
|
|
497
|
-
this.
|
|
498
|
-
this.
|
|
499
|
-
this.
|
|
500
|
-
this.
|
|
501
|
-
this.
|
|
502
|
-
this.
|
|
503
|
-
this.
|
|
504
|
-
this.
|
|
505
|
-
}
|
|
506
|
-
protoOf(ByteChannel).
|
|
507
|
-
var tmp0_safe_receiver = this.
|
|
503
|
+
this.c1f_1 = autoFlush;
|
|
504
|
+
this.d1f_1 = new Buffer();
|
|
505
|
+
this.e1f_1 = 0;
|
|
506
|
+
this.f1f_1 = new Object();
|
|
507
|
+
this.g1f_1 = atomic$ref$1(Empty_instance);
|
|
508
|
+
this.h1f_1 = new Buffer();
|
|
509
|
+
this.i1f_1 = new Buffer();
|
|
510
|
+
this.j1f_1 = atomic$ref$1(null);
|
|
511
|
+
}
|
|
512
|
+
protoOf(ByteChannel).y1g = function () {
|
|
513
|
+
var tmp0_safe_receiver = this.z1g();
|
|
508
514
|
if (tmp0_safe_receiver == null)
|
|
509
515
|
null;
|
|
510
516
|
else {
|
|
511
517
|
// Inline function 'kotlin.let' call
|
|
512
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
513
518
|
throw tmp0_safe_receiver;
|
|
514
519
|
}
|
|
515
|
-
if (this.
|
|
520
|
+
if (this.h1f_1.v1b()) {
|
|
516
521
|
moveFlushToReadBuffer(this);
|
|
517
522
|
}
|
|
518
|
-
return this.
|
|
523
|
+
return this.h1f_1;
|
|
519
524
|
};
|
|
520
|
-
protoOf(ByteChannel).
|
|
521
|
-
var tmp0_safe_receiver = this.
|
|
525
|
+
protoOf(ByteChannel).a1h = function () {
|
|
526
|
+
var tmp0_safe_receiver = this.z1g();
|
|
522
527
|
if (tmp0_safe_receiver == null)
|
|
523
528
|
null;
|
|
524
529
|
else {
|
|
525
530
|
// Inline function 'kotlin.let' call
|
|
526
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
527
531
|
throw tmp0_safe_receiver;
|
|
528
532
|
}
|
|
529
|
-
if (this.
|
|
533
|
+
if (this.b1h()) {
|
|
530
534
|
throw IOException_init_$Create$('Channel is closed for write');
|
|
531
535
|
}
|
|
532
|
-
return this.
|
|
536
|
+
return this.i1f_1;
|
|
533
537
|
};
|
|
534
|
-
protoOf(ByteChannel).
|
|
535
|
-
var tmp0_safe_receiver = this.
|
|
536
|
-
return tmp0_safe_receiver == null ? null : tmp0_safe_receiver.
|
|
538
|
+
protoOf(ByteChannel).z1g = function () {
|
|
539
|
+
var tmp0_safe_receiver = this.j1f_1.kotlinx$atomicfu$value;
|
|
540
|
+
return tmp0_safe_receiver == null ? null : tmp0_safe_receiver.v9();
|
|
537
541
|
};
|
|
538
|
-
protoOf(ByteChannel).
|
|
539
|
-
return !(this.
|
|
542
|
+
protoOf(ByteChannel).b1h = function () {
|
|
543
|
+
return !(this.j1f_1.kotlinx$atomicfu$value == null);
|
|
540
544
|
};
|
|
541
|
-
protoOf(ByteChannel).
|
|
542
|
-
return !(this.
|
|
545
|
+
protoOf(ByteChannel).d1h = function () {
|
|
546
|
+
return !(this.z1g() == null) || (this.b1h() && this.e1f_1 === 0 && this.h1f_1.v1b());
|
|
543
547
|
};
|
|
544
|
-
protoOf(ByteChannel).
|
|
548
|
+
protoOf(ByteChannel).e1h = function (min, $completion) {
|
|
545
549
|
var tmp = new $awaitContentCOROUTINE$0(this, min, $completion);
|
|
546
|
-
tmp.
|
|
547
|
-
tmp.
|
|
548
|
-
return tmp.
|
|
550
|
+
tmp.g9_1 = Unit_instance;
|
|
551
|
+
tmp.h9_1 = null;
|
|
552
|
+
return tmp.m9();
|
|
549
553
|
};
|
|
550
|
-
protoOf(ByteChannel).
|
|
554
|
+
protoOf(ByteChannel).x1g = function ($completion) {
|
|
551
555
|
var tmp = new $flushCOROUTINE$1(this, $completion);
|
|
552
|
-
tmp.
|
|
553
|
-
tmp.
|
|
554
|
-
return tmp.
|
|
556
|
+
tmp.g9_1 = Unit_instance;
|
|
557
|
+
tmp.h9_1 = null;
|
|
558
|
+
return tmp.m9();
|
|
555
559
|
};
|
|
556
|
-
protoOf(ByteChannel).
|
|
557
|
-
if (this.
|
|
560
|
+
protoOf(ByteChannel).h1g = function () {
|
|
561
|
+
if (this.i1f_1.v1b())
|
|
558
562
|
return Unit_instance;
|
|
559
563
|
// Inline function 'io.ktor.utils.io.locks.synchronized' call
|
|
560
|
-
this.
|
|
561
|
-
|
|
562
|
-
this.
|
|
563
|
-
this.
|
|
564
|
+
this.f1f_1;
|
|
565
|
+
// Inline function 'io.ktor.utils.io.ByteChannel.flushWriteBuffer.<anonymous>' call
|
|
566
|
+
var count = this.i1f_1.s().j1();
|
|
567
|
+
this.d1f_1.l1d(this.i1f_1);
|
|
568
|
+
this.e1f_1 = this.e1f_1 + count | 0;
|
|
564
569
|
// Inline function 'io.ktor.utils.io.ByteChannel.resumeSlot' call
|
|
565
|
-
var current = this.
|
|
570
|
+
var current = this.g1f_1.kotlinx$atomicfu$value;
|
|
566
571
|
var tmp;
|
|
567
572
|
if (current instanceof Read) {
|
|
568
|
-
tmp = this.
|
|
573
|
+
tmp = this.g1f_1.atomicfu$compareAndSet(current, Empty_instance);
|
|
569
574
|
} else {
|
|
570
575
|
tmp = false;
|
|
571
576
|
}
|
|
572
577
|
if (tmp) {
|
|
573
|
-
current.
|
|
578
|
+
current.y1e();
|
|
574
579
|
}
|
|
575
580
|
};
|
|
576
|
-
protoOf(ByteChannel).
|
|
581
|
+
protoOf(ByteChannel).g1h = function ($completion) {
|
|
577
582
|
var tmp = new $flushAndCloseCOROUTINE$2(this, $completion);
|
|
578
|
-
tmp.
|
|
579
|
-
tmp.
|
|
580
|
-
return tmp.
|
|
583
|
+
tmp.g9_1 = Unit_instance;
|
|
584
|
+
tmp.h9_1 = null;
|
|
585
|
+
return tmp.m9();
|
|
581
586
|
};
|
|
582
|
-
protoOf(ByteChannel).
|
|
583
|
-
if (!(this.
|
|
587
|
+
protoOf(ByteChannel).h1h = function (cause) {
|
|
588
|
+
if (!(this.j1f_1.kotlinx$atomicfu$value == null))
|
|
584
589
|
return Unit_instance;
|
|
585
590
|
var closedToken = new CloseToken(cause);
|
|
586
|
-
this.
|
|
587
|
-
var actualCause = closedToken.
|
|
591
|
+
this.j1f_1.atomicfu$compareAndSet(null, closedToken);
|
|
592
|
+
var actualCause = closedToken.v9();
|
|
588
593
|
closeSlot(this, actualCause);
|
|
589
594
|
};
|
|
590
595
|
protoOf(ByteChannel).toString = function () {
|
|
@@ -599,9 +604,8 @@
|
|
|
599
604
|
length = length === VOID ? content.length : length;
|
|
600
605
|
// Inline function 'kotlin.also' call
|
|
601
606
|
var this_0 = new Buffer();
|
|
602
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
603
607
|
// Inline function 'io.ktor.utils.io.ByteReadChannel.<anonymous>' call
|
|
604
|
-
this_0.
|
|
608
|
+
this_0.d1d(content, offset, offset + length | 0);
|
|
605
609
|
var source = this_0;
|
|
606
610
|
return ByteReadChannel_0(source);
|
|
607
611
|
}
|
|
@@ -609,27 +613,27 @@
|
|
|
609
613
|
return new SourceByteReadChannel(source);
|
|
610
614
|
}
|
|
611
615
|
function ByteReadChannel$Companion$Empty$1() {
|
|
612
|
-
this.
|
|
613
|
-
this.
|
|
616
|
+
this.i1h_1 = null;
|
|
617
|
+
this.j1h_1 = new Buffer();
|
|
614
618
|
}
|
|
615
|
-
protoOf(ByteReadChannel$Companion$Empty$1).
|
|
616
|
-
return this.
|
|
619
|
+
protoOf(ByteReadChannel$Companion$Empty$1).z1g = function () {
|
|
620
|
+
return this.i1h_1;
|
|
617
621
|
};
|
|
618
|
-
protoOf(ByteReadChannel$Companion$Empty$1).
|
|
622
|
+
protoOf(ByteReadChannel$Companion$Empty$1).d1h = function () {
|
|
619
623
|
return true;
|
|
620
624
|
};
|
|
621
|
-
protoOf(ByteReadChannel$Companion$Empty$1).
|
|
622
|
-
return this.
|
|
625
|
+
protoOf(ByteReadChannel$Companion$Empty$1).y1g = function () {
|
|
626
|
+
return this.j1h_1;
|
|
623
627
|
};
|
|
624
|
-
protoOf(ByteReadChannel$Companion$Empty$1).
|
|
628
|
+
protoOf(ByteReadChannel$Companion$Empty$1).e1h = function (min, $completion) {
|
|
625
629
|
return false;
|
|
626
630
|
};
|
|
627
|
-
protoOf(ByteReadChannel$Companion$Empty$1).
|
|
631
|
+
protoOf(ByteReadChannel$Companion$Empty$1).h1h = function (cause) {
|
|
628
632
|
};
|
|
629
633
|
function Companion_0() {
|
|
630
634
|
Companion_instance_1 = this;
|
|
631
635
|
var tmp = this;
|
|
632
|
-
tmp.
|
|
636
|
+
tmp.k1h_1 = new ByteReadChannel$Companion$Empty$1();
|
|
633
637
|
}
|
|
634
638
|
var Companion_instance_1;
|
|
635
639
|
function Companion_getInstance_0() {
|
|
@@ -640,267 +644,264 @@
|
|
|
640
644
|
function ByteReadChannel_1() {
|
|
641
645
|
}
|
|
642
646
|
function cancel_0(_this__u8e3s4) {
|
|
643
|
-
_this__u8e3s4.
|
|
647
|
+
_this__u8e3s4.h1h(IOException_init_$Create$('Channel was cancelled'));
|
|
644
648
|
}
|
|
645
649
|
function readRemaining(_this__u8e3s4, $completion) {
|
|
646
650
|
var tmp = new $readRemainingCOROUTINE$3(_this__u8e3s4, $completion);
|
|
647
|
-
tmp.
|
|
648
|
-
tmp.
|
|
649
|
-
return tmp.
|
|
651
|
+
tmp.g9_1 = Unit_instance;
|
|
652
|
+
tmp.h9_1 = null;
|
|
653
|
+
return tmp.m9();
|
|
650
654
|
}
|
|
651
655
|
function get_availableForRead(_this__u8e3s4) {
|
|
652
|
-
return _this__u8e3s4.
|
|
656
|
+
return _this__u8e3s4.y1g().u1b().s().j1();
|
|
653
657
|
}
|
|
654
658
|
function readPacket(_this__u8e3s4, packet, $completion) {
|
|
655
659
|
var tmp = new $readPacketCOROUTINE$4(_this__u8e3s4, packet, $completion);
|
|
656
|
-
tmp.
|
|
657
|
-
tmp.
|
|
658
|
-
return tmp.
|
|
660
|
+
tmp.g9_1 = Unit_instance;
|
|
661
|
+
tmp.h9_1 = null;
|
|
662
|
+
return tmp.m9();
|
|
659
663
|
}
|
|
660
664
|
function readAvailable(_this__u8e3s4, buffer, offset, length, $completion) {
|
|
661
665
|
offset = offset === VOID ? 0 : offset;
|
|
662
666
|
length = length === VOID ? buffer.length - offset | 0 : length;
|
|
663
667
|
var tmp = new $readAvailableCOROUTINE$7(_this__u8e3s4, buffer, offset, length, $completion);
|
|
664
|
-
tmp.
|
|
665
|
-
tmp.
|
|
666
|
-
return tmp.
|
|
668
|
+
tmp.g9_1 = Unit_instance;
|
|
669
|
+
tmp.h9_1 = null;
|
|
670
|
+
return tmp.m9();
|
|
667
671
|
}
|
|
668
672
|
function toByteArray(_this__u8e3s4, $completion) {
|
|
669
673
|
var tmp = new $toByteArrayCOROUTINE$9(_this__u8e3s4, $completion);
|
|
670
|
-
tmp.
|
|
671
|
-
tmp.
|
|
672
|
-
return tmp.
|
|
674
|
+
tmp.g9_1 = Unit_instance;
|
|
675
|
+
tmp.h9_1 = null;
|
|
676
|
+
return tmp.m9();
|
|
673
677
|
}
|
|
674
678
|
function copyTo(_this__u8e3s4, channel, limit, $completion) {
|
|
675
679
|
var tmp = new $copyToCOROUTINE$10(_this__u8e3s4, channel, limit, $completion);
|
|
676
|
-
tmp.
|
|
677
|
-
tmp.
|
|
678
|
-
return tmp.
|
|
680
|
+
tmp.g9_1 = Unit_instance;
|
|
681
|
+
tmp.h9_1 = null;
|
|
682
|
+
return tmp.m9();
|
|
679
683
|
}
|
|
680
684
|
function rethrowCloseCauseIfNeeded(_this__u8e3s4) {
|
|
681
|
-
var tmp0_safe_receiver = _this__u8e3s4.
|
|
685
|
+
var tmp0_safe_receiver = _this__u8e3s4.z1g();
|
|
682
686
|
if (tmp0_safe_receiver == null)
|
|
683
687
|
null;
|
|
684
688
|
else {
|
|
685
689
|
// Inline function 'kotlin.let' call
|
|
686
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
687
690
|
throw tmp0_safe_receiver;
|
|
688
691
|
}
|
|
689
692
|
}
|
|
690
693
|
function readBuffer(_this__u8e3s4, $completion) {
|
|
691
694
|
var tmp = new $readBufferCOROUTINE$12(_this__u8e3s4, $completion);
|
|
692
|
-
tmp.
|
|
693
|
-
tmp.
|
|
694
|
-
return tmp.
|
|
695
|
+
tmp.g9_1 = Unit_instance;
|
|
696
|
+
tmp.h9_1 = null;
|
|
697
|
+
return tmp.m9();
|
|
695
698
|
}
|
|
696
699
|
function rethrowCloseCauseIfNeeded_0(_this__u8e3s4) {
|
|
697
|
-
var tmp0_safe_receiver = _this__u8e3s4.
|
|
700
|
+
var tmp0_safe_receiver = _this__u8e3s4.z1g();
|
|
698
701
|
if (tmp0_safe_receiver == null)
|
|
699
702
|
null;
|
|
700
703
|
else {
|
|
701
704
|
// Inline function 'kotlin.let' call
|
|
702
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
703
705
|
throw tmp0_safe_receiver;
|
|
704
706
|
}
|
|
705
707
|
}
|
|
706
708
|
function rethrowCloseCauseIfNeeded_1(_this__u8e3s4) {
|
|
707
|
-
var tmp0_safe_receiver = _this__u8e3s4.
|
|
709
|
+
var tmp0_safe_receiver = _this__u8e3s4.z1g();
|
|
708
710
|
if (tmp0_safe_receiver == null)
|
|
709
711
|
null;
|
|
710
712
|
else {
|
|
711
713
|
// Inline function 'kotlin.let' call
|
|
712
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
713
714
|
throw tmp0_safe_receiver;
|
|
714
715
|
}
|
|
715
716
|
}
|
|
716
717
|
function $readRemainingCOROUTINE$3(_this__u8e3s4, resultContinuation) {
|
|
717
718
|
CoroutineImpl.call(this, resultContinuation);
|
|
718
|
-
this.
|
|
719
|
+
this.t1h_1 = _this__u8e3s4;
|
|
719
720
|
}
|
|
720
|
-
protoOf($readRemainingCOROUTINE$3).
|
|
721
|
-
var suspendResult = this.
|
|
721
|
+
protoOf($readRemainingCOROUTINE$3).m9 = function () {
|
|
722
|
+
var suspendResult = this.g9_1;
|
|
722
723
|
$sm: do
|
|
723
724
|
try {
|
|
724
|
-
var tmp = this.
|
|
725
|
+
var tmp = this.e9_1;
|
|
725
726
|
switch (tmp) {
|
|
726
727
|
case 0:
|
|
727
|
-
this.
|
|
728
|
-
this.
|
|
729
|
-
this.
|
|
728
|
+
this.f9_1 = 4;
|
|
729
|
+
this.u1h_1 = BytePacketBuilder();
|
|
730
|
+
this.e9_1 = 1;
|
|
730
731
|
continue $sm;
|
|
731
732
|
case 1:
|
|
732
|
-
if (!!this.
|
|
733
|
-
this.
|
|
733
|
+
if (!!this.t1h_1.d1h()) {
|
|
734
|
+
this.e9_1 = 3;
|
|
734
735
|
continue $sm;
|
|
735
736
|
}
|
|
736
737
|
|
|
737
|
-
this.
|
|
738
|
-
this.
|
|
739
|
-
suspendResult = this.
|
|
738
|
+
this.u1h_1.l1d(this.t1h_1.y1g());
|
|
739
|
+
this.e9_1 = 2;
|
|
740
|
+
suspendResult = this.t1h_1.f1h(VOID, this);
|
|
740
741
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
741
742
|
return suspendResult;
|
|
742
743
|
}
|
|
743
744
|
|
|
744
745
|
continue $sm;
|
|
745
746
|
case 2:
|
|
746
|
-
this.
|
|
747
|
+
this.e9_1 = 1;
|
|
747
748
|
continue $sm;
|
|
748
749
|
case 3:
|
|
749
|
-
rethrowCloseCauseIfNeeded(this.
|
|
750
|
-
return this.
|
|
750
|
+
rethrowCloseCauseIfNeeded(this.t1h_1);
|
|
751
|
+
return this.u1h_1.u1b();
|
|
751
752
|
case 4:
|
|
752
|
-
throw this.
|
|
753
|
+
throw this.h9_1;
|
|
753
754
|
}
|
|
754
755
|
} catch ($p) {
|
|
755
756
|
var e = $p;
|
|
756
|
-
if (this.
|
|
757
|
+
if (this.f9_1 === 4) {
|
|
757
758
|
throw e;
|
|
758
759
|
} else {
|
|
759
|
-
this.
|
|
760
|
-
this.
|
|
760
|
+
this.e9_1 = this.f9_1;
|
|
761
|
+
this.h9_1 = e;
|
|
761
762
|
}
|
|
762
763
|
}
|
|
763
764
|
while (true);
|
|
764
765
|
};
|
|
765
766
|
function $readPacketCOROUTINE$4(_this__u8e3s4, packet, resultContinuation) {
|
|
766
767
|
CoroutineImpl.call(this, resultContinuation);
|
|
767
|
-
this.
|
|
768
|
-
this.
|
|
768
|
+
this.d1i_1 = _this__u8e3s4;
|
|
769
|
+
this.e1i_1 = packet;
|
|
769
770
|
}
|
|
770
|
-
protoOf($readPacketCOROUTINE$4).
|
|
771
|
-
var suspendResult = this.
|
|
771
|
+
protoOf($readPacketCOROUTINE$4).m9 = function () {
|
|
772
|
+
var suspendResult = this.g9_1;
|
|
772
773
|
$sm: do
|
|
773
774
|
try {
|
|
774
|
-
var tmp = this.
|
|
775
|
+
var tmp = this.e9_1;
|
|
775
776
|
switch (tmp) {
|
|
776
777
|
case 0:
|
|
777
|
-
this.
|
|
778
|
-
this.
|
|
779
|
-
this.
|
|
778
|
+
this.f9_1 = 6;
|
|
779
|
+
this.f1i_1 = new Buffer();
|
|
780
|
+
this.e9_1 = 1;
|
|
780
781
|
continue $sm;
|
|
781
782
|
case 1:
|
|
782
|
-
if (!(this.
|
|
783
|
-
this.
|
|
783
|
+
if (!(this.f1i_1.s().e1(toLong(this.e1i_1)) < 0)) {
|
|
784
|
+
this.e9_1 = 5;
|
|
784
785
|
continue $sm;
|
|
785
786
|
}
|
|
786
787
|
|
|
787
|
-
if (this.
|
|
788
|
-
this.
|
|
789
|
-
suspendResult = this.
|
|
788
|
+
if (this.d1i_1.y1g().v1b()) {
|
|
789
|
+
this.e9_1 = 2;
|
|
790
|
+
suspendResult = this.d1i_1.f1h(VOID, this);
|
|
790
791
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
791
792
|
return suspendResult;
|
|
792
793
|
}
|
|
793
794
|
continue $sm;
|
|
794
795
|
} else {
|
|
795
|
-
this.
|
|
796
|
+
this.e9_1 = 3;
|
|
796
797
|
continue $sm;
|
|
797
798
|
}
|
|
798
799
|
|
|
799
800
|
case 2:
|
|
800
|
-
this.
|
|
801
|
+
this.e9_1 = 3;
|
|
801
802
|
continue $sm;
|
|
802
803
|
case 3:
|
|
803
|
-
if (this.
|
|
804
|
-
this.
|
|
804
|
+
if (this.d1i_1.d1h()) {
|
|
805
|
+
this.e9_1 = 5;
|
|
805
806
|
continue $sm;
|
|
806
807
|
} else {
|
|
807
|
-
this.
|
|
808
|
+
this.e9_1 = 4;
|
|
808
809
|
continue $sm;
|
|
809
810
|
}
|
|
810
811
|
|
|
811
812
|
case 4:
|
|
812
|
-
if (get_remaining(this.
|
|
813
|
-
this.
|
|
813
|
+
if (get_remaining(this.d1i_1.y1g()).e1(numberToLong(this.e1i_1).a3(this.f1i_1.s())) > 0) {
|
|
814
|
+
this.d1i_1.y1g().w1c(this.f1i_1, numberToLong(this.e1i_1).a3(this.f1i_1.s()));
|
|
814
815
|
} else {
|
|
815
|
-
this.
|
|
816
|
+
this.d1i_1.y1g().x1c(this.f1i_1);
|
|
816
817
|
}
|
|
817
818
|
|
|
818
|
-
this.
|
|
819
|
+
this.e9_1 = 1;
|
|
819
820
|
continue $sm;
|
|
820
821
|
case 5:
|
|
821
|
-
if (this.
|
|
822
|
-
throw EOFException_init_$Create$('Not enough data available, required ' + this.
|
|
822
|
+
if (this.f1i_1.s().e1(toLong(this.e1i_1)) < 0) {
|
|
823
|
+
throw EOFException_init_$Create$('Not enough data available, required ' + this.e1i_1 + ' bytes but only ' + this.f1i_1.s().toString() + ' available');
|
|
823
824
|
}
|
|
824
825
|
|
|
825
|
-
return this.
|
|
826
|
+
return this.f1i_1;
|
|
826
827
|
case 6:
|
|
827
|
-
throw this.
|
|
828
|
+
throw this.h9_1;
|
|
828
829
|
}
|
|
829
830
|
} catch ($p) {
|
|
830
831
|
var e = $p;
|
|
831
|
-
if (this.
|
|
832
|
+
if (this.f9_1 === 6) {
|
|
832
833
|
throw e;
|
|
833
834
|
} else {
|
|
834
|
-
this.
|
|
835
|
-
this.
|
|
835
|
+
this.e9_1 = this.f9_1;
|
|
836
|
+
this.h9_1 = e;
|
|
836
837
|
}
|
|
837
838
|
}
|
|
838
839
|
while (true);
|
|
839
840
|
};
|
|
840
841
|
function $readAvailableCOROUTINE$7(_this__u8e3s4, buffer, offset, length, resultContinuation) {
|
|
841
842
|
CoroutineImpl.call(this, resultContinuation);
|
|
842
|
-
this.
|
|
843
|
-
this.
|
|
844
|
-
this.
|
|
845
|
-
this.
|
|
843
|
+
this.o1i_1 = _this__u8e3s4;
|
|
844
|
+
this.p1i_1 = buffer;
|
|
845
|
+
this.q1i_1 = offset;
|
|
846
|
+
this.r1i_1 = length;
|
|
846
847
|
}
|
|
847
|
-
protoOf($readAvailableCOROUTINE$7).
|
|
848
|
-
var suspendResult = this.
|
|
848
|
+
protoOf($readAvailableCOROUTINE$7).m9 = function () {
|
|
849
|
+
var suspendResult = this.g9_1;
|
|
849
850
|
$sm: do
|
|
850
851
|
try {
|
|
851
|
-
var tmp = this.
|
|
852
|
+
var tmp = this.e9_1;
|
|
852
853
|
switch (tmp) {
|
|
853
854
|
case 0:
|
|
854
|
-
this.
|
|
855
|
-
if (this.
|
|
855
|
+
this.f9_1 = 3;
|
|
856
|
+
if (this.o1i_1.d1h())
|
|
856
857
|
return -1;
|
|
857
|
-
if (this.
|
|
858
|
-
this.
|
|
859
|
-
suspendResult = this.
|
|
858
|
+
if (this.o1i_1.y1g().v1b()) {
|
|
859
|
+
this.e9_1 = 1;
|
|
860
|
+
suspendResult = this.o1i_1.f1h(VOID, this);
|
|
860
861
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
861
862
|
return suspendResult;
|
|
862
863
|
}
|
|
863
864
|
continue $sm;
|
|
864
865
|
} else {
|
|
865
|
-
this.
|
|
866
|
+
this.e9_1 = 2;
|
|
866
867
|
continue $sm;
|
|
867
868
|
}
|
|
868
869
|
|
|
869
870
|
case 1:
|
|
870
|
-
this.
|
|
871
|
+
this.e9_1 = 2;
|
|
871
872
|
continue $sm;
|
|
872
873
|
case 2:
|
|
873
|
-
if (this.
|
|
874
|
+
if (this.o1i_1.d1h())
|
|
874
875
|
return -1;
|
|
875
|
-
return readAvailable_0(this.
|
|
876
|
+
return readAvailable_0(this.o1i_1.y1g(), this.p1i_1, this.q1i_1, this.r1i_1);
|
|
876
877
|
case 3:
|
|
877
|
-
throw this.
|
|
878
|
+
throw this.h9_1;
|
|
878
879
|
}
|
|
879
880
|
} catch ($p) {
|
|
880
881
|
var e = $p;
|
|
881
|
-
if (this.
|
|
882
|
+
if (this.f9_1 === 3) {
|
|
882
883
|
throw e;
|
|
883
884
|
} else {
|
|
884
|
-
this.
|
|
885
|
-
this.
|
|
885
|
+
this.e9_1 = this.f9_1;
|
|
886
|
+
this.h9_1 = e;
|
|
886
887
|
}
|
|
887
888
|
}
|
|
888
889
|
while (true);
|
|
889
890
|
};
|
|
890
891
|
function $toByteArrayCOROUTINE$9(_this__u8e3s4, resultContinuation) {
|
|
891
892
|
CoroutineImpl.call(this, resultContinuation);
|
|
892
|
-
this.
|
|
893
|
+
this.a1j_1 = _this__u8e3s4;
|
|
893
894
|
}
|
|
894
|
-
protoOf($toByteArrayCOROUTINE$9).
|
|
895
|
-
var suspendResult = this.
|
|
895
|
+
protoOf($toByteArrayCOROUTINE$9).m9 = function () {
|
|
896
|
+
var suspendResult = this.g9_1;
|
|
896
897
|
$sm: do
|
|
897
898
|
try {
|
|
898
|
-
var tmp = this.
|
|
899
|
+
var tmp = this.e9_1;
|
|
899
900
|
switch (tmp) {
|
|
900
901
|
case 0:
|
|
901
|
-
this.
|
|
902
|
-
this.
|
|
903
|
-
suspendResult = readBuffer(this.
|
|
902
|
+
this.f9_1 = 2;
|
|
903
|
+
this.e9_1 = 1;
|
|
904
|
+
suspendResult = readBuffer(this.a1j_1, this);
|
|
904
905
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
905
906
|
return suspendResult;
|
|
906
907
|
}
|
|
@@ -910,244 +911,244 @@
|
|
|
910
911
|
var ARGUMENT = suspendResult;
|
|
911
912
|
return readBytes(ARGUMENT);
|
|
912
913
|
case 2:
|
|
913
|
-
throw this.
|
|
914
|
+
throw this.h9_1;
|
|
914
915
|
}
|
|
915
916
|
} catch ($p) {
|
|
916
917
|
var e = $p;
|
|
917
|
-
if (this.
|
|
918
|
+
if (this.f9_1 === 2) {
|
|
918
919
|
throw e;
|
|
919
920
|
} else {
|
|
920
|
-
this.
|
|
921
|
-
this.
|
|
921
|
+
this.e9_1 = this.f9_1;
|
|
922
|
+
this.h9_1 = e;
|
|
922
923
|
}
|
|
923
924
|
}
|
|
924
925
|
while (true);
|
|
925
926
|
};
|
|
926
927
|
function $copyToCOROUTINE$10(_this__u8e3s4, channel, limit, resultContinuation) {
|
|
927
928
|
CoroutineImpl.call(this, resultContinuation);
|
|
928
|
-
this.
|
|
929
|
-
this.
|
|
930
|
-
this.
|
|
929
|
+
this.j1j_1 = _this__u8e3s4;
|
|
930
|
+
this.k1j_1 = channel;
|
|
931
|
+
this.l1j_1 = limit;
|
|
931
932
|
}
|
|
932
|
-
protoOf($copyToCOROUTINE$10).
|
|
933
|
-
var suspendResult = this.
|
|
933
|
+
protoOf($copyToCOROUTINE$10).m9 = function () {
|
|
934
|
+
var suspendResult = this.g9_1;
|
|
934
935
|
$sm: do
|
|
935
936
|
try {
|
|
936
|
-
var tmp = this.
|
|
937
|
+
var tmp = this.e9_1;
|
|
937
938
|
switch (tmp) {
|
|
938
939
|
case 0:
|
|
939
|
-
this.
|
|
940
|
-
this.
|
|
941
|
-
this.
|
|
940
|
+
this.f9_1 = 12;
|
|
941
|
+
this.m1j_1 = this.l1j_1;
|
|
942
|
+
this.e9_1 = 1;
|
|
942
943
|
continue $sm;
|
|
943
944
|
case 1:
|
|
944
|
-
this.
|
|
945
|
-
this.
|
|
946
|
-
this.
|
|
945
|
+
this.f9_1 = 8;
|
|
946
|
+
this.f9_1 = 7;
|
|
947
|
+
this.e9_1 = 2;
|
|
947
948
|
continue $sm;
|
|
948
949
|
case 2:
|
|
949
|
-
if (!(!this.
|
|
950
|
-
this.
|
|
950
|
+
if (!(!this.j1j_1.d1h() && this.m1j_1.e1(new Long(0, 0)) > 0)) {
|
|
951
|
+
this.e9_1 = 6;
|
|
951
952
|
continue $sm;
|
|
952
953
|
}
|
|
953
954
|
|
|
954
|
-
if (this.
|
|
955
|
-
this.
|
|
956
|
-
suspendResult = this.
|
|
955
|
+
if (this.j1j_1.y1g().v1b()) {
|
|
956
|
+
this.e9_1 = 3;
|
|
957
|
+
suspendResult = this.j1j_1.f1h(VOID, this);
|
|
957
958
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
958
959
|
return suspendResult;
|
|
959
960
|
}
|
|
960
961
|
continue $sm;
|
|
961
962
|
} else {
|
|
962
|
-
this.
|
|
963
|
+
this.e9_1 = 4;
|
|
963
964
|
continue $sm;
|
|
964
965
|
}
|
|
965
966
|
|
|
966
967
|
case 3:
|
|
967
|
-
this.
|
|
968
|
+
this.e9_1 = 4;
|
|
968
969
|
continue $sm;
|
|
969
970
|
case 4:
|
|
970
971
|
var tmp_0 = this;
|
|
971
|
-
var
|
|
972
|
-
var b = get_remaining(this.
|
|
973
|
-
tmp_0.
|
|
974
|
-
this.
|
|
975
|
-
this.
|
|
976
|
-
this.
|
|
977
|
-
suspendResult = this.
|
|
972
|
+
var tmp0 = this.m1j_1;
|
|
973
|
+
var b = get_remaining(this.j1j_1.y1g());
|
|
974
|
+
tmp_0.o1j_1 = tmp0.e1(b) <= 0 ? tmp0 : b;
|
|
975
|
+
this.j1j_1.y1g().w1c(this.k1j_1.a1h(), this.o1j_1);
|
|
976
|
+
this.m1j_1 = this.m1j_1.a3(this.o1j_1);
|
|
977
|
+
this.e9_1 = 5;
|
|
978
|
+
suspendResult = this.k1j_1.x1g(this);
|
|
978
979
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
979
980
|
return suspendResult;
|
|
980
981
|
}
|
|
981
982
|
|
|
982
983
|
continue $sm;
|
|
983
984
|
case 5:
|
|
984
|
-
this.
|
|
985
|
+
this.e9_1 = 2;
|
|
985
986
|
continue $sm;
|
|
986
987
|
case 6:
|
|
987
|
-
this.
|
|
988
|
-
this.
|
|
989
|
-
this.
|
|
988
|
+
this.n1j_1 = Unit_instance;
|
|
989
|
+
this.f9_1 = 12;
|
|
990
|
+
this.e9_1 = 10;
|
|
990
991
|
continue $sm;
|
|
991
992
|
case 7:
|
|
992
|
-
this.
|
|
993
|
-
var tmp_1 = this.
|
|
993
|
+
this.f9_1 = 8;
|
|
994
|
+
var tmp_1 = this.h9_1;
|
|
994
995
|
if (tmp_1 instanceof Error) {
|
|
995
|
-
this.
|
|
996
|
+
this.p1j_1 = this.h9_1;
|
|
996
997
|
var tmp_2 = this;
|
|
997
|
-
this.
|
|
998
|
-
close(this.
|
|
999
|
-
throw this.
|
|
998
|
+
this.j1j_1.h1h(this.p1j_1);
|
|
999
|
+
close(this.k1j_1, this.p1j_1);
|
|
1000
|
+
throw this.p1j_1;
|
|
1000
1001
|
} else {
|
|
1001
|
-
throw this.
|
|
1002
|
+
throw this.h9_1;
|
|
1002
1003
|
}
|
|
1003
1004
|
|
|
1004
1005
|
case 8:
|
|
1005
|
-
this.
|
|
1006
|
-
this.
|
|
1007
|
-
this.
|
|
1008
|
-
suspendResult = this.
|
|
1006
|
+
this.f9_1 = 12;
|
|
1007
|
+
this.q1j_1 = this.h9_1;
|
|
1008
|
+
this.e9_1 = 9;
|
|
1009
|
+
suspendResult = this.k1j_1.x1g(this);
|
|
1009
1010
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1010
1011
|
return suspendResult;
|
|
1011
1012
|
}
|
|
1012
1013
|
|
|
1013
1014
|
continue $sm;
|
|
1014
1015
|
case 9:
|
|
1015
|
-
throw this.
|
|
1016
|
+
throw this.q1j_1;
|
|
1016
1017
|
case 10:
|
|
1017
|
-
this.
|
|
1018
|
-
this.
|
|
1019
|
-
suspendResult = this.
|
|
1018
|
+
this.f9_1 = 12;
|
|
1019
|
+
this.e9_1 = 11;
|
|
1020
|
+
suspendResult = this.k1j_1.x1g(this);
|
|
1020
1021
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1021
1022
|
return suspendResult;
|
|
1022
1023
|
}
|
|
1023
1024
|
|
|
1024
1025
|
continue $sm;
|
|
1025
1026
|
case 11:
|
|
1026
|
-
return this.
|
|
1027
|
+
return this.l1j_1.a3(this.m1j_1);
|
|
1027
1028
|
case 12:
|
|
1028
|
-
throw this.
|
|
1029
|
+
throw this.h9_1;
|
|
1029
1030
|
}
|
|
1030
1031
|
} catch ($p) {
|
|
1031
1032
|
var e = $p;
|
|
1032
|
-
if (this.
|
|
1033
|
+
if (this.f9_1 === 12) {
|
|
1033
1034
|
throw e;
|
|
1034
1035
|
} else {
|
|
1035
|
-
this.
|
|
1036
|
-
this.
|
|
1036
|
+
this.e9_1 = this.f9_1;
|
|
1037
|
+
this.h9_1 = e;
|
|
1037
1038
|
}
|
|
1038
1039
|
}
|
|
1039
1040
|
while (true);
|
|
1040
1041
|
};
|
|
1041
1042
|
function $readBufferCOROUTINE$12(_this__u8e3s4, resultContinuation) {
|
|
1042
1043
|
CoroutineImpl.call(this, resultContinuation);
|
|
1043
|
-
this.
|
|
1044
|
+
this.z1j_1 = _this__u8e3s4;
|
|
1044
1045
|
}
|
|
1045
|
-
protoOf($readBufferCOROUTINE$12).
|
|
1046
|
-
var suspendResult = this.
|
|
1046
|
+
protoOf($readBufferCOROUTINE$12).m9 = function () {
|
|
1047
|
+
var suspendResult = this.g9_1;
|
|
1047
1048
|
$sm: do
|
|
1048
1049
|
try {
|
|
1049
|
-
var tmp = this.
|
|
1050
|
+
var tmp = this.e9_1;
|
|
1050
1051
|
switch (tmp) {
|
|
1051
1052
|
case 0:
|
|
1052
|
-
this.
|
|
1053
|
-
this.
|
|
1054
|
-
this.
|
|
1053
|
+
this.f9_1 = 4;
|
|
1054
|
+
this.a1k_1 = new Buffer();
|
|
1055
|
+
this.e9_1 = 1;
|
|
1055
1056
|
continue $sm;
|
|
1056
1057
|
case 1:
|
|
1057
|
-
if (!!this.
|
|
1058
|
-
this.
|
|
1058
|
+
if (!!this.z1j_1.d1h()) {
|
|
1059
|
+
this.e9_1 = 3;
|
|
1059
1060
|
continue $sm;
|
|
1060
1061
|
}
|
|
1061
1062
|
|
|
1062
|
-
this.
|
|
1063
|
-
this.
|
|
1064
|
-
suspendResult = this.
|
|
1063
|
+
this.a1k_1.l1d(this.z1j_1.y1g());
|
|
1064
|
+
this.e9_1 = 2;
|
|
1065
|
+
suspendResult = this.z1j_1.f1h(VOID, this);
|
|
1065
1066
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1066
1067
|
return suspendResult;
|
|
1067
1068
|
}
|
|
1068
1069
|
|
|
1069
1070
|
continue $sm;
|
|
1070
1071
|
case 2:
|
|
1071
|
-
this.
|
|
1072
|
+
this.e9_1 = 1;
|
|
1072
1073
|
continue $sm;
|
|
1073
1074
|
case 3:
|
|
1074
|
-
var tmp0_safe_receiver = this.
|
|
1075
|
+
var tmp0_safe_receiver = this.z1j_1.z1g();
|
|
1075
1076
|
if (tmp0_safe_receiver == null)
|
|
1076
1077
|
null;
|
|
1077
1078
|
else {
|
|
1078
1079
|
throw tmp0_safe_receiver;
|
|
1079
1080
|
}
|
|
1080
1081
|
|
|
1081
|
-
return this.
|
|
1082
|
+
return this.a1k_1;
|
|
1082
1083
|
case 4:
|
|
1083
|
-
throw this.
|
|
1084
|
+
throw this.h9_1;
|
|
1084
1085
|
}
|
|
1085
1086
|
} catch ($p) {
|
|
1086
1087
|
var e = $p;
|
|
1087
|
-
if (this.
|
|
1088
|
+
if (this.f9_1 === 4) {
|
|
1088
1089
|
throw e;
|
|
1089
1090
|
} else {
|
|
1090
|
-
this.
|
|
1091
|
-
this.
|
|
1091
|
+
this.e9_1 = this.f9_1;
|
|
1092
|
+
this.h9_1 = e;
|
|
1092
1093
|
}
|
|
1093
1094
|
}
|
|
1094
1095
|
while (true);
|
|
1095
1096
|
};
|
|
1096
1097
|
function flushIfNeeded(_this__u8e3s4, $completion) {
|
|
1097
1098
|
var tmp = new $flushIfNeededCOROUTINE$14(_this__u8e3s4, $completion);
|
|
1098
|
-
tmp.
|
|
1099
|
-
tmp.
|
|
1100
|
-
return tmp.
|
|
1099
|
+
tmp.g9_1 = Unit_instance;
|
|
1100
|
+
tmp.h9_1 = null;
|
|
1101
|
+
return tmp.m9();
|
|
1101
1102
|
}
|
|
1102
1103
|
function $flushIfNeededCOROUTINE$14(_this__u8e3s4, resultContinuation) {
|
|
1103
1104
|
CoroutineImpl.call(this, resultContinuation);
|
|
1104
|
-
this.
|
|
1105
|
+
this.j1k_1 = _this__u8e3s4;
|
|
1105
1106
|
}
|
|
1106
|
-
protoOf($flushIfNeededCOROUTINE$14).
|
|
1107
|
-
var suspendResult = this.
|
|
1107
|
+
protoOf($flushIfNeededCOROUTINE$14).m9 = function () {
|
|
1108
|
+
var suspendResult = this.g9_1;
|
|
1108
1109
|
$sm: do
|
|
1109
1110
|
try {
|
|
1110
|
-
var tmp = this.
|
|
1111
|
+
var tmp = this.e9_1;
|
|
1111
1112
|
switch (tmp) {
|
|
1112
1113
|
case 0:
|
|
1113
|
-
this.
|
|
1114
|
-
rethrowCloseCauseIfNeeded_0(this.
|
|
1114
|
+
this.f9_1 = 3;
|
|
1115
|
+
rethrowCloseCauseIfNeeded_0(this.j1k_1);
|
|
1115
1116
|
var tmp_0;
|
|
1116
|
-
var tmp_1 = this.
|
|
1117
|
+
var tmp_1 = this.j1k_1;
|
|
1117
1118
|
var tmp0_safe_receiver = tmp_1 instanceof ByteChannel ? tmp_1 : null;
|
|
1118
|
-
if ((tmp0_safe_receiver == null ? null : tmp0_safe_receiver.
|
|
1119
|
+
if ((tmp0_safe_receiver == null ? null : tmp0_safe_receiver.c1f_1) === true) {
|
|
1119
1120
|
tmp_0 = true;
|
|
1120
1121
|
} else {
|
|
1121
|
-
tmp_0 = get_size(this.
|
|
1122
|
+
tmp_0 = get_size(this.j1k_1.a1h()) >= 1048576;
|
|
1122
1123
|
}
|
|
1123
1124
|
|
|
1124
1125
|
if (tmp_0) {
|
|
1125
|
-
this.
|
|
1126
|
-
suspendResult = this.
|
|
1126
|
+
this.e9_1 = 1;
|
|
1127
|
+
suspendResult = this.j1k_1.x1g(this);
|
|
1127
1128
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1128
1129
|
return suspendResult;
|
|
1129
1130
|
}
|
|
1130
1131
|
continue $sm;
|
|
1131
1132
|
} else {
|
|
1132
|
-
this.
|
|
1133
|
+
this.e9_1 = 2;
|
|
1133
1134
|
continue $sm;
|
|
1134
1135
|
}
|
|
1135
1136
|
|
|
1136
1137
|
case 1:
|
|
1137
|
-
this.
|
|
1138
|
+
this.e9_1 = 2;
|
|
1138
1139
|
continue $sm;
|
|
1139
1140
|
case 2:
|
|
1140
1141
|
return Unit_instance;
|
|
1141
1142
|
case 3:
|
|
1142
|
-
throw this.
|
|
1143
|
+
throw this.h9_1;
|
|
1143
1144
|
}
|
|
1144
1145
|
} catch ($p) {
|
|
1145
1146
|
var e = $p;
|
|
1146
|
-
if (this.
|
|
1147
|
+
if (this.f9_1 === 3) {
|
|
1147
1148
|
throw e;
|
|
1148
1149
|
} else {
|
|
1149
|
-
this.
|
|
1150
|
-
this.
|
|
1150
|
+
this.e9_1 = this.f9_1;
|
|
1151
|
+
this.h9_1 = e;
|
|
1151
1152
|
}
|
|
1152
1153
|
}
|
|
1153
1154
|
while (true);
|
|
@@ -1158,11 +1159,11 @@
|
|
|
1158
1159
|
}
|
|
1159
1160
|
var NO_CALLBACK;
|
|
1160
1161
|
function WriterJob(channel, job) {
|
|
1161
|
-
this.
|
|
1162
|
-
this.
|
|
1162
|
+
this.k1k_1 = channel;
|
|
1163
|
+
this.l1k_1 = job;
|
|
1163
1164
|
}
|
|
1164
|
-
protoOf(WriterJob).
|
|
1165
|
-
return this.
|
|
1165
|
+
protoOf(WriterJob).zt = function () {
|
|
1166
|
+
return this.l1k_1;
|
|
1166
1167
|
};
|
|
1167
1168
|
function writer(_this__u8e3s4, coroutineContext, autoFlush, block) {
|
|
1168
1169
|
coroutineContext = coroutineContext === VOID ? EmptyCoroutineContext_getInstance() : coroutineContext;
|
|
@@ -1171,47 +1172,46 @@
|
|
|
1171
1172
|
return writer_0(_this__u8e3s4, coroutineContext, new ByteChannel(), block);
|
|
1172
1173
|
}
|
|
1173
1174
|
function WriterScope(channel, coroutineContext) {
|
|
1174
|
-
this.
|
|
1175
|
-
this.
|
|
1175
|
+
this.m1k_1 = channel;
|
|
1176
|
+
this.n1k_1 = coroutineContext;
|
|
1176
1177
|
}
|
|
1177
|
-
protoOf(WriterScope).
|
|
1178
|
-
return this.
|
|
1178
|
+
protoOf(WriterScope).ao = function () {
|
|
1179
|
+
return this.n1k_1;
|
|
1179
1180
|
};
|
|
1180
1181
|
function writeFully(_this__u8e3s4, value, startIndex, endIndex, $completion) {
|
|
1181
1182
|
startIndex = startIndex === VOID ? 0 : startIndex;
|
|
1182
1183
|
endIndex = endIndex === VOID ? value.length : endIndex;
|
|
1183
|
-
_this__u8e3s4.
|
|
1184
|
+
_this__u8e3s4.a1h().d1d(value, startIndex, endIndex);
|
|
1184
1185
|
return flushIfNeeded(_this__u8e3s4, $completion);
|
|
1185
1186
|
}
|
|
1186
1187
|
function writePacket(_this__u8e3s4, copy, $completion) {
|
|
1187
|
-
_this__u8e3s4.
|
|
1188
|
+
_this__u8e3s4.a1h().l1d(copy);
|
|
1188
1189
|
return flushIfNeeded(_this__u8e3s4, $completion);
|
|
1189
1190
|
}
|
|
1190
1191
|
function get_isCompleted(_this__u8e3s4) {
|
|
1191
1192
|
_init_properties_ByteWriteChannelOperations_kt__i7slrs();
|
|
1192
|
-
return _this__u8e3s4.
|
|
1193
|
+
return _this__u8e3s4.zt().vo();
|
|
1193
1194
|
}
|
|
1194
1195
|
function close(_this__u8e3s4, cause) {
|
|
1195
1196
|
_init_properties_ByteWriteChannelOperations_kt__i7slrs();
|
|
1196
1197
|
if (cause == null) {
|
|
1197
1198
|
fireAndForget(ByteWriteChannel$flushAndClose$ref_0(_this__u8e3s4));
|
|
1198
1199
|
} else {
|
|
1199
|
-
_this__u8e3s4.
|
|
1200
|
+
_this__u8e3s4.h1h(cause);
|
|
1200
1201
|
}
|
|
1201
1202
|
}
|
|
1202
1203
|
function invokeOnCompletion(_this__u8e3s4, block) {
|
|
1203
1204
|
_init_properties_ByteWriteChannelOperations_kt__i7slrs();
|
|
1204
|
-
var tmp = _this__u8e3s4.
|
|
1205
|
-
tmp.
|
|
1205
|
+
var tmp = _this__u8e3s4.zt();
|
|
1206
|
+
tmp.cp(invokeOnCompletion$lambda(block));
|
|
1206
1207
|
}
|
|
1207
1208
|
function writer_0(_this__u8e3s4, coroutineContext, channel, block) {
|
|
1208
1209
|
coroutineContext = coroutineContext === VOID ? EmptyCoroutineContext_getInstance() : coroutineContext;
|
|
1209
1210
|
_init_properties_ByteWriteChannelOperations_kt__i7slrs();
|
|
1210
1211
|
// Inline function 'kotlin.apply' call
|
|
1211
1212
|
var this_0 = launch(_this__u8e3s4, coroutineContext, VOID, writer$slambda_0(block, channel, null));
|
|
1212
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1213
1213
|
// Inline function 'io.ktor.utils.io.writer.<anonymous>' call
|
|
1214
|
-
this_0.
|
|
1214
|
+
this_0.cp(writer$lambda(channel));
|
|
1215
1215
|
var job = this_0;
|
|
1216
1216
|
return new WriterJob(channel, job);
|
|
1217
1217
|
}
|
|
@@ -1220,30 +1220,30 @@
|
|
|
1220
1220
|
startCoroutineCancellable(_this__u8e3s4, get_NO_CALLBACK());
|
|
1221
1221
|
}
|
|
1222
1222
|
function NO_CALLBACK$1() {
|
|
1223
|
-
this.
|
|
1223
|
+
this.o1k_1 = EmptyCoroutineContext_getInstance();
|
|
1224
1224
|
}
|
|
1225
|
-
protoOf(NO_CALLBACK$1).
|
|
1226
|
-
return this.
|
|
1225
|
+
protoOf(NO_CALLBACK$1).k9 = function () {
|
|
1226
|
+
return this.o1k_1;
|
|
1227
1227
|
};
|
|
1228
|
-
protoOf(NO_CALLBACK$1).
|
|
1228
|
+
protoOf(NO_CALLBACK$1).l9 = function (result) {
|
|
1229
1229
|
return Unit_instance;
|
|
1230
1230
|
};
|
|
1231
|
-
protoOf(NO_CALLBACK$1).
|
|
1232
|
-
return this.
|
|
1231
|
+
protoOf(NO_CALLBACK$1).p9 = function (result) {
|
|
1232
|
+
return this.l9(result);
|
|
1233
1233
|
};
|
|
1234
1234
|
function ByteWriteChannel$flushAndClose$ref($boundThis) {
|
|
1235
|
-
this.
|
|
1235
|
+
this.p1k_1 = $boundThis;
|
|
1236
1236
|
}
|
|
1237
|
-
protoOf(ByteWriteChannel$flushAndClose$ref).
|
|
1238
|
-
return this.
|
|
1237
|
+
protoOf(ByteWriteChannel$flushAndClose$ref).q1k = function ($completion) {
|
|
1238
|
+
return this.p1k_1.g1h($completion);
|
|
1239
1239
|
};
|
|
1240
|
-
protoOf(ByteWriteChannel$flushAndClose$ref).
|
|
1241
|
-
return this.
|
|
1240
|
+
protoOf(ByteWriteChannel$flushAndClose$ref).bb = function ($completion) {
|
|
1241
|
+
return this.q1k($completion);
|
|
1242
1242
|
};
|
|
1243
1243
|
function ByteWriteChannel$flushAndClose$ref_0($boundThis) {
|
|
1244
1244
|
var i = new ByteWriteChannel$flushAndClose$ref($boundThis);
|
|
1245
1245
|
var l = function ($completion) {
|
|
1246
|
-
return i.
|
|
1246
|
+
return i.q1k($completion);
|
|
1247
1247
|
};
|
|
1248
1248
|
l.callableName = 'flushAndClose';
|
|
1249
1249
|
l.$arity = 0;
|
|
@@ -1256,74 +1256,74 @@
|
|
|
1256
1256
|
};
|
|
1257
1257
|
}
|
|
1258
1258
|
function writer$slambda($block, $channel, resultContinuation) {
|
|
1259
|
-
this.
|
|
1260
|
-
this.
|
|
1259
|
+
this.z1k_1 = $block;
|
|
1260
|
+
this.a1l_1 = $channel;
|
|
1261
1261
|
CoroutineImpl.call(this, resultContinuation);
|
|
1262
1262
|
}
|
|
1263
|
-
protoOf(writer$slambda).
|
|
1264
|
-
var tmp = this.
|
|
1265
|
-
tmp.
|
|
1266
|
-
tmp.
|
|
1267
|
-
return tmp.
|
|
1263
|
+
protoOf(writer$slambda).u1l = function ($this$launch, $completion) {
|
|
1264
|
+
var tmp = this.v1l($this$launch, $completion);
|
|
1265
|
+
tmp.g9_1 = Unit_instance;
|
|
1266
|
+
tmp.h9_1 = null;
|
|
1267
|
+
return tmp.m9();
|
|
1268
1268
|
};
|
|
1269
|
-
protoOf(writer$slambda).
|
|
1270
|
-
return this.
|
|
1269
|
+
protoOf(writer$slambda).w9 = function (p1, $completion) {
|
|
1270
|
+
return this.u1l((!(p1 == null) ? isInterface(p1, CoroutineScope) : false) ? p1 : THROW_CCE(), $completion);
|
|
1271
1271
|
};
|
|
1272
|
-
protoOf(writer$slambda).
|
|
1273
|
-
var suspendResult = this.
|
|
1272
|
+
protoOf(writer$slambda).m9 = function () {
|
|
1273
|
+
var suspendResult = this.g9_1;
|
|
1274
1274
|
$sm: do
|
|
1275
1275
|
try {
|
|
1276
|
-
var tmp = this.
|
|
1276
|
+
var tmp = this.e9_1;
|
|
1277
1277
|
switch (tmp) {
|
|
1278
1278
|
case 0:
|
|
1279
|
-
this.
|
|
1280
|
-
this.
|
|
1281
|
-
this.
|
|
1279
|
+
this.f9_1 = 14;
|
|
1280
|
+
this.c1l_1 = Job(get_job(this.b1l_1.ao()));
|
|
1281
|
+
this.e9_1 = 1;
|
|
1282
1282
|
continue $sm;
|
|
1283
1283
|
case 1:
|
|
1284
|
-
this.
|
|
1285
|
-
this.
|
|
1286
|
-
this.
|
|
1287
|
-
suspendResult = this.
|
|
1284
|
+
this.f9_1 = 4;
|
|
1285
|
+
this.f9_1 = 3;
|
|
1286
|
+
this.e9_1 = 2;
|
|
1287
|
+
suspendResult = this.z1k_1(new WriterScope(this.a1l_1, this.b1l_1.ao().jh(this.c1l_1)), this);
|
|
1288
1288
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1289
1289
|
return suspendResult;
|
|
1290
1290
|
}
|
|
1291
1291
|
|
|
1292
1292
|
continue $sm;
|
|
1293
1293
|
case 2:
|
|
1294
|
-
this.
|
|
1294
|
+
this.c1l_1.vu();
|
|
1295
1295
|
var tmp_0 = this;
|
|
1296
1296
|
var tmp_1;
|
|
1297
|
-
if (get_job(this.
|
|
1298
|
-
this.
|
|
1297
|
+
if (get_job(this.b1l_1.ao()).wo()) {
|
|
1298
|
+
this.a1l_1.h1h(get_job(this.b1l_1.ao()).zo());
|
|
1299
1299
|
tmp_1 = Unit_instance;
|
|
1300
1300
|
}
|
|
1301
1301
|
|
|
1302
|
-
tmp_0.
|
|
1303
|
-
this.
|
|
1304
|
-
this.
|
|
1302
|
+
tmp_0.d1l_1 = tmp_1;
|
|
1303
|
+
this.f9_1 = 14;
|
|
1304
|
+
this.e9_1 = 9;
|
|
1305
1305
|
continue $sm;
|
|
1306
1306
|
case 3:
|
|
1307
|
-
this.
|
|
1308
|
-
var tmp_2 = this.
|
|
1307
|
+
this.f9_1 = 4;
|
|
1308
|
+
var tmp_2 = this.h9_1;
|
|
1309
1309
|
if (tmp_2 instanceof Error) {
|
|
1310
|
-
this.
|
|
1310
|
+
this.e1l_1 = this.h9_1;
|
|
1311
1311
|
var tmp_3 = this;
|
|
1312
|
-
cancel(this.
|
|
1313
|
-
this.
|
|
1314
|
-
tmp_3.
|
|
1315
|
-
this.
|
|
1316
|
-
this.
|
|
1312
|
+
cancel(this.c1l_1, 'Exception thrown while writing to channel', this.e1l_1);
|
|
1313
|
+
this.a1l_1.h1h(this.e1l_1);
|
|
1314
|
+
tmp_3.d1l_1 = Unit_instance;
|
|
1315
|
+
this.f9_1 = 14;
|
|
1316
|
+
this.e9_1 = 9;
|
|
1317
1317
|
continue $sm;
|
|
1318
1318
|
} else {
|
|
1319
|
-
throw this.
|
|
1319
|
+
throw this.h9_1;
|
|
1320
1320
|
}
|
|
1321
1321
|
|
|
1322
1322
|
case 4:
|
|
1323
|
-
this.
|
|
1324
|
-
this.
|
|
1325
|
-
this.
|
|
1326
|
-
suspendResult = this.
|
|
1323
|
+
this.f9_1 = 14;
|
|
1324
|
+
this.f1l_1 = this.h9_1;
|
|
1325
|
+
this.e9_1 = 5;
|
|
1326
|
+
suspendResult = this.c1l_1.wu(this);
|
|
1327
1327
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1328
1328
|
return suspendResult;
|
|
1329
1329
|
}
|
|
@@ -1331,14 +1331,16 @@
|
|
|
1331
1331
|
continue $sm;
|
|
1332
1332
|
case 5:
|
|
1333
1333
|
var tmp_4 = this;
|
|
1334
|
-
tmp_4.
|
|
1335
|
-
this.
|
|
1334
|
+
tmp_4.g1l_1 = this.b1l_1;
|
|
1335
|
+
this.h1l_1 = this.g1l_1;
|
|
1336
|
+
this.f9_1 = 7;
|
|
1336
1337
|
var tmp_5 = this;
|
|
1337
|
-
tmp_5.
|
|
1338
|
+
tmp_5.j1l_1 = Companion_instance;
|
|
1338
1339
|
var tmp_6 = this;
|
|
1339
|
-
tmp_6.
|
|
1340
|
-
this.
|
|
1341
|
-
|
|
1340
|
+
tmp_6.k1l_1 = this.h1l_1;
|
|
1341
|
+
this.l1l_1 = this.k1l_1;
|
|
1342
|
+
this.e9_1 = 6;
|
|
1343
|
+
suspendResult = this.a1l_1.g1h(this);
|
|
1342
1344
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1343
1345
|
return suspendResult;
|
|
1344
1346
|
}
|
|
@@ -1346,96 +1348,103 @@
|
|
|
1346
1348
|
continue $sm;
|
|
1347
1349
|
case 6:
|
|
1348
1350
|
var tmp_7 = this;
|
|
1349
|
-
tmp_7.
|
|
1350
|
-
|
|
1351
|
-
this.
|
|
1352
|
-
|
|
1351
|
+
tmp_7.m1l_1 = Unit_instance;
|
|
1352
|
+
var tmp_8 = this;
|
|
1353
|
+
this.j1l_1;
|
|
1354
|
+
var value = this.m1l_1;
|
|
1355
|
+
tmp_8.i1l_1 = _Result___init__impl__xyqfz8(value);
|
|
1356
|
+
this.f9_1 = 14;
|
|
1357
|
+
this.e9_1 = 8;
|
|
1353
1358
|
continue $sm;
|
|
1354
1359
|
case 7:
|
|
1355
|
-
this.
|
|
1356
|
-
var
|
|
1357
|
-
if (
|
|
1358
|
-
this.
|
|
1359
|
-
var
|
|
1360
|
-
var exception = this.
|
|
1361
|
-
|
|
1362
|
-
this.
|
|
1360
|
+
this.f9_1 = 14;
|
|
1361
|
+
var tmp_9 = this.h9_1;
|
|
1362
|
+
if (tmp_9 instanceof Error) {
|
|
1363
|
+
this.n1l_1 = this.h9_1;
|
|
1364
|
+
var tmp_10 = this;
|
|
1365
|
+
var exception = this.n1l_1;
|
|
1366
|
+
tmp_10.i1l_1 = _Result___init__impl__xyqfz8(createFailure(exception));
|
|
1367
|
+
this.e9_1 = 8;
|
|
1363
1368
|
continue $sm;
|
|
1364
1369
|
} else {
|
|
1365
|
-
throw this.
|
|
1370
|
+
throw this.h9_1;
|
|
1366
1371
|
}
|
|
1367
1372
|
|
|
1368
1373
|
case 8:
|
|
1369
|
-
this.
|
|
1370
|
-
throw this.
|
|
1374
|
+
this.f9_1 = 14;
|
|
1375
|
+
throw this.f1l_1;
|
|
1371
1376
|
case 9:
|
|
1372
|
-
this.
|
|
1373
|
-
this.
|
|
1374
|
-
suspendResult = this.
|
|
1377
|
+
this.f9_1 = 14;
|
|
1378
|
+
this.e9_1 = 10;
|
|
1379
|
+
suspendResult = this.c1l_1.wu(this);
|
|
1375
1380
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1376
1381
|
return suspendResult;
|
|
1377
1382
|
}
|
|
1378
1383
|
|
|
1379
1384
|
continue $sm;
|
|
1380
1385
|
case 10:
|
|
1381
|
-
var tmp_10 = this;
|
|
1382
|
-
tmp_10.h1k_1 = this.w1j_1;
|
|
1383
|
-
this.e9_1 = 12;
|
|
1384
1386
|
var tmp_11 = this;
|
|
1385
|
-
tmp_11.
|
|
1387
|
+
tmp_11.o1l_1 = this.b1l_1;
|
|
1388
|
+
this.p1l_1 = this.o1l_1;
|
|
1389
|
+
this.f9_1 = 12;
|
|
1386
1390
|
var tmp_12 = this;
|
|
1387
|
-
tmp_12.
|
|
1388
|
-
|
|
1389
|
-
|
|
1391
|
+
tmp_12.r1l_1 = Companion_instance;
|
|
1392
|
+
var tmp_13 = this;
|
|
1393
|
+
tmp_13.s1l_1 = this.p1l_1;
|
|
1394
|
+
this.t1l_1 = this.s1l_1;
|
|
1395
|
+
this.e9_1 = 11;
|
|
1396
|
+
suspendResult = this.a1l_1.g1h(this);
|
|
1390
1397
|
if (suspendResult === get_COROUTINE_SUSPENDED()) {
|
|
1391
1398
|
return suspendResult;
|
|
1392
1399
|
}
|
|
1393
1400
|
|
|
1394
1401
|
continue $sm;
|
|
1395
1402
|
case 11:
|
|
1396
|
-
|
|
1397
|
-
this.
|
|
1398
|
-
|
|
1403
|
+
var tmp_14 = this;
|
|
1404
|
+
this.r1l_1;
|
|
1405
|
+
tmp_14.q1l_1 = _Result___init__impl__xyqfz8(Unit_instance);
|
|
1406
|
+
this.f9_1 = 14;
|
|
1407
|
+
this.e9_1 = 13;
|
|
1399
1408
|
continue $sm;
|
|
1400
1409
|
case 12:
|
|
1401
|
-
this.
|
|
1402
|
-
var
|
|
1403
|
-
if (
|
|
1404
|
-
var e = this.
|
|
1405
|
-
var
|
|
1406
|
-
|
|
1407
|
-
this.
|
|
1410
|
+
this.f9_1 = 14;
|
|
1411
|
+
var tmp_15 = this.h9_1;
|
|
1412
|
+
if (tmp_15 instanceof Error) {
|
|
1413
|
+
var e = this.h9_1;
|
|
1414
|
+
var tmp_16 = this;
|
|
1415
|
+
tmp_16.q1l_1 = _Result___init__impl__xyqfz8(createFailure(e));
|
|
1416
|
+
this.e9_1 = 13;
|
|
1408
1417
|
continue $sm;
|
|
1409
1418
|
} else {
|
|
1410
|
-
throw this.
|
|
1419
|
+
throw this.h9_1;
|
|
1411
1420
|
}
|
|
1412
1421
|
|
|
1413
1422
|
case 13:
|
|
1414
|
-
this.
|
|
1423
|
+
this.f9_1 = 14;
|
|
1415
1424
|
return Unit_instance;
|
|
1416
1425
|
case 14:
|
|
1417
|
-
throw this.
|
|
1426
|
+
throw this.h9_1;
|
|
1418
1427
|
}
|
|
1419
1428
|
} catch ($p) {
|
|
1420
1429
|
var e_0 = $p;
|
|
1421
|
-
if (this.
|
|
1430
|
+
if (this.f9_1 === 14) {
|
|
1422
1431
|
throw e_0;
|
|
1423
1432
|
} else {
|
|
1424
|
-
this.
|
|
1425
|
-
this.
|
|
1433
|
+
this.e9_1 = this.f9_1;
|
|
1434
|
+
this.h9_1 = e_0;
|
|
1426
1435
|
}
|
|
1427
1436
|
}
|
|
1428
1437
|
while (true);
|
|
1429
1438
|
};
|
|
1430
|
-
protoOf(writer$slambda).
|
|
1431
|
-
var i = new writer$slambda(this.
|
|
1432
|
-
i.
|
|
1439
|
+
protoOf(writer$slambda).v1l = function ($this$launch, completion) {
|
|
1440
|
+
var i = new writer$slambda(this.z1k_1, this.a1l_1, completion);
|
|
1441
|
+
i.b1l_1 = $this$launch;
|
|
1433
1442
|
return i;
|
|
1434
1443
|
};
|
|
1435
1444
|
function writer$slambda_0($block, $channel, resultContinuation) {
|
|
1436
1445
|
var i = new writer$slambda($block, $channel, resultContinuation);
|
|
1437
1446
|
var l = function ($this$launch, $completion) {
|
|
1438
|
-
return i.
|
|
1447
|
+
return i.u1l($this$launch, $completion);
|
|
1439
1448
|
};
|
|
1440
1449
|
l.$arity = 1;
|
|
1441
1450
|
return l;
|
|
@@ -1443,8 +1452,8 @@
|
|
|
1443
1452
|
function writer$lambda($channel) {
|
|
1444
1453
|
return function (it) {
|
|
1445
1454
|
var tmp;
|
|
1446
|
-
if (!(it == null) && !$channel.
|
|
1447
|
-
$channel.
|
|
1455
|
+
if (!(it == null) && !$channel.b1h()) {
|
|
1456
|
+
$channel.h1h(it);
|
|
1448
1457
|
tmp = Unit_instance;
|
|
1449
1458
|
}
|
|
1450
1459
|
return Unit_instance;
|
|
@@ -1471,7 +1480,7 @@
|
|
|
1471
1480
|
if (origin instanceof CancellationException) {
|
|
1472
1481
|
var tmp_1;
|
|
1473
1482
|
if (isInterface(origin, CopyableThrowable)) {
|
|
1474
|
-
tmp_1 = origin.
|
|
1483
|
+
tmp_1 = origin.ev();
|
|
1475
1484
|
} else {
|
|
1476
1485
|
var tmp0_elvis_lhs = origin.message;
|
|
1477
1486
|
tmp_1 = CancellationException_init_$Create$(tmp0_elvis_lhs == null ? 'Channel was cancelled' : tmp0_elvis_lhs, origin);
|
|
@@ -1485,37 +1494,37 @@
|
|
|
1485
1494
|
tmp_2 = false;
|
|
1486
1495
|
}
|
|
1487
1496
|
if (tmp_2) {
|
|
1488
|
-
tmp_0 = origin.
|
|
1497
|
+
tmp_0 = origin.ev();
|
|
1489
1498
|
} else {
|
|
1490
1499
|
var tmp1_elvis_lhs = origin.message;
|
|
1491
1500
|
tmp_0 = IOException_init_$Create$_0(tmp1_elvis_lhs == null ? 'Channel was closed' : tmp1_elvis_lhs, origin);
|
|
1492
1501
|
}
|
|
1493
1502
|
}
|
|
1494
1503
|
}
|
|
1495
|
-
tmp.
|
|
1504
|
+
tmp.c1h_1 = tmp_0;
|
|
1496
1505
|
}
|
|
1497
|
-
protoOf(CloseToken).
|
|
1506
|
+
protoOf(CloseToken).v9 = function () {
|
|
1498
1507
|
var tmp;
|
|
1499
|
-
if (this.
|
|
1508
|
+
if (this.c1h_1 == null) {
|
|
1500
1509
|
tmp = null;
|
|
1501
1510
|
} else {
|
|
1502
|
-
var tmp_0 = this.
|
|
1511
|
+
var tmp_0 = this.c1h_1;
|
|
1503
1512
|
if (tmp_0 instanceof IOException) {
|
|
1504
1513
|
var tmp_1;
|
|
1505
|
-
var tmp_2 = this.
|
|
1514
|
+
var tmp_2 = this.c1h_1;
|
|
1506
1515
|
if (isInterface(tmp_2, CopyableThrowable)) {
|
|
1507
|
-
tmp_1 = this.
|
|
1516
|
+
tmp_1 = this.c1h_1.ev();
|
|
1508
1517
|
} else {
|
|
1509
|
-
tmp_1 = IOException_init_$Create$_0(this.
|
|
1518
|
+
tmp_1 = IOException_init_$Create$_0(this.c1h_1.message, this.c1h_1);
|
|
1510
1519
|
}
|
|
1511
1520
|
tmp = tmp_1;
|
|
1512
1521
|
} else {
|
|
1513
|
-
var tmp_3 = this.
|
|
1522
|
+
var tmp_3 = this.c1h_1;
|
|
1514
1523
|
if (!(tmp_3 == null) ? isInterface(tmp_3, CopyableThrowable) : false) {
|
|
1515
|
-
var tmp0_elvis_lhs = this.
|
|
1516
|
-
tmp = tmp0_elvis_lhs == null ? CancellationException_init_$Create$(this.
|
|
1524
|
+
var tmp0_elvis_lhs = this.c1h_1.ev();
|
|
1525
|
+
tmp = tmp0_elvis_lhs == null ? CancellationException_init_$Create$(this.c1h_1.message, this.c1h_1) : tmp0_elvis_lhs;
|
|
1517
1526
|
} else {
|
|
1518
|
-
tmp = CancellationException_init_$Create$(this.
|
|
1527
|
+
tmp = CancellationException_init_$Create$(this.c1h_1.message, this.c1h_1);
|
|
1519
1528
|
}
|
|
1520
1529
|
}
|
|
1521
1530
|
}
|
|
@@ -1532,57 +1541,53 @@
|
|
|
1532
1541
|
return readString(_this__u8e3s4);
|
|
1533
1542
|
}
|
|
1534
1543
|
function SourceByteReadChannel(source) {
|
|
1535
|
-
this.
|
|
1536
|
-
this.
|
|
1544
|
+
this.w1l_1 = source;
|
|
1545
|
+
this.x1l_1 = null;
|
|
1537
1546
|
}
|
|
1538
|
-
protoOf(SourceByteReadChannel).
|
|
1539
|
-
var tmp0_safe_receiver = this.
|
|
1540
|
-
return tmp0_safe_receiver == null ? null : tmp0_safe_receiver.
|
|
1547
|
+
protoOf(SourceByteReadChannel).z1g = function () {
|
|
1548
|
+
var tmp0_safe_receiver = this.x1l_1;
|
|
1549
|
+
return tmp0_safe_receiver == null ? null : tmp0_safe_receiver.v9();
|
|
1541
1550
|
};
|
|
1542
|
-
protoOf(SourceByteReadChannel).
|
|
1543
|
-
return this.
|
|
1551
|
+
protoOf(SourceByteReadChannel).d1h = function () {
|
|
1552
|
+
return this.w1l_1.v1b();
|
|
1544
1553
|
};
|
|
1545
|
-
protoOf(SourceByteReadChannel).
|
|
1546
|
-
var tmp0_safe_receiver = this.
|
|
1554
|
+
protoOf(SourceByteReadChannel).y1g = function () {
|
|
1555
|
+
var tmp0_safe_receiver = this.z1g();
|
|
1547
1556
|
if (tmp0_safe_receiver == null)
|
|
1548
1557
|
null;
|
|
1549
1558
|
else {
|
|
1550
1559
|
// Inline function 'kotlin.let' call
|
|
1551
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1552
1560
|
throw tmp0_safe_receiver;
|
|
1553
1561
|
}
|
|
1554
|
-
return this.
|
|
1562
|
+
return this.w1l_1;
|
|
1555
1563
|
};
|
|
1556
|
-
protoOf(SourceByteReadChannel).
|
|
1557
|
-
var tmp0_safe_receiver = this.
|
|
1564
|
+
protoOf(SourceByteReadChannel).e1h = function (min, $completion) {
|
|
1565
|
+
var tmp0_safe_receiver = this.z1g();
|
|
1558
1566
|
if (tmp0_safe_receiver == null)
|
|
1559
1567
|
null;
|
|
1560
1568
|
else {
|
|
1561
1569
|
// Inline function 'kotlin.let' call
|
|
1562
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1563
1570
|
throw tmp0_safe_receiver;
|
|
1564
1571
|
}
|
|
1565
|
-
return get_remaining(this.
|
|
1572
|
+
return get_remaining(this.w1l_1).e1(toLong(min)) >= 0;
|
|
1566
1573
|
};
|
|
1567
|
-
protoOf(SourceByteReadChannel).
|
|
1568
|
-
if (!(this.
|
|
1574
|
+
protoOf(SourceByteReadChannel).h1h = function (cause) {
|
|
1575
|
+
if (!(this.x1l_1 == null))
|
|
1569
1576
|
return Unit_instance;
|
|
1570
|
-
this.
|
|
1577
|
+
this.w1l_1.q1d();
|
|
1571
1578
|
var tmp = this;
|
|
1572
1579
|
var tmp1_elvis_lhs = cause == null ? null : cause.message;
|
|
1573
|
-
tmp.
|
|
1580
|
+
tmp.x1l_1 = new CloseToken(IOException_init_$Create$_0(tmp1_elvis_lhs == null ? 'Channel was cancelled' : tmp1_elvis_lhs, cause));
|
|
1574
1581
|
};
|
|
1575
1582
|
function decode(_this__u8e3s4, input, max) {
|
|
1576
1583
|
max = max === VOID ? 2147483647 : max;
|
|
1577
|
-
|
|
1584
|
+
var tmp0 = toLong(max);
|
|
1578
1585
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
1579
|
-
var
|
|
1580
|
-
|
|
1581
|
-
var capacity = (
|
|
1582
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1586
|
+
var b = input.u1b().s();
|
|
1587
|
+
// Inline function 'kotlin.text.buildString' call
|
|
1588
|
+
var capacity = (tmp0.e1(b) <= 0 ? tmp0 : b).j1();
|
|
1583
1589
|
// Inline function 'kotlin.apply' call
|
|
1584
1590
|
var this_0 = StringBuilder_init_$Create$(capacity);
|
|
1585
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1586
1591
|
// Inline function 'io.ktor.utils.io.charsets.decode.<anonymous>' call
|
|
1587
1592
|
decode_0(_this__u8e3s4, input, this_0, max);
|
|
1588
1593
|
return this_0.toString();
|
|
@@ -1594,13 +1599,8 @@
|
|
|
1594
1599
|
$l$loop: while (true) {
|
|
1595
1600
|
var rc = encodeImpl(_this__u8e3s4, input, start, toIndex, destination);
|
|
1596
1601
|
// Inline function 'kotlin.check' call
|
|
1597
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1598
|
-
// Inline function 'kotlin.check' call
|
|
1599
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1600
1602
|
if (!(rc >= 0)) {
|
|
1601
|
-
|
|
1602
|
-
var message = 'Check failed.';
|
|
1603
|
-
throw IllegalStateException_init_$Create$(toString_0(message));
|
|
1603
|
+
throw IllegalStateException_init_$Create$('Check failed.');
|
|
1604
1604
|
}
|
|
1605
1605
|
start = start + rc | 0;
|
|
1606
1606
|
if (start >= toIndex)
|
|
@@ -1617,7 +1617,7 @@
|
|
|
1617
1617
|
return builder;
|
|
1618
1618
|
}
|
|
1619
1619
|
function canRead(_this__u8e3s4) {
|
|
1620
|
-
return !_this__u8e3s4.
|
|
1620
|
+
return !_this__u8e3s4.v1b();
|
|
1621
1621
|
}
|
|
1622
1622
|
function readBytes(_this__u8e3s4, count) {
|
|
1623
1623
|
count = count === VOID ? _this__u8e3s4.s().j1() : count;
|
|
@@ -1627,37 +1627,37 @@
|
|
|
1627
1627
|
return new Buffer();
|
|
1628
1628
|
}
|
|
1629
1629
|
function writePacket_0(_this__u8e3s4, packet) {
|
|
1630
|
-
_this__u8e3s4.
|
|
1630
|
+
_this__u8e3s4.l1d(packet);
|
|
1631
1631
|
}
|
|
1632
1632
|
function build(_this__u8e3s4) {
|
|
1633
|
-
return _this__u8e3s4.
|
|
1633
|
+
return _this__u8e3s4.u1b();
|
|
1634
1634
|
}
|
|
1635
1635
|
function get_size(_this__u8e3s4) {
|
|
1636
|
-
return _this__u8e3s4.
|
|
1636
|
+
return _this__u8e3s4.u1b().s().j1();
|
|
1637
1637
|
}
|
|
1638
1638
|
function writeFully_0(_this__u8e3s4, buffer, offset, length) {
|
|
1639
1639
|
offset = offset === VOID ? 0 : offset;
|
|
1640
1640
|
length = length === VOID ? buffer.length - offset | 0 : length;
|
|
1641
|
-
_this__u8e3s4.
|
|
1641
|
+
_this__u8e3s4.d1d(buffer, offset, offset + length | 0);
|
|
1642
1642
|
}
|
|
1643
1643
|
var ByteReadPacketEmpty;
|
|
1644
1644
|
function get_remaining(_this__u8e3s4) {
|
|
1645
1645
|
_init_properties_ByteReadPacket_kt__28475y();
|
|
1646
|
-
return _this__u8e3s4.
|
|
1646
|
+
return _this__u8e3s4.u1b().s();
|
|
1647
1647
|
}
|
|
1648
1648
|
function discard(_this__u8e3s4, count) {
|
|
1649
1649
|
count = count === VOID ? new Long(-1, 2147483647) : count;
|
|
1650
1650
|
_init_properties_ByteReadPacket_kt__28475y();
|
|
1651
|
-
_this__u8e3s4.
|
|
1651
|
+
_this__u8e3s4.x1b(count);
|
|
1652
1652
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
1653
1653
|
var b = get_remaining(_this__u8e3s4);
|
|
1654
1654
|
var countToDiscard = count.e1(b) <= 0 ? count : b;
|
|
1655
|
-
_this__u8e3s4.
|
|
1655
|
+
_this__u8e3s4.u1b().r1c(countToDiscard);
|
|
1656
1656
|
return countToDiscard;
|
|
1657
1657
|
}
|
|
1658
1658
|
function takeWhile(_this__u8e3s4, block) {
|
|
1659
1659
|
_init_properties_ByteReadPacket_kt__28475y();
|
|
1660
|
-
while (!_this__u8e3s4.
|
|
1660
|
+
while (!_this__u8e3s4.v1b() && block(_this__u8e3s4.u1b())) {
|
|
1661
1661
|
}
|
|
1662
1662
|
}
|
|
1663
1663
|
var properties_initialized_ByteReadPacket_kt_hw4st4;
|
|
@@ -1670,37 +1670,37 @@
|
|
|
1670
1670
|
function readAvailable_0(_this__u8e3s4, buffer, offset, length) {
|
|
1671
1671
|
offset = offset === VOID ? 0 : offset;
|
|
1672
1672
|
length = length === VOID ? buffer.length - offset | 0 : length;
|
|
1673
|
-
var result = _this__u8e3s4.
|
|
1673
|
+
var result = _this__u8e3s4.s1c(buffer, offset, offset + length | 0);
|
|
1674
1674
|
return result === -1 ? 0 : result;
|
|
1675
1675
|
}
|
|
1676
1676
|
function readText_0(_this__u8e3s4, charset, max) {
|
|
1677
|
-
charset = charset === VOID ? Charsets_getInstance().
|
|
1677
|
+
charset = charset === VOID ? Charsets_getInstance().y1l_1 : charset;
|
|
1678
1678
|
max = max === VOID ? 2147483647 : max;
|
|
1679
|
-
if (charset.equals(Charsets_getInstance().
|
|
1679
|
+
if (charset.equals(Charsets_getInstance().y1l_1)) {
|
|
1680
1680
|
if (max === 2147483647)
|
|
1681
1681
|
return readString(_this__u8e3s4);
|
|
1682
|
+
var tmp0 = _this__u8e3s4.u1b().s();
|
|
1682
1683
|
// Inline function 'kotlin.math.min' call
|
|
1683
|
-
var a = _this__u8e3s4.t1a().s();
|
|
1684
1684
|
var b = toLong(max);
|
|
1685
|
-
var count =
|
|
1685
|
+
var count = tmp0.e1(b) <= 0 ? tmp0 : b;
|
|
1686
1686
|
return readString_0(_this__u8e3s4, count);
|
|
1687
1687
|
}
|
|
1688
|
-
return decode(charset.
|
|
1688
|
+
return decode(charset.b1m(), _this__u8e3s4, max);
|
|
1689
1689
|
}
|
|
1690
1690
|
function toByteArray_0(_this__u8e3s4, charset) {
|
|
1691
|
-
charset = charset === VOID ? Charsets_getInstance().
|
|
1692
|
-
if (charset.equals(Charsets_getInstance().
|
|
1691
|
+
charset = charset === VOID ? Charsets_getInstance().y1l_1 : charset;
|
|
1692
|
+
if (charset.equals(Charsets_getInstance().y1l_1))
|
|
1693
1693
|
return encodeToByteArray(_this__u8e3s4, VOID, VOID, true);
|
|
1694
|
-
return encodeToByteArray_0(charset.
|
|
1694
|
+
return encodeToByteArray_0(charset.c1m(), _this__u8e3s4, 0, _this__u8e3s4.length);
|
|
1695
1695
|
}
|
|
1696
1696
|
function writeText(_this__u8e3s4, text, fromIndex, toIndex, charset) {
|
|
1697
1697
|
fromIndex = fromIndex === VOID ? 0 : fromIndex;
|
|
1698
1698
|
toIndex = toIndex === VOID ? charSequenceLength(text) : toIndex;
|
|
1699
|
-
charset = charset === VOID ? Charsets_getInstance().
|
|
1700
|
-
if (charset === Charsets_getInstance().
|
|
1699
|
+
charset = charset === VOID ? Charsets_getInstance().y1l_1 : charset;
|
|
1700
|
+
if (charset === Charsets_getInstance().y1l_1) {
|
|
1701
1701
|
return writeString(_this__u8e3s4, toString_0(text), fromIndex, toIndex);
|
|
1702
1702
|
}
|
|
1703
|
-
encodeToImpl(charset.
|
|
1703
|
+
encodeToImpl(charset.c1m(), _this__u8e3s4, text, fromIndex, toIndex);
|
|
1704
1704
|
}
|
|
1705
1705
|
function get_ByteArrayPool() {
|
|
1706
1706
|
_init_properties_ByteArrayPool_kt__kfi3uj();
|
|
@@ -1710,7 +1710,7 @@
|
|
|
1710
1710
|
function ByteArrayPool$1() {
|
|
1711
1711
|
DefaultPool.call(this, 128);
|
|
1712
1712
|
}
|
|
1713
|
-
protoOf(ByteArrayPool$1).
|
|
1713
|
+
protoOf(ByteArrayPool$1).g1m = function () {
|
|
1714
1714
|
return new Int8Array(4096);
|
|
1715
1715
|
};
|
|
1716
1716
|
var properties_initialized_ByteArrayPool_kt_td6pfh;
|
|
@@ -1722,13 +1722,13 @@
|
|
|
1722
1722
|
}
|
|
1723
1723
|
function Companion_1() {
|
|
1724
1724
|
}
|
|
1725
|
-
protoOf(Companion_1).
|
|
1725
|
+
protoOf(Companion_1).p1m = function (name) {
|
|
1726
1726
|
switch (name) {
|
|
1727
1727
|
case 'UTF-8':
|
|
1728
1728
|
case 'utf-8':
|
|
1729
1729
|
case 'UTF8':
|
|
1730
1730
|
case 'utf8':
|
|
1731
|
-
return Charsets_getInstance().
|
|
1731
|
+
return Charsets_getInstance().y1l_1;
|
|
1732
1732
|
}
|
|
1733
1733
|
var tmp;
|
|
1734
1734
|
var tmp_0;
|
|
@@ -1741,8 +1741,6 @@
|
|
|
1741
1741
|
default:
|
|
1742
1742
|
// Inline function 'kotlin.let' call
|
|
1743
1743
|
|
|
1744
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1745
|
-
|
|
1746
1744
|
// Inline function 'io.ktor.utils.io.charsets.Companion.forName.<anonymous>' call
|
|
1747
1745
|
|
|
1748
1746
|
var it = replace(name, _Char___init__impl__6a9atx(95), _Char___init__impl__6a9atx(45));
|
|
@@ -1769,11 +1767,11 @@
|
|
|
1769
1767
|
tmp = name === 'Latin1';
|
|
1770
1768
|
}
|
|
1771
1769
|
if (tmp) {
|
|
1772
|
-
return Charsets_getInstance().
|
|
1770
|
+
return Charsets_getInstance().z1l_1;
|
|
1773
1771
|
}
|
|
1774
1772
|
throw IllegalArgumentException_init_$Create$('Charset ' + name + ' is not supported');
|
|
1775
1773
|
};
|
|
1776
|
-
protoOf(Companion_1).
|
|
1774
|
+
protoOf(Companion_1).q1m = function (charset) {
|
|
1777
1775
|
var tmp;
|
|
1778
1776
|
switch (charset) {
|
|
1779
1777
|
case 'UTF-8':
|
|
@@ -1793,8 +1791,6 @@
|
|
|
1793
1791
|
default:
|
|
1794
1792
|
// Inline function 'kotlin.let' call
|
|
1795
1793
|
|
|
1796
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1797
|
-
|
|
1798
1794
|
// Inline function 'io.ktor.utils.io.charsets.Companion.isSupported.<anonymous>' call
|
|
1799
1795
|
|
|
1800
1796
|
var it = replace(charset, _Char___init__impl__6a9atx(95), _Char___init__impl__6a9atx(45));
|
|
@@ -1832,7 +1828,7 @@
|
|
|
1832
1828
|
return Companion_instance_2;
|
|
1833
1829
|
}
|
|
1834
1830
|
function Charset(_name) {
|
|
1835
|
-
this.
|
|
1831
|
+
this.a1m_1 = _name;
|
|
1836
1832
|
}
|
|
1837
1833
|
protoOf(Charset).equals = function (other) {
|
|
1838
1834
|
if (this === other)
|
|
@@ -1841,21 +1837,21 @@
|
|
|
1841
1837
|
return false;
|
|
1842
1838
|
if (!(other instanceof Charset))
|
|
1843
1839
|
THROW_CCE();
|
|
1844
|
-
return this.
|
|
1840
|
+
return this.a1m_1 === other.a1m_1;
|
|
1845
1841
|
};
|
|
1846
1842
|
protoOf(Charset).hashCode = function () {
|
|
1847
|
-
return getStringHashCode(this.
|
|
1843
|
+
return getStringHashCode(this.a1m_1);
|
|
1848
1844
|
};
|
|
1849
1845
|
protoOf(Charset).toString = function () {
|
|
1850
|
-
return this.
|
|
1846
|
+
return this.a1m_1;
|
|
1851
1847
|
};
|
|
1852
1848
|
function get_name(_this__u8e3s4) {
|
|
1853
|
-
return _this__u8e3s4.
|
|
1849
|
+
return _this__u8e3s4.a1m_1;
|
|
1854
1850
|
}
|
|
1855
1851
|
function Charsets() {
|
|
1856
1852
|
Charsets_instance = this;
|
|
1857
|
-
this.
|
|
1858
|
-
this.
|
|
1853
|
+
this.y1l_1 = new CharsetImpl('UTF-8');
|
|
1854
|
+
this.z1l_1 = new CharsetImpl('ISO-8859-1');
|
|
1859
1855
|
}
|
|
1860
1856
|
var Charsets_instance;
|
|
1861
1857
|
function Charsets_getInstance() {
|
|
@@ -1868,29 +1864,29 @@
|
|
|
1868
1864
|
captureStack(this, MalformedInputException);
|
|
1869
1865
|
}
|
|
1870
1866
|
function CharsetDecoder(_charset) {
|
|
1871
|
-
this.
|
|
1867
|
+
this.r1m_1 = _charset;
|
|
1872
1868
|
}
|
|
1873
1869
|
function CharsetEncoder(_charset) {
|
|
1874
|
-
this.
|
|
1870
|
+
this.s1m_1 = _charset;
|
|
1875
1871
|
}
|
|
1876
1872
|
function CharsetImpl(name) {
|
|
1877
1873
|
Charset.call(this, name);
|
|
1878
1874
|
}
|
|
1879
|
-
protoOf(CharsetImpl).
|
|
1875
|
+
protoOf(CharsetImpl).c1m = function () {
|
|
1880
1876
|
return new CharsetEncoderImpl(this);
|
|
1881
1877
|
};
|
|
1882
|
-
protoOf(CharsetImpl).
|
|
1878
|
+
protoOf(CharsetImpl).b1m = function () {
|
|
1883
1879
|
return new CharsetDecoderImpl(this);
|
|
1884
1880
|
};
|
|
1885
1881
|
function CharsetEncoderImpl(charset) {
|
|
1886
1882
|
CharsetEncoder.call(this, charset);
|
|
1887
|
-
this.
|
|
1883
|
+
this.v1m_1 = charset;
|
|
1888
1884
|
}
|
|
1889
1885
|
protoOf(CharsetEncoderImpl).toString = function () {
|
|
1890
|
-
return 'CharsetEncoderImpl(charset=' + this.
|
|
1886
|
+
return 'CharsetEncoderImpl(charset=' + this.v1m_1.toString() + ')';
|
|
1891
1887
|
};
|
|
1892
1888
|
protoOf(CharsetEncoderImpl).hashCode = function () {
|
|
1893
|
-
return this.
|
|
1889
|
+
return this.v1m_1.hashCode();
|
|
1894
1890
|
};
|
|
1895
1891
|
protoOf(CharsetEncoderImpl).equals = function (other) {
|
|
1896
1892
|
if (this === other)
|
|
@@ -1898,19 +1894,19 @@
|
|
|
1898
1894
|
if (!(other instanceof CharsetEncoderImpl))
|
|
1899
1895
|
return false;
|
|
1900
1896
|
var tmp0_other_with_cast = other instanceof CharsetEncoderImpl ? other : THROW_CCE();
|
|
1901
|
-
if (!this.
|
|
1897
|
+
if (!this.v1m_1.equals(tmp0_other_with_cast.v1m_1))
|
|
1902
1898
|
return false;
|
|
1903
1899
|
return true;
|
|
1904
1900
|
};
|
|
1905
1901
|
function CharsetDecoderImpl(charset) {
|
|
1906
1902
|
CharsetDecoder.call(this, charset);
|
|
1907
|
-
this.
|
|
1903
|
+
this.x1m_1 = charset;
|
|
1908
1904
|
}
|
|
1909
1905
|
protoOf(CharsetDecoderImpl).toString = function () {
|
|
1910
|
-
return 'CharsetDecoderImpl(charset=' + this.
|
|
1906
|
+
return 'CharsetDecoderImpl(charset=' + this.x1m_1.toString() + ')';
|
|
1911
1907
|
};
|
|
1912
1908
|
protoOf(CharsetDecoderImpl).hashCode = function () {
|
|
1913
|
-
return this.
|
|
1909
|
+
return this.x1m_1.hashCode();
|
|
1914
1910
|
};
|
|
1915
1911
|
protoOf(CharsetDecoderImpl).equals = function (other) {
|
|
1916
1912
|
if (this === other)
|
|
@@ -1918,7 +1914,7 @@
|
|
|
1918
1914
|
if (!(other instanceof CharsetDecoderImpl))
|
|
1919
1915
|
return false;
|
|
1920
1916
|
var tmp0_other_with_cast = other instanceof CharsetDecoderImpl ? other : THROW_CCE();
|
|
1921
|
-
if (!this.
|
|
1917
|
+
if (!this.x1m_1.equals(tmp0_other_with_cast.x1m_1))
|
|
1922
1918
|
return false;
|
|
1923
1919
|
return true;
|
|
1924
1920
|
};
|
|
@@ -1929,15 +1925,15 @@
|
|
|
1929
1925
|
}
|
|
1930
1926
|
function decode_0(_this__u8e3s4, input, dst, max) {
|
|
1931
1927
|
var decoder = Decoder(get_name(get_charset(_this__u8e3s4)), true);
|
|
1928
|
+
var tmp0 = input.u1b().s();
|
|
1932
1929
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
1933
|
-
var a = input.t1a().s();
|
|
1934
1930
|
var b = toLong(max);
|
|
1935
|
-
var count =
|
|
1931
|
+
var count = tmp0.e1(b) <= 0 ? tmp0 : b;
|
|
1936
1932
|
var tmp = readByteArray(input, count.j1());
|
|
1937
1933
|
var array = tmp instanceof Int8Array ? tmp : THROW_CCE();
|
|
1938
1934
|
var tmp_0;
|
|
1939
1935
|
try {
|
|
1940
|
-
tmp_0 = decoder.
|
|
1936
|
+
tmp_0 = decoder.y1m(array);
|
|
1941
1937
|
} catch ($p) {
|
|
1942
1938
|
var tmp_1;
|
|
1943
1939
|
if ($p instanceof Error) {
|
|
@@ -1968,24 +1964,21 @@
|
|
|
1968
1964
|
return readByteArray_0(dst);
|
|
1969
1965
|
}
|
|
1970
1966
|
function get_charset(_this__u8e3s4) {
|
|
1971
|
-
return _this__u8e3s4.
|
|
1967
|
+
return _this__u8e3s4.r1m_1;
|
|
1972
1968
|
}
|
|
1973
1969
|
function encodeImpl(_this__u8e3s4, input, fromIndex, toIndex, dst) {
|
|
1974
1970
|
// Inline function 'kotlin.require' call
|
|
1975
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1976
1971
|
// Inline function 'kotlin.require' call
|
|
1977
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
1978
1972
|
if (!(fromIndex <= toIndex)) {
|
|
1979
1973
|
// Inline function 'kotlin.require.<anonymous>' call
|
|
1980
1974
|
var message = 'Failed requirement.';
|
|
1981
1975
|
throw IllegalArgumentException_init_$Create$(toString_0(message));
|
|
1982
1976
|
}
|
|
1983
|
-
if (get_charset_0(_this__u8e3s4).equals(Charsets_getInstance().
|
|
1977
|
+
if (get_charset_0(_this__u8e3s4).equals(Charsets_getInstance().z1l_1)) {
|
|
1984
1978
|
return encodeISO88591(input, fromIndex, toIndex, dst);
|
|
1985
1979
|
}
|
|
1986
1980
|
// Inline function 'kotlin.require' call
|
|
1987
|
-
|
|
1988
|
-
if (!(get_charset_0(_this__u8e3s4) === Charsets_getInstance().p1k_1)) {
|
|
1981
|
+
if (!(get_charset_0(_this__u8e3s4) === Charsets_getInstance().y1l_1)) {
|
|
1989
1982
|
// Inline function 'io.ktor.utils.io.charsets.encodeImpl.<anonymous>' call
|
|
1990
1983
|
var message_0 = 'Only UTF-8 encoding is supported in JS';
|
|
1991
1984
|
throw IllegalArgumentException_init_$Create$(toString_0(message_0));
|
|
@@ -1996,17 +1989,17 @@
|
|
|
1996
1989
|
var result = encoder.encode(tmp$ret$2);
|
|
1997
1990
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
1998
1991
|
// Inline function 'kotlin.js.asDynamic' call
|
|
1999
|
-
dst.
|
|
1992
|
+
dst.g1d(result);
|
|
2000
1993
|
return result.length;
|
|
2001
1994
|
}
|
|
2002
1995
|
function get_charset_0(_this__u8e3s4) {
|
|
2003
|
-
return _this__u8e3s4.
|
|
1996
|
+
return _this__u8e3s4.s1m_1;
|
|
2004
1997
|
}
|
|
2005
1998
|
function forName(_this__u8e3s4, name) {
|
|
2006
|
-
return Companion_instance_2.
|
|
1999
|
+
return Companion_instance_2.p1m(name);
|
|
2007
2000
|
}
|
|
2008
2001
|
function isSupported(_this__u8e3s4, name) {
|
|
2009
|
-
return Companion_instance_2.
|
|
2002
|
+
return Companion_instance_2.q1m(name);
|
|
2010
2003
|
}
|
|
2011
2004
|
function Decoder(encoding, fatal) {
|
|
2012
2005
|
fatal = fatal === VOID ? true : fatal;
|
|
@@ -2032,19 +2025,18 @@
|
|
|
2032
2025
|
fatal = fatal === VOID ? false : fatal;
|
|
2033
2026
|
// Inline function 'kotlin.apply' call
|
|
2034
2027
|
var this_0 = new Object();
|
|
2035
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
2036
2028
|
// Inline function 'io.ktor.utils.io.charsets.textDecoderOptions.<anonymous>' call
|
|
2037
|
-
// Inline function 'kotlin.with' call
|
|
2038
2029
|
// Inline function 'kotlin.js.asDynamic' call
|
|
2039
|
-
// Inline function 'kotlin.
|
|
2030
|
+
// Inline function 'kotlin.with' call
|
|
2031
|
+
// Inline function 'io.ktor.utils.io.charsets.textDecoderOptions.<anonymous>.<anonymous>' call
|
|
2040
2032
|
this_0.fatal = fatal;
|
|
2041
2033
|
return this_0;
|
|
2042
2034
|
}
|
|
2043
2035
|
function toKtor$1($this_toKtor) {
|
|
2044
|
-
this.
|
|
2036
|
+
this.z1m_1 = $this_toKtor;
|
|
2045
2037
|
}
|
|
2046
|
-
protoOf(toKtor$1).
|
|
2047
|
-
return this.
|
|
2038
|
+
protoOf(toKtor$1).y1m = function (buffer) {
|
|
2039
|
+
return this.z1m_1.decode(buffer);
|
|
2048
2040
|
};
|
|
2049
2041
|
function get_ENCODING_ALIASES() {
|
|
2050
2042
|
_init_properties_TextDecoderFallback_js_kt__an7r6m();
|
|
@@ -2057,20 +2049,19 @@
|
|
|
2057
2049
|
}
|
|
2058
2050
|
var REPLACEMENT;
|
|
2059
2051
|
function TextDecoderFallback(encoding, fatal) {
|
|
2060
|
-
this.
|
|
2061
|
-
// Inline function 'kotlin.text.lowercase' call
|
|
2052
|
+
this.a1n_1 = fatal;
|
|
2062
2053
|
// Inline function 'kotlin.text.trim' call
|
|
2054
|
+
// Inline function 'kotlin.text.lowercase' call
|
|
2063
2055
|
// Inline function 'kotlin.js.asDynamic' call
|
|
2064
2056
|
var requestedEncoding = toString_0(trim(isCharSequence(encoding) ? encoding : THROW_CCE())).toLowerCase();
|
|
2065
2057
|
// Inline function 'kotlin.check' call
|
|
2066
|
-
// Inline function 'kotlin.contracts.contract' call
|
|
2067
2058
|
if (!get_ENCODING_ALIASES().x1(requestedEncoding)) {
|
|
2068
2059
|
// Inline function 'io.ktor.utils.io.charsets.TextDecoderFallback.<anonymous>' call
|
|
2069
2060
|
var message = encoding + ' is not supported.';
|
|
2070
2061
|
throw IllegalStateException_init_$Create$(toString_0(message));
|
|
2071
2062
|
}
|
|
2072
2063
|
}
|
|
2073
|
-
protoOf(TextDecoderFallback).
|
|
2064
|
+
protoOf(TextDecoderFallback).y1m = function (buffer) {
|
|
2074
2065
|
// Inline function 'io.ktor.utils.io.core.buildPacket' call
|
|
2075
2066
|
var builder = new Buffer();
|
|
2076
2067
|
// Inline function 'io.ktor.utils.io.charsets.TextDecoderFallback.decode.<anonymous>' call
|
|
@@ -2087,8 +2078,7 @@
|
|
|
2087
2078
|
var point = toCodePoint(byte);
|
|
2088
2079
|
if (point < 0) {
|
|
2089
2080
|
// Inline function 'kotlin.check' call
|
|
2090
|
-
|
|
2091
|
-
if (!!this.r1l_1) {
|
|
2081
|
+
if (!!this.a1n_1) {
|
|
2092
2082
|
// Inline function 'io.ktor.utils.io.charsets.TextDecoderFallback.decode.<anonymous>.<anonymous>' call
|
|
2093
2083
|
var message = 'Invalid character: ' + point;
|
|
2094
2084
|
throw IllegalStateException_init_$Create$(toString_0(message));
|
|
@@ -2097,9 +2087,9 @@
|
|
|
2097
2087
|
continue $l$loop;
|
|
2098
2088
|
}
|
|
2099
2089
|
if (point > 255) {
|
|
2100
|
-
builder.
|
|
2090
|
+
builder.m1d(toByte(point >> 8));
|
|
2101
2091
|
}
|
|
2102
|
-
builder.
|
|
2092
|
+
builder.m1d(toByte(point & 255));
|
|
2103
2093
|
}
|
|
2104
2094
|
while (inductionVariable < last);
|
|
2105
2095
|
return decodeToString(readByteArray_0(builder));
|
|
@@ -2139,7 +2129,7 @@
|
|
|
2139
2129
|
if (character > 255) {
|
|
2140
2130
|
failedToMapError(character);
|
|
2141
2131
|
}
|
|
2142
|
-
dst.
|
|
2132
|
+
dst.m1d(toByte(character));
|
|
2143
2133
|
}
|
|
2144
2134
|
while (inductionVariable < toIndex);
|
|
2145
2135
|
return toIndex - fromIndex | 0;
|
|
@@ -2161,48 +2151,48 @@
|
|
|
2161
2151
|
}
|
|
2162
2152
|
}
|
|
2163
2153
|
function DefaultPool(capacity) {
|
|
2164
|
-
this.
|
|
2154
|
+
this.h1m_1 = capacity;
|
|
2165
2155
|
var tmp = this;
|
|
2166
2156
|
// Inline function 'kotlin.arrayOfNulls' call
|
|
2167
|
-
var size = this.
|
|
2168
|
-
tmp.
|
|
2169
|
-
this.
|
|
2157
|
+
var size = this.h1m_1;
|
|
2158
|
+
tmp.i1m_1 = fillArrayVal(Array(size), null);
|
|
2159
|
+
this.j1m_1 = 0;
|
|
2170
2160
|
}
|
|
2171
|
-
protoOf(DefaultPool).
|
|
2161
|
+
protoOf(DefaultPool).k1m = function (instance) {
|
|
2172
2162
|
};
|
|
2173
|
-
protoOf(DefaultPool).
|
|
2163
|
+
protoOf(DefaultPool).l1m = function (instance) {
|
|
2174
2164
|
return instance;
|
|
2175
2165
|
};
|
|
2176
|
-
protoOf(DefaultPool).
|
|
2166
|
+
protoOf(DefaultPool).m1m = function (instance) {
|
|
2177
2167
|
};
|
|
2178
|
-
protoOf(DefaultPool).
|
|
2179
|
-
if (this.
|
|
2180
|
-
return this.
|
|
2181
|
-
this.
|
|
2182
|
-
var idx = this.
|
|
2183
|
-
var tmp = this.
|
|
2168
|
+
protoOf(DefaultPool).n1m = function () {
|
|
2169
|
+
if (this.j1m_1 === 0)
|
|
2170
|
+
return this.g1m();
|
|
2171
|
+
this.j1m_1 = this.j1m_1 - 1 | 0;
|
|
2172
|
+
var idx = this.j1m_1;
|
|
2173
|
+
var tmp = this.i1m_1[idx];
|
|
2184
2174
|
var instance = !(tmp == null) ? tmp : THROW_CCE();
|
|
2185
|
-
this.
|
|
2186
|
-
return this.
|
|
2175
|
+
this.i1m_1[idx] = null;
|
|
2176
|
+
return this.l1m(instance);
|
|
2187
2177
|
};
|
|
2188
|
-
protoOf(DefaultPool).
|
|
2189
|
-
this.
|
|
2190
|
-
if (this.
|
|
2191
|
-
this.
|
|
2178
|
+
protoOf(DefaultPool).o1m = function (instance) {
|
|
2179
|
+
this.m1m(instance);
|
|
2180
|
+
if (this.j1m_1 === this.h1m_1) {
|
|
2181
|
+
this.k1m(instance);
|
|
2192
2182
|
} else {
|
|
2193
|
-
var _unary__edvuaz = this.
|
|
2194
|
-
this.
|
|
2195
|
-
this.
|
|
2183
|
+
var _unary__edvuaz = this.j1m_1;
|
|
2184
|
+
this.j1m_1 = _unary__edvuaz + 1 | 0;
|
|
2185
|
+
this.i1m_1[_unary__edvuaz] = instance;
|
|
2196
2186
|
}
|
|
2197
2187
|
};
|
|
2198
2188
|
//region block: post-declaration
|
|
2199
|
-
protoOf(Read).
|
|
2200
|
-
protoOf(Read).
|
|
2201
|
-
protoOf(Write).
|
|
2202
|
-
protoOf(Write).
|
|
2203
|
-
protoOf(ByteChannel).
|
|
2204
|
-
protoOf(ByteReadChannel$Companion$Empty$1).
|
|
2205
|
-
protoOf(SourceByteReadChannel).
|
|
2189
|
+
protoOf(Read).y1e = resume;
|
|
2190
|
+
protoOf(Read).z1e = resume_0;
|
|
2191
|
+
protoOf(Write).y1e = resume;
|
|
2192
|
+
protoOf(Write).z1e = resume_0;
|
|
2193
|
+
protoOf(ByteChannel).f1h = awaitContent$default;
|
|
2194
|
+
protoOf(ByteReadChannel$Companion$Empty$1).f1h = awaitContent$default;
|
|
2195
|
+
protoOf(SourceByteReadChannel).f1h = awaitContent$default;
|
|
2206
2196
|
//endregion
|
|
2207
2197
|
//region block: init
|
|
2208
2198
|
Empty_instance = new Empty();
|
|
@@ -2251,5 +2241,3 @@
|
|
|
2251
2241
|
//endregion
|
|
2252
2242
|
return _;
|
|
2253
2243
|
}(module.exports, require('./kotlin-kotlin-stdlib.js'), require('./kotlinx-coroutines-core.js'), require('./kotlinx-io-kotlinx-io-core.js'), require('./kotlinx-atomicfu.js')));
|
|
2254
|
-
|
|
2255
|
-
//# sourceMappingURL=ktor-ktor-io.js.map
|