@godaan/shared 1.0.0-SNAPSHOT-202512150300 → 1.0.0-SNAPSHOT-202512160231

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/kotlin/compose-multiplatform-core-compose-foundation-foundation.js +1 -1
  2. package/kotlin/compose-multiplatform-core-compose-runtime-runtime.js +1 -1
  3. package/kotlin/godaan-backend-shared.d.ts +1 -0
  4. package/kotlin/godaan-backend-shared.js +84 -4
  5. package/kotlin/godaan-backend-shared.js.map +1 -1
  6. package/kotlin/kotlin-kotlin-stdlib.js +9554 -76
  7. package/kotlin/kotlin-kotlin-stdlib.js.map +1 -1
  8. package/kotlin/kotlinx-atomicfu.js +190 -6
  9. package/kotlin/kotlinx-atomicfu.js.map +1 -1
  10. package/kotlin/kotlinx-coroutines-core.js +8162 -5
  11. package/kotlin/kotlinx-coroutines-core.js.map +1 -1
  12. package/kotlin/kotlinx-io-kotlinx-io-bytestring.js +204 -5
  13. package/kotlin/kotlinx-io-kotlinx-io-bytestring.js.map +1 -1
  14. package/kotlin/kotlinx-io-kotlinx-io-core.js +2019 -5
  15. package/kotlin/kotlinx-io-kotlinx-io-core.js.map +1 -1
  16. package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js +772 -5
  17. package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js.map +1 -1
  18. package/kotlin/ktor-ktor-client-core.js +8305 -26
  19. package/kotlin/ktor-ktor-client-core.js.map +1 -1
  20. package/kotlin/ktor-ktor-events.js +84 -5
  21. package/kotlin/ktor-ktor-events.js.map +1 -1
  22. package/kotlin/ktor-ktor-http-cio.js +2268 -5
  23. package/kotlin/ktor-ktor-http-cio.js.map +1 -1
  24. package/kotlin/ktor-ktor-http.js +3026 -5
  25. package/kotlin/ktor-ktor-http.js.map +1 -1
  26. package/kotlin/ktor-ktor-io.js +3159 -5
  27. package/kotlin/ktor-ktor-io.js.map +1 -1
  28. package/kotlin/ktor-ktor-utils.js +2355 -5
  29. package/kotlin/ktor-ktor-utils.js.map +1 -1
  30. package/kotlin/ktor-ktor-websockets.js +437 -5
  31. package/kotlin/ktor-ktor-websockets.js.map +1 -1
  32. package/package.json +1 -1
@@ -1,13 +1,2276 @@
1
1
  (function (factory) {
2
2
  if (typeof define === 'function' && define.amd)
3
- define(['exports'], factory);
3
+ define(['exports', './kotlin-kotlin-stdlib.js', './ktor-ktor-http.js', './kotlinx-coroutines-core.js', './ktor-ktor-io.js', './kotlinx-io-kotlinx-io-bytestring.js', './kotlinx-io-kotlinx-io-core.js'], factory);
4
4
  else if (typeof exports === 'object')
5
- factory(module.exports);
6
- else
7
- globalThis['ktor-ktor-http-cio'] = factory(typeof globalThis['ktor-ktor-http-cio'] === 'undefined' ? {} : globalThis['ktor-ktor-http-cio']);
8
- }(function (_) {
5
+ factory(module.exports, require('./kotlin-kotlin-stdlib.js'), require('./ktor-ktor-http.js'), require('./kotlinx-coroutines-core.js'), require('./ktor-ktor-io.js'), require('./kotlinx-io-kotlinx-io-bytestring.js'), require('./kotlinx-io-kotlinx-io-core.js'));
6
+ else {
7
+ if (typeof globalThis['kotlin-kotlin-stdlib'] === 'undefined') {
8
+ throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'kotlin-kotlin-stdlib' was not found. Please, check whether 'kotlin-kotlin-stdlib' is loaded prior to 'ktor-ktor-http-cio'.");
9
+ }
10
+ if (typeof globalThis['ktor-ktor-http'] === 'undefined') {
11
+ throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'ktor-ktor-http' was not found. Please, check whether 'ktor-ktor-http' is loaded prior to 'ktor-ktor-http-cio'.");
12
+ }
13
+ if (typeof globalThis['kotlinx-coroutines-core'] === 'undefined') {
14
+ throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'kotlinx-coroutines-core' was not found. Please, check whether 'kotlinx-coroutines-core' is loaded prior to 'ktor-ktor-http-cio'.");
15
+ }
16
+ if (typeof globalThis['ktor-ktor-io'] === 'undefined') {
17
+ throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'ktor-ktor-io' was not found. Please, check whether 'ktor-ktor-io' is loaded prior to 'ktor-ktor-http-cio'.");
18
+ }
19
+ if (typeof globalThis['kotlinx-io-kotlinx-io-bytestring'] === 'undefined') {
20
+ throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'kotlinx-io-kotlinx-io-bytestring' was not found. Please, check whether 'kotlinx-io-kotlinx-io-bytestring' is loaded prior to 'ktor-ktor-http-cio'.");
21
+ }
22
+ if (typeof globalThis['kotlinx-io-kotlinx-io-core'] === 'undefined') {
23
+ throw new Error("Error loading module 'ktor-ktor-http-cio'. Its dependency 'kotlinx-io-kotlinx-io-core' was not found. Please, check whether 'kotlinx-io-kotlinx-io-core' is loaded prior to 'ktor-ktor-http-cio'.");
24
+ }
25
+ globalThis['ktor-ktor-http-cio'] = factory(typeof globalThis['ktor-ktor-http-cio'] === 'undefined' ? {} : globalThis['ktor-ktor-http-cio'], globalThis['kotlin-kotlin-stdlib'], globalThis['ktor-ktor-http'], globalThis['kotlinx-coroutines-core'], globalThis['ktor-ktor-io'], globalThis['kotlinx-io-kotlinx-io-bytestring'], globalThis['kotlinx-io-kotlinx-io-core']);
26
+ }
27
+ }(function (_, kotlin_kotlin, kotlin_io_ktor_ktor_http, kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core, kotlin_io_ktor_ktor_io, kotlin_org_jetbrains_kotlinx_kotlinx_io_bytestring, kotlin_org_jetbrains_kotlinx_kotlinx_io_core) {
9
28
  'use strict';
29
+ //region block: imports
30
+ var imul = Math.imul;
31
+ var Long = kotlin_kotlin.$_$.u9;
32
+ var VOID = kotlin_kotlin.$_$.a;
33
+ var protoOf = kotlin_kotlin.$_$.g7;
34
+ var MultiPartData = kotlin_io_ktor_ktor_http.$_$.k;
35
+ var CoroutineScope = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.t;
36
+ var initMetadataForClass = kotlin_kotlin.$_$.q6;
37
+ var Unit_instance = kotlin_kotlin.$_$.k2;
38
+ var toString = kotlin_kotlin.$_$.j7;
39
+ var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.b1;
40
+ var abs = kotlin_kotlin.$_$.k7;
41
+ var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.s;
42
+ var CoroutineImpl = kotlin_kotlin.$_$.g5;
43
+ var THROW_CCE = kotlin_kotlin.$_$.y9;
44
+ var SequenceScope = kotlin_kotlin.$_$.y7;
45
+ var get_COROUTINE_SUSPENDED = kotlin_kotlin.$_$.q4;
46
+ var initMetadataForLambda = kotlin_kotlin.$_$.v6;
47
+ var ArrayList_init_$Create$ = kotlin_kotlin.$_$.g;
48
+ var sequence = kotlin_kotlin.$_$.z7;
49
+ var DefaultPool = kotlin_io_ktor_ktor_io.$_$.a1;
50
+ var fill = kotlin_kotlin.$_$.g3;
51
+ var isIntArray = kotlin_kotlin.$_$.z6;
52
+ var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.r1;
53
+ var endsWith = kotlin_kotlin.$_$.g8;
54
+ var charSequenceLength = kotlin_kotlin.$_$.g6;
55
+ var charSequenceGet = kotlin_kotlin.$_$.f6;
56
+ var Char = kotlin_kotlin.$_$.m9;
57
+ var Char__compareTo_impl_ypi4mb = kotlin_kotlin.$_$.s1;
58
+ var contains = kotlin_kotlin.$_$.c8;
59
+ var charSequenceSubSequence = kotlin_kotlin.$_$.h6;
60
+ var Char__toInt_impl_vasixd = kotlin_kotlin.$_$.x1;
61
+ var IllegalStateException = kotlin_kotlin.$_$.t9;
62
+ var IllegalStateException_init_$Init$ = kotlin_kotlin.$_$.d1;
63
+ var captureStack = kotlin_kotlin.$_$.b6;
64
+ var readUTF8LineTo = kotlin_io_ktor_ktor_io.$_$.e;
65
+ var IllegalStateException_init_$Create$ = kotlin_kotlin.$_$.e1;
66
+ var HttpHeaders_getInstance = kotlin_io_ktor_ktor_http.$_$.g;
67
+ var initMetadataForCoroutine = kotlin_kotlin.$_$.s6;
68
+ var setOf = kotlin_kotlin.$_$.a4;
69
+ var Companion_getInstance = kotlin_io_ktor_ktor_io.$_$.m;
70
+ var LineEndingMode__plus_impl_ttpz2j = kotlin_io_ktor_ktor_io.$_$.j;
71
+ var listOf = kotlin_kotlin.$_$.q3;
72
+ var MultiPart_getInstance = kotlin_io_ktor_ktor_http.$_$.d;
73
+ var ByteString_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_io_bytestring.$_$.a;
74
+ var IOException_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.c;
75
+ var toString_0 = kotlin_kotlin.$_$.g9;
76
+ var toByte = kotlin_kotlin.$_$.h7;
77
+ var copyOfRange = kotlin_kotlin.$_$.a3;
78
+ var produce = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.j;
79
+ var startsWith = kotlin_kotlin.$_$.x8;
80
+ var readUntil = kotlin_io_ktor_ktor_io.$_$.f;
81
+ var WriterScope = kotlin_io_ktor_ktor_io.$_$.f1;
82
+ var ProducerScope = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.h;
83
+ var isInterface = kotlin_kotlin.$_$.a7;
84
+ var counted = kotlin_io_ktor_ktor_io.$_$.i1;
85
+ var writer = kotlin_io_ktor_ktor_io.$_$.m1;
86
+ var readRemaining = kotlin_io_ktor_ktor_io.$_$.d;
87
+ var get_remaining = kotlin_io_ktor_ktor_io.$_$.u;
88
+ var compare = kotlin_kotlin.$_$.m5;
89
+ var skipIfFound = kotlin_io_ktor_ktor_io.$_$.g;
90
+ var ByteChannel = kotlin_io_ktor_ktor_io.$_$.c1;
91
+ var CompletableDeferred = kotlin_org_jetbrains_kotlinx_kotlinx_coroutines_core.$_$.o;
92
+ var CancellationException_init_$Create$ = kotlin_kotlin.$_$.n;
93
+ var close = kotlin_io_ktor_ktor_io.$_$.h1;
94
+ var subtract = kotlin_kotlin.$_$.w5;
95
+ var convertToInt = kotlin_kotlin.$_$.n5;
96
+ var readPacket = kotlin_io_ktor_ktor_io.$_$.c;
97
+ var EOFException_init_$Create$ = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.a;
98
+ var copyTo = kotlin_io_ktor_ktor_io.$_$.a;
99
+ var add = kotlin_kotlin.$_$.k5;
100
+ var fromInt = kotlin_kotlin.$_$.q5;
101
+ var toByteArray = kotlin_io_ktor_ktor_io.$_$.w;
102
+ var ByteString = kotlin_org_jetbrains_kotlinx_kotlinx_io_bytestring.$_$.c;
103
+ var LinkedHashMap_init_$Create$ = kotlin_kotlin.$_$.l;
104
+ var compareTo = kotlin_kotlin.$_$.i6;
105
+ var NoSuchElementException_init_$Create$ = kotlin_kotlin.$_$.k1;
106
+ var Collection = kotlin_kotlin.$_$.m2;
107
+ var emptyList = kotlin_kotlin.$_$.d3;
108
+ var initMetadataForCompanion = kotlin_kotlin.$_$.r6;
109
+ var ensureNotNull = kotlin_kotlin.$_$.fa;
110
+ var StringBuilder_init_$Create$_0 = kotlin_kotlin.$_$.r;
111
+ var isCharSequence = kotlin_kotlin.$_$.y6;
112
+ var getStringHashCode = kotlin_kotlin.$_$.o6;
113
+ var CharSequence = kotlin_kotlin.$_$.l9;
114
+ var IndexOutOfBoundsException_init_$Create$ = kotlin_kotlin.$_$.h1;
115
+ var NoPoolImpl = kotlin_io_ktor_ktor_io.$_$.b1;
116
+ var charArray = kotlin_kotlin.$_$.d6;
117
+ var shiftLeft = kotlin_kotlin.$_$.u5;
118
+ var NumberFormatException_init_$Create$ = kotlin_kotlin.$_$.l1;
119
+ var toString_1 = kotlin_kotlin.$_$.y1;
120
+ var charCodeAt = kotlin_kotlin.$_$.e6;
121
+ var Companion_getInstance_0 = kotlin_io_ktor_ktor_http.$_$.h;
122
+ var numberRangeToNumber = kotlin_kotlin.$_$.d7;
123
+ var collectionSizeOrDefault = kotlin_kotlin.$_$.v2;
124
+ var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.f;
125
+ var numberToLong = kotlin_kotlin.$_$.t5;
126
+ var toLongArray = kotlin_kotlin.$_$.i4;
127
+ var Char__plus_impl_qi7pgj = kotlin_kotlin.$_$.v1;
128
+ var Char__minus_impl_a2frrh = kotlin_kotlin.$_$.u1;
129
+ var toByteArray_0 = kotlin_kotlin.$_$.d4;
130
+ var IOException = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.g;
131
+ var IOException_init_$Init$ = kotlin_org_jetbrains_kotlinx_kotlinx_io_core.$_$.b;
132
+ var isWhitespace = kotlin_kotlin.$_$.o8;
133
+ //endregion
10
134
  //region block: pre-declaration
135
+ initMetadataForClass(CIOMultipartDataBase, 'CIOMultipartDataBase', VOID, VOID, [MultiPartData, CoroutineScope], [0, 1]);
136
+ initMetadataForClass(HttpHeadersMap, 'HttpHeadersMap');
137
+ initMetadataForLambda(HeadersData$headersStarts$slambda, CoroutineImpl, VOID, [1]);
138
+ initMetadataForClass(HeadersData, 'HeadersData', HeadersData);
139
+ initMetadataForClass(IntArrayPool$1, VOID, VOID, DefaultPool);
140
+ initMetadataForClass(HeadersDataPool$1, VOID, VOID, DefaultPool);
141
+ initMetadataForClass(ParserException, 'ParserException', VOID, IllegalStateException);
142
+ initMetadataForCoroutine($parseHeadersCOROUTINE$, CoroutineImpl);
143
+ initMetadataForClass(MultipartEvent, 'MultipartEvent');
144
+ initMetadataForClass(Preamble, 'Preamble', VOID, MultipartEvent);
145
+ initMetadataForClass(MultipartPart, 'MultipartPart', VOID, MultipartEvent);
146
+ initMetadataForClass(Epilogue, 'Epilogue', VOID, MultipartEvent);
147
+ initMetadataForLambda(parseMultipart$slambda$slambda, CoroutineImpl, VOID, [1]);
148
+ initMetadataForLambda(parseMultipart$slambda, CoroutineImpl, VOID, [1]);
149
+ initMetadataForCoroutine($parsePartHeadersImplCOROUTINE$, CoroutineImpl);
150
+ initMetadataForCoroutine($parsePartBodyImplCOROUTINE$, CoroutineImpl);
151
+ initMetadataForCoroutine($skipIfFoundReadCountCOROUTINE$, CoroutineImpl);
152
+ initMetadataForClass(Node, 'Node');
153
+ initMetadataForCompanion(Companion);
154
+ initMetadataForClass(AsciiCharTree, 'AsciiCharTree');
155
+ initMetadataForClass(SubSequenceImpl, 'SubSequenceImpl', VOID, VOID, [CharSequence]);
156
+ initMetadataForClass(CharArrayBuilder, 'CharArrayBuilder', CharArrayBuilder, VOID, [CharSequence]);
157
+ initMetadataForClass(CharArrayPool$1, VOID, VOID, NoPoolImpl);
158
+ initMetadataForClass(CharArrayPool$2, VOID, VOID, DefaultPool);
159
+ initMetadataForClass(UnsupportedMediaTypeExceptionCIO, 'UnsupportedMediaTypeExceptionCIO', VOID, IOException);
160
+ initMetadataForClass(MutableRange, 'MutableRange');
161
+ //endregion
162
+ function CIOMultipartDataBase(coroutineContext, channel, contentType, contentLength, formFieldLimit) {
163
+ formFieldLimit = formFieldLimit === VOID ? new Long(65536, 0) : formFieldLimit;
164
+ this.t20_1 = coroutineContext;
165
+ this.u20_1 = null;
166
+ this.v20_1 = parseMultipart(this, channel, contentType, contentLength, formFieldLimit);
167
+ }
168
+ protoOf(CIOMultipartDataBase).wj = function () {
169
+ return this.t20_1;
170
+ };
171
+ function get_IntArrayPool() {
172
+ _init_properties_HttpHeadersMap_kt__hwatby();
173
+ return IntArrayPool;
174
+ }
175
+ var IntArrayPool;
176
+ function get_HeadersDataPool() {
177
+ _init_properties_HttpHeadersMap_kt__hwatby();
178
+ return HeadersDataPool;
179
+ }
180
+ var HeadersDataPool;
181
+ function thresholdReached($this) {
182
+ return $this.x20_1 >= $this.y20_1 * 0.75;
183
+ }
184
+ function resize($this) {
185
+ var prevSize = $this.x20_1;
186
+ var prevData = $this.z20_1;
187
+ $this.x20_1 = 0;
188
+ $this.y20_1 = imul($this.y20_1, 2) | 128;
189
+ var tmp = $this;
190
+ // Inline function 'kotlin.apply' call
191
+ var this_0 = get_HeadersDataPool().g1e();
192
+ this_0.c21(imul(prevData.b21(), 2) | 1);
193
+ tmp.z20_1 = this_0;
194
+ var _iterator__ex2g4s = prevData.d21().i();
195
+ while (_iterator__ex2g4s.j()) {
196
+ var headerOffset = _iterator__ex2g4s.k();
197
+ $this.f21(prevData.e21(headerOffset + 1 | 0), prevData.e21(headerOffset + 2 | 0), prevData.e21(headerOffset + 3 | 0), prevData.e21(headerOffset + 4 | 0));
198
+ }
199
+ get_HeadersDataPool().h1e(prevData);
200
+ // Inline function 'kotlin.require' call
201
+ // Inline function 'kotlin.require' call
202
+ if (!(prevSize === $this.x20_1)) {
203
+ var message = 'Failed requirement.';
204
+ throw IllegalArgumentException_init_$Create$(toString(message));
205
+ }
206
+ }
207
+ function headerHasName($this, name, headerOffset) {
208
+ var nameStartIndex = $this.z20_1.e21(headerOffset + 1 | 0);
209
+ var nameEndIndex = $this.z20_1.e21(headerOffset + 2 | 0);
210
+ return equalsLowerCase($this.w20_1, nameStartIndex, nameEndIndex, name);
211
+ }
212
+ function HttpHeadersMap(builder) {
213
+ this.w20_1 = builder;
214
+ this.x20_1 = 0;
215
+ this.y20_1 = 0;
216
+ this.z20_1 = get_HeadersDataPool().g1e();
217
+ }
218
+ protoOf(HttpHeadersMap).v1h = function (name) {
219
+ if (this.x20_1 === 0)
220
+ return null;
221
+ // Inline function 'kotlin.math.absoluteValue' call
222
+ var this_0 = hashCodeLowerCase(name);
223
+ var hash = abs(this_0);
224
+ var headerIndex = hash % this.y20_1 | 0;
225
+ while (!(this.z20_1.e21(imul(headerIndex, 6) + 0 | 0) === -1)) {
226
+ if (headerHasName(this, name, imul(headerIndex, 6))) {
227
+ return this.g21(imul(headerIndex, 6));
228
+ }
229
+ headerIndex = (headerIndex + 1 | 0) % this.y20_1 | 0;
230
+ }
231
+ return null;
232
+ };
233
+ protoOf(HttpHeadersMap).h21 = function () {
234
+ return this.z20_1.d21();
235
+ };
236
+ protoOf(HttpHeadersMap).f21 = function (nameStartIndex, nameEndIndex, valueStartIndex, valueEndIndex) {
237
+ if (thresholdReached(this)) {
238
+ resize(this);
239
+ }
240
+ // Inline function 'kotlin.math.absoluteValue' call
241
+ var this_0 = hashCodeLowerCase(this.w20_1, nameStartIndex, nameEndIndex);
242
+ var hash = abs(this_0);
243
+ var name = this.w20_1.c(nameStartIndex, nameEndIndex);
244
+ var headerIndex = hash % this.y20_1 | 0;
245
+ var sameNameHeaderIndex = -1;
246
+ while (!(this.z20_1.e21(imul(headerIndex, 6) + 0 | 0) === -1)) {
247
+ if (headerHasName(this, name, imul(headerIndex, 6))) {
248
+ sameNameHeaderIndex = headerIndex;
249
+ }
250
+ headerIndex = (headerIndex + 1 | 0) % this.y20_1 | 0;
251
+ }
252
+ var headerOffset = imul(headerIndex, 6);
253
+ this.z20_1.p21(headerOffset + 0 | 0, hash);
254
+ this.z20_1.p21(headerOffset + 1 | 0, nameStartIndex);
255
+ this.z20_1.p21(headerOffset + 2 | 0, nameEndIndex);
256
+ this.z20_1.p21(headerOffset + 3 | 0, valueStartIndex);
257
+ this.z20_1.p21(headerOffset + 4 | 0, valueEndIndex);
258
+ this.z20_1.p21(headerOffset + 5 | 0, -1);
259
+ if (!(sameNameHeaderIndex === -1)) {
260
+ this.z20_1.p21(imul(sameNameHeaderIndex, 6) + 5 | 0, headerIndex);
261
+ }
262
+ this.x20_1 = this.x20_1 + 1 | 0;
263
+ };
264
+ protoOf(HttpHeadersMap).q21 = function (headerOffset) {
265
+ var nameStartIndex = this.z20_1.e21(headerOffset + 1 | 0);
266
+ var nameEndIndex = this.z20_1.e21(headerOffset + 2 | 0);
267
+ return this.w20_1.c(nameStartIndex, nameEndIndex);
268
+ };
269
+ protoOf(HttpHeadersMap).g21 = function (headerOffset) {
270
+ var valueStartIndex = this.z20_1.e21(headerOffset + 3 | 0);
271
+ var valueEndIndex = this.z20_1.e21(headerOffset + 4 | 0);
272
+ return this.w20_1.c(valueStartIndex, valueEndIndex);
273
+ };
274
+ protoOf(HttpHeadersMap).r21 = function () {
275
+ this.x20_1 = 0;
276
+ this.y20_1 = 0;
277
+ get_HeadersDataPool().h1e(this.z20_1);
278
+ this.z20_1 = get_HeadersDataPool().g1e();
279
+ };
280
+ protoOf(HttpHeadersMap).toString = function () {
281
+ // Inline function 'kotlin.text.buildString' call
282
+ // Inline function 'kotlin.apply' call
283
+ var this_0 = StringBuilder_init_$Create$();
284
+ dumpTo(this, '', this_0);
285
+ return this_0.toString();
286
+ };
287
+ function HeadersData$headersStarts$slambda(this$0, resultContinuation) {
288
+ this.a22_1 = this$0;
289
+ CoroutineImpl.call(this, resultContinuation);
290
+ }
291
+ protoOf(HeadersData$headersStarts$slambda).g22 = function ($this$sequence, $completion) {
292
+ var tmp = this.h22($this$sequence, $completion);
293
+ tmp.e7_1 = Unit_instance;
294
+ tmp.f7_1 = null;
295
+ return tmp.k7();
296
+ };
297
+ protoOf(HeadersData$headersStarts$slambda).w7 = function (p1, $completion) {
298
+ return this.g22(p1 instanceof SequenceScope ? p1 : THROW_CCE(), $completion);
299
+ };
300
+ protoOf(HeadersData$headersStarts$slambda).k7 = function () {
301
+ var suspendResult = this.e7_1;
302
+ $sm: do
303
+ try {
304
+ var tmp = this.c7_1;
305
+ switch (tmp) {
306
+ case 0:
307
+ this.d7_1 = 7;
308
+ this.c22_1 = 0;
309
+ this.f22_1 = this.a22_1.a21_1.i();
310
+ this.c7_1 = 1;
311
+ continue $sm;
312
+ case 1:
313
+ if (!this.f22_1.j()) {
314
+ this.c7_1 = 6;
315
+ continue $sm;
316
+ }
317
+
318
+ this.e22_1 = this.f22_1.k();
319
+ this.d22_1 = 0;
320
+ this.c7_1 = 2;
321
+ continue $sm;
322
+ case 2:
323
+ if (!(this.d22_1 < this.e22_1.length)) {
324
+ this.c7_1 = 5;
325
+ continue $sm;
326
+ }
327
+
328
+ if (!(this.a22_1.e21(this.c22_1 + 0 | 0) === -1)) {
329
+ this.c7_1 = 3;
330
+ suspendResult = this.b22_1.vc(this.c22_1, this);
331
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
332
+ return suspendResult;
333
+ }
334
+ continue $sm;
335
+ } else {
336
+ this.c7_1 = 4;
337
+ continue $sm;
338
+ }
339
+
340
+ case 3:
341
+ this.c7_1 = 4;
342
+ continue $sm;
343
+ case 4:
344
+ this.d22_1 = this.d22_1 + 6 | 0;
345
+ this.c22_1 = this.c22_1 + 6 | 0;
346
+ this.c7_1 = 2;
347
+ continue $sm;
348
+ case 5:
349
+ this.c7_1 = 1;
350
+ continue $sm;
351
+ case 6:
352
+ return Unit_instance;
353
+ case 7:
354
+ throw this.f7_1;
355
+ }
356
+ } catch ($p) {
357
+ var e = $p;
358
+ if (this.d7_1 === 7) {
359
+ throw e;
360
+ } else {
361
+ this.c7_1 = this.d7_1;
362
+ this.f7_1 = e;
363
+ }
364
+ }
365
+ while (true);
366
+ };
367
+ protoOf(HeadersData$headersStarts$slambda).h22 = function ($this$sequence, completion) {
368
+ var i = new HeadersData$headersStarts$slambda(this.a22_1, completion);
369
+ i.b22_1 = $this$sequence;
370
+ return i;
371
+ };
372
+ function HeadersData$headersStarts$slambda_0(this$0, resultContinuation) {
373
+ var i = new HeadersData$headersStarts$slambda(this$0, resultContinuation);
374
+ var l = function ($this$sequence, $completion) {
375
+ return i.g22($this$sequence, $completion);
376
+ };
377
+ l.$arity = 1;
378
+ return l;
379
+ }
380
+ function HeadersData() {
381
+ var tmp = this;
382
+ // Inline function 'kotlin.collections.mutableListOf' call
383
+ tmp.a21_1 = ArrayList_init_$Create$();
384
+ }
385
+ protoOf(HeadersData).b21 = function () {
386
+ return this.a21_1.n();
387
+ };
388
+ protoOf(HeadersData).c21 = function (subArraysCount) {
389
+ // Inline function 'kotlin.repeat' call
390
+ var inductionVariable = 0;
391
+ if (inductionVariable < subArraysCount)
392
+ do {
393
+ var index = inductionVariable;
394
+ inductionVariable = inductionVariable + 1 | 0;
395
+ this.a21_1.g(get_IntArrayPool().g1e());
396
+ }
397
+ while (inductionVariable < subArraysCount);
398
+ };
399
+ protoOf(HeadersData).e21 = function (index) {
400
+ return this.a21_1.m(index / 768 | 0)[index % 768 | 0];
401
+ };
402
+ protoOf(HeadersData).p21 = function (index, value) {
403
+ this.a21_1.m(index / 768 | 0)[index % 768 | 0] = value;
404
+ };
405
+ protoOf(HeadersData).d21 = function () {
406
+ return sequence(HeadersData$headersStarts$slambda_0(this, null));
407
+ };
408
+ protoOf(HeadersData).r21 = function () {
409
+ var _iterator__ex2g4s = this.a21_1.i();
410
+ while (_iterator__ex2g4s.j()) {
411
+ var array = _iterator__ex2g4s.k();
412
+ get_IntArrayPool().h1e(array);
413
+ }
414
+ this.a21_1.r1();
415
+ };
416
+ function dumpTo(_this__u8e3s4, indent, out) {
417
+ _init_properties_HttpHeadersMap_kt__hwatby();
418
+ var _iterator__ex2g4s = _this__u8e3s4.h21().i();
419
+ while (_iterator__ex2g4s.j()) {
420
+ var offset = _iterator__ex2g4s.k();
421
+ out.h(indent);
422
+ out.h(_this__u8e3s4.q21(offset));
423
+ out.h(' => ');
424
+ out.h(_this__u8e3s4.g21(offset));
425
+ out.h('\n');
426
+ }
427
+ }
428
+ function IntArrayPool$1() {
429
+ DefaultPool.call(this, 1000);
430
+ }
431
+ protoOf(IntArrayPool$1).z1d = function () {
432
+ var tmp = 0;
433
+ var tmp_0 = new Int32Array(768);
434
+ while (tmp < 768) {
435
+ tmp_0[tmp] = -1;
436
+ tmp = tmp + 1 | 0;
437
+ }
438
+ return tmp_0;
439
+ };
440
+ protoOf(IntArrayPool$1).l22 = function (instance) {
441
+ fill(instance, -1);
442
+ return protoOf(DefaultPool).e1e.call(this, instance);
443
+ };
444
+ protoOf(IntArrayPool$1).e1e = function (instance) {
445
+ return this.l22(isIntArray(instance) ? instance : THROW_CCE());
446
+ };
447
+ function HeadersDataPool$1() {
448
+ DefaultPool.call(this, 1000);
449
+ }
450
+ protoOf(HeadersDataPool$1).z1d = function () {
451
+ return new HeadersData();
452
+ };
453
+ protoOf(HeadersDataPool$1).p22 = function (instance) {
454
+ instance.r21();
455
+ return protoOf(DefaultPool).e1e.call(this, instance);
456
+ };
457
+ protoOf(HeadersDataPool$1).e1e = function (instance) {
458
+ return this.p22(instance instanceof HeadersData ? instance : THROW_CCE());
459
+ };
460
+ var properties_initialized_HttpHeadersMap_kt_kotj4w;
461
+ function _init_properties_HttpHeadersMap_kt__hwatby() {
462
+ if (!properties_initialized_HttpHeadersMap_kt_kotj4w) {
463
+ properties_initialized_HttpHeadersMap_kt_kotj4w = true;
464
+ IntArrayPool = new IntArrayPool$1();
465
+ HeadersDataPool = new HeadersDataPool$1();
466
+ }
467
+ }
468
+ function get_hostForbiddenSymbols() {
469
+ _init_properties_HttpParser_kt__gbdom1();
470
+ return hostForbiddenSymbols;
471
+ }
472
+ var hostForbiddenSymbols;
473
+ function get_httpLineEndings() {
474
+ _init_properties_HttpParser_kt__gbdom1();
475
+ return httpLineEndings;
476
+ }
477
+ var httpLineEndings;
478
+ var versions;
479
+ function parseHeaders(input, builder, range, $completion) {
480
+ range = range === VOID ? new MutableRange(0, 0) : range;
481
+ var tmp = new $parseHeadersCOROUTINE$(input, builder, range, $completion);
482
+ tmp.e7_1 = Unit_instance;
483
+ tmp.f7_1 = null;
484
+ return tmp.k7();
485
+ }
486
+ function parseHeaderName(text, range) {
487
+ _init_properties_HttpParser_kt__gbdom1();
488
+ var index = range.d23_1;
489
+ var end = range.e23_1;
490
+ while (index < end) {
491
+ var ch = text.b(index);
492
+ if (ch === _Char___init__impl__6a9atx(58) && !(index === range.d23_1)) {
493
+ range.d23_1 = index + 1 | 0;
494
+ return index;
495
+ }
496
+ if (isDelimiter(ch)) {
497
+ parseHeaderNameFailed(text, index, range.d23_1, ch);
498
+ }
499
+ index = index + 1 | 0;
500
+ }
501
+ noColonFound(text, range);
502
+ }
503
+ function parseHeaderValue(text, range) {
504
+ _init_properties_HttpParser_kt__gbdom1();
505
+ var start = range.d23_1;
506
+ var end = range.e23_1;
507
+ var index = start;
508
+ index = skipSpacesAndHorizontalTabs(text, index, end);
509
+ if (index >= end) {
510
+ range.d23_1 = end;
511
+ return Unit_instance;
512
+ }
513
+ var valueStart = index;
514
+ var valueLastIndex = index;
515
+ while (index < end) {
516
+ var ch = text.b(index);
517
+ if (ch !== _Char___init__impl__6a9atx(9) && ch !== _Char___init__impl__6a9atx(32))
518
+ if (ch === _Char___init__impl__6a9atx(13) || ch === _Char___init__impl__6a9atx(10)) {
519
+ characterIsNotAllowed(text, ch);
520
+ } else
521
+ valueLastIndex = index;
522
+ index = index + 1 | 0;
523
+ }
524
+ range.d23_1 = valueStart;
525
+ range.e23_1 = valueLastIndex + 1 | 0;
526
+ }
527
+ function validateHostHeader(host) {
528
+ _init_properties_HttpParser_kt__gbdom1();
529
+ if (endsWith(host, ':')) {
530
+ throw new ParserException("Host header with ':' should contains port: " + toString(host));
531
+ }
532
+ var tmp$ret$1;
533
+ $l$block: {
534
+ // Inline function 'kotlin.text.any' call
535
+ var inductionVariable = 0;
536
+ while (inductionVariable < charSequenceLength(host)) {
537
+ var element = charSequenceGet(host, inductionVariable);
538
+ inductionVariable = inductionVariable + 1 | 0;
539
+ if (get_hostForbiddenSymbols().k1(new Char(element))) {
540
+ tmp$ret$1 = true;
541
+ break $l$block;
542
+ }
543
+ }
544
+ tmp$ret$1 = false;
545
+ }
546
+ if (tmp$ret$1) {
547
+ throw new ParserException('Host cannot contain any of the following symbols: ' + toString(get_hostForbiddenSymbols()));
548
+ }
549
+ }
550
+ function isDelimiter(ch) {
551
+ _init_properties_HttpParser_kt__gbdom1();
552
+ return Char__compareTo_impl_ypi4mb(ch, _Char___init__impl__6a9atx(32)) <= 0 || contains('"(),/:;<=>?@[\\]{}', ch);
553
+ }
554
+ function parseHeaderNameFailed(text, index, start, ch) {
555
+ _init_properties_HttpParser_kt__gbdom1();
556
+ if (ch === _Char___init__impl__6a9atx(58)) {
557
+ throw new ParserException('Empty header names are not allowed as per RFC7230.');
558
+ }
559
+ if (index === start) {
560
+ throw new ParserException('Multiline headers via line folding is not supported since it is deprecated as per RFC7230.');
561
+ }
562
+ characterIsNotAllowed(text, ch);
563
+ }
564
+ function noColonFound(text, range) {
565
+ _init_properties_HttpParser_kt__gbdom1();
566
+ var tmp2 = range.d23_1;
567
+ // Inline function 'kotlin.text.substring' call
568
+ var endIndex = range.e23_1;
569
+ var tmp$ret$0 = toString(charSequenceSubSequence(text, tmp2, endIndex));
570
+ throw new ParserException('No colon in HTTP header in ' + tmp$ret$0 + ' in builder: \n' + toString(text));
571
+ }
572
+ function characterIsNotAllowed(text, ch) {
573
+ _init_properties_HttpParser_kt__gbdom1();
574
+ // Inline function 'kotlin.code' call
575
+ var tmp$ret$0 = Char__toInt_impl_vasixd(ch);
576
+ throw new ParserException('Character with code ' + (tmp$ret$0 & 255) + ' is not allowed in header names, \n' + toString(text));
577
+ }
578
+ function ParserException(message) {
579
+ IllegalStateException_init_$Init$(message, this);
580
+ captureStack(this, ParserException);
581
+ }
582
+ function $parseHeadersCOROUTINE$(input, builder, range, resultContinuation) {
583
+ CoroutineImpl.call(this, resultContinuation);
584
+ this.y22_1 = input;
585
+ this.z22_1 = builder;
586
+ this.a23_1 = range;
587
+ }
588
+ protoOf($parseHeadersCOROUTINE$).k7 = function () {
589
+ var suspendResult = this.e7_1;
590
+ $sm: do
591
+ try {
592
+ var tmp = this.c7_1;
593
+ switch (tmp) {
594
+ case 0:
595
+ this.d7_1 = 7;
596
+ this.b23_1 = new HttpHeadersMap(this.z22_1);
597
+ this.d7_1 = 6;
598
+ this.c7_1 = 1;
599
+ continue $sm;
600
+ case 1:
601
+ if (!true) {
602
+ this.c7_1 = 5;
603
+ continue $sm;
604
+ }
605
+
606
+ this.c7_1 = 2;
607
+ suspendResult = readUTF8LineTo(this.y22_1, this.z22_1, 8192, get_httpLineEndings(), this);
608
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
609
+ return suspendResult;
610
+ }
611
+
612
+ continue $sm;
613
+ case 2:
614
+ if (!suspendResult) {
615
+ this.b23_1.r21();
616
+ return null;
617
+ } else {
618
+ this.c7_1 = 3;
619
+ continue $sm;
620
+ }
621
+
622
+ case 3:
623
+ this.a23_1.e23_1 = this.z22_1.o21_1;
624
+ this.c23_1 = this.a23_1.e23_1 - this.a23_1.d23_1 | 0;
625
+ if (this.c23_1 === 0) {
626
+ this.c7_1 = 5;
627
+ continue $sm;
628
+ } else {
629
+ this.c7_1 = 4;
630
+ continue $sm;
631
+ }
632
+
633
+ case 4:
634
+ if (this.c23_1 >= 8192) {
635
+ var message = 'Header line length limit exceeded';
636
+ throw IllegalStateException_init_$Create$(toString(message));
637
+ }
638
+
639
+ var nameStart = this.a23_1.d23_1;
640
+ var nameEnd = parseHeaderName(this.z22_1, this.a23_1);
641
+ var headerEnd = this.a23_1.e23_1;
642
+ parseHeaderValue(this.z22_1, this.a23_1);
643
+ var valueStart = this.a23_1.d23_1;
644
+ var valueEnd = this.a23_1.e23_1;
645
+ this.a23_1.d23_1 = headerEnd;
646
+ this.b23_1.f21(nameStart, nameEnd, valueStart, valueEnd);
647
+ this.c7_1 = 1;
648
+ continue $sm;
649
+ case 5:
650
+ var host = this.b23_1.v1h(HttpHeaders_getInstance().x1q_1);
651
+ if (!(host == null)) {
652
+ validateHostHeader(host);
653
+ }
654
+
655
+ return this.b23_1;
656
+ case 6:
657
+ this.d7_1 = 7;
658
+ var tmp_0 = this.f7_1;
659
+ if (tmp_0 instanceof Error) {
660
+ var t = this.f7_1;
661
+ this.b23_1.r21();
662
+ throw t;
663
+ } else {
664
+ throw this.f7_1;
665
+ }
666
+
667
+ case 7:
668
+ throw this.f7_1;
669
+ }
670
+ } catch ($p) {
671
+ var e = $p;
672
+ if (this.d7_1 === 7) {
673
+ throw e;
674
+ } else {
675
+ this.c7_1 = this.d7_1;
676
+ this.f7_1 = e;
677
+ }
678
+ }
679
+ while (true);
680
+ };
681
+ var properties_initialized_HttpParser_kt_uedryv;
682
+ function _init_properties_HttpParser_kt__gbdom1() {
683
+ if (!properties_initialized_HttpParser_kt_uedryv) {
684
+ properties_initialized_HttpParser_kt_uedryv = true;
685
+ hostForbiddenSymbols = setOf([new Char(_Char___init__impl__6a9atx(47)), new Char(_Char___init__impl__6a9atx(63)), new Char(_Char___init__impl__6a9atx(35)), new Char(_Char___init__impl__6a9atx(64))]);
686
+ httpLineEndings = LineEndingMode__plus_impl_ttpz2j(Companion_getInstance().a1a_1, Companion_getInstance().z19_1);
687
+ versions = Companion_instance.f23(listOf(['HTTP/1.0', 'HTTP/1.1']));
688
+ }
689
+ }
690
+ function get_CrLf() {
691
+ _init_properties_Multipart_kt__ato98a();
692
+ return CrLf;
693
+ }
694
+ var CrLf;
695
+ function get_PrefixString() {
696
+ _init_properties_Multipart_kt__ato98a();
697
+ return PrefixString;
698
+ }
699
+ var PrefixString;
700
+ function Preamble(body) {
701
+ MultipartEvent.call(this);
702
+ this.g23_1 = body;
703
+ }
704
+ function MultipartPart(headers, body) {
705
+ MultipartEvent.call(this);
706
+ this.h23_1 = headers;
707
+ this.i23_1 = body;
708
+ }
709
+ function Epilogue(body) {
710
+ MultipartEvent.call(this);
711
+ this.j23_1 = body;
712
+ }
713
+ function MultipartEvent() {
714
+ }
715
+ function parseMultipart(_this__u8e3s4, input, contentType, contentLength, maxPartSize) {
716
+ maxPartSize = maxPartSize === VOID ? new Long(-1, 2147483647) : maxPartSize;
717
+ _init_properties_Multipart_kt__ato98a();
718
+ if (!MultiPart_getInstance().x1o(contentType)) {
719
+ throw new UnsupportedMediaTypeExceptionCIO('Failed to parse multipart: Content-Type should be multipart/* but it is ' + toString(contentType));
720
+ }
721
+ var boundaryByteBuffer = parseBoundaryInternal(contentType);
722
+ var boundaryBytes = ByteString_init_$Create$(boundaryByteBuffer);
723
+ return parseMultipart_0(_this__u8e3s4, boundaryBytes, input, contentLength, maxPartSize);
724
+ }
725
+ function parseBoundaryInternal(contentType) {
726
+ _init_properties_Multipart_kt__ato98a();
727
+ var boundaryParameter = findBoundary(contentType);
728
+ if (boundaryParameter === -1) {
729
+ throw IOException_init_$Create$("Failed to parse multipart: Content-Type's boundary parameter is missing");
730
+ }
731
+ var boundaryStart = boundaryParameter + 9 | 0;
732
+ var boundaryBytes = new Int8Array(74);
733
+ var position = {_v: 0};
734
+ parseBoundaryInternal$put(position, boundaryBytes, 13);
735
+ parseBoundaryInternal$put(position, boundaryBytes, 10);
736
+ parseBoundaryInternal$put(position, boundaryBytes, 45);
737
+ parseBoundaryInternal$put(position, boundaryBytes, 45);
738
+ var state = 0;
739
+ var inductionVariable = boundaryStart;
740
+ var last = charSequenceLength(contentType);
741
+ if (inductionVariable < last)
742
+ loop: do {
743
+ var i = inductionVariable;
744
+ inductionVariable = inductionVariable + 1 | 0;
745
+ var ch = charSequenceGet(contentType, i);
746
+ // Inline function 'kotlin.code' call
747
+ var v = Char__toInt_impl_vasixd(ch) & 65535;
748
+ if ((v & 65535) > 127) {
749
+ throw IOException_init_$Create$('Failed to parse multipart: wrong boundary byte 0x' + toString_0(v, 16) + ' - should be 7bit character');
750
+ }
751
+ switch (state) {
752
+ case 0:
753
+ if (ch !== _Char___init__impl__6a9atx(32))
754
+ if (ch === _Char___init__impl__6a9atx(34)) {
755
+ state = 2;
756
+ } else if (ch === _Char___init__impl__6a9atx(59) || ch === _Char___init__impl__6a9atx(44)) {
757
+ break loop;
758
+ } else {
759
+ state = 1;
760
+ parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
761
+ }
762
+
763
+ break;
764
+ case 1:
765
+ if (ch === _Char___init__impl__6a9atx(32) || ch === _Char___init__impl__6a9atx(44) || ch === _Char___init__impl__6a9atx(59)) {
766
+ break loop;
767
+ } else {
768
+ parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
769
+ }
770
+
771
+ break;
772
+ case 2:
773
+ if (ch === _Char___init__impl__6a9atx(92)) {
774
+ state = 3;
775
+ } else if (ch === _Char___init__impl__6a9atx(34)) {
776
+ break loop;
777
+ } else {
778
+ parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
779
+ }
780
+
781
+ break;
782
+ case 3:
783
+ parseBoundaryInternal$put(position, boundaryBytes, toByte(v));
784
+ state = 2;
785
+ break;
786
+ }
787
+ }
788
+ while (inductionVariable < last);
789
+ if (position._v === 4) {
790
+ throw IOException_init_$Create$('Empty multipart boundary is not allowed');
791
+ }
792
+ return copyOfRange(boundaryBytes, 0, position._v);
793
+ }
794
+ function parseMultipart_0(_this__u8e3s4, boundaryPrefixed, input, totalLength, maxPartSize) {
795
+ _init_properties_Multipart_kt__ato98a();
796
+ return produce(_this__u8e3s4, VOID, VOID, parseMultipart$slambda_0(input, boundaryPrefixed, maxPartSize, totalLength, null));
797
+ }
798
+ function findBoundary(contentType) {
799
+ _init_properties_Multipart_kt__ato98a();
800
+ var state = 0;
801
+ var paramNameCount = 0;
802
+ var inductionVariable = 0;
803
+ var last = charSequenceLength(contentType) - 1 | 0;
804
+ if (inductionVariable <= last)
805
+ do {
806
+ var i = inductionVariable;
807
+ inductionVariable = inductionVariable + 1 | 0;
808
+ var ch = charSequenceGet(contentType, i);
809
+ switch (state) {
810
+ case 0:
811
+ if (ch === _Char___init__impl__6a9atx(59)) {
812
+ state = 1;
813
+ paramNameCount = 0;
814
+ }
815
+
816
+ break;
817
+ case 1:
818
+ if (ch === _Char___init__impl__6a9atx(61)) {
819
+ state = 2;
820
+ } else if (ch === _Char___init__impl__6a9atx(59)) {
821
+ paramNameCount = 0;
822
+ } else if (ch === _Char___init__impl__6a9atx(44)) {
823
+ state = 0;
824
+ } else if (ch !== _Char___init__impl__6a9atx(32))
825
+ if (paramNameCount === 0 && startsWith(contentType, 'boundary=', i, true)) {
826
+ return i;
827
+ } else {
828
+ paramNameCount = paramNameCount + 1 | 0;
829
+ }
830
+
831
+ break;
832
+ case 2:
833
+ if (ch === _Char___init__impl__6a9atx(34))
834
+ state = 3;
835
+ else if (ch === _Char___init__impl__6a9atx(44))
836
+ state = 0;
837
+ else if (ch === _Char___init__impl__6a9atx(59)) {
838
+ state = 1;
839
+ paramNameCount = 0;
840
+ }
841
+
842
+ break;
843
+ case 3:
844
+ if (ch === _Char___init__impl__6a9atx(34)) {
845
+ state = 1;
846
+ paramNameCount = 0;
847
+ } else if (ch === _Char___init__impl__6a9atx(92)) {
848
+ state = 4;
849
+ }
850
+
851
+ break;
852
+ case 4:
853
+ state = 3;
854
+ break;
855
+ }
856
+ }
857
+ while (inductionVariable <= last);
858
+ return -1;
859
+ }
860
+ function parsePreambleImpl(boundary, input, output, limit, $completion) {
861
+ limit = limit === VOID ? new Long(-1, 2147483647) : limit;
862
+ return readUntil(input, boundary, output, limit, true, $completion);
863
+ }
864
+ function parsePartHeadersImpl(input, $completion) {
865
+ var tmp = new $parsePartHeadersImplCOROUTINE$(input, $completion);
866
+ tmp.e7_1 = Unit_instance;
867
+ tmp.f7_1 = null;
868
+ return tmp.k7();
869
+ }
870
+ function parsePartBodyImpl(boundaryPrefixed, input, output, headers, limit, $completion) {
871
+ var tmp = new $parsePartBodyImplCOROUTINE$(boundaryPrefixed, input, output, headers, limit, $completion);
872
+ tmp.e7_1 = Unit_instance;
873
+ tmp.f7_1 = null;
874
+ return tmp.k7();
875
+ }
876
+ function skipIfFoundReadCount(_this__u8e3s4, prefix, $completion) {
877
+ var tmp = new $skipIfFoundReadCountCOROUTINE$(_this__u8e3s4, prefix, $completion);
878
+ tmp.e7_1 = Unit_instance;
879
+ tmp.f7_1 = null;
880
+ return tmp.k7();
881
+ }
882
+ function throwLimitExceeded(actual, limit) {
883
+ _init_properties_Multipart_kt__ato98a();
884
+ throw IOException_init_$Create$('Multipart content length exceeds limit ' + actual.toString() + ' > ' + limit.toString() + '; ' + "limit is defined using 'formFieldLimit' argument");
885
+ }
886
+ function parseBoundaryInternal$put(position, boundaryBytes, value) {
887
+ if (position._v >= boundaryBytes.length) {
888
+ throw IOException_init_$Create$("Failed to parse multipart: boundary shouldn't be longer than 70 characters");
889
+ }
890
+ var _unary__edvuaz = position._v;
891
+ position._v = _unary__edvuaz + 1 | 0;
892
+ boundaryBytes[_unary__edvuaz] = value;
893
+ }
894
+ function parseMultipart$slambda$slambda($firstBoundary, $countedInput, resultContinuation) {
895
+ this.d25_1 = $firstBoundary;
896
+ this.e25_1 = $countedInput;
897
+ CoroutineImpl.call(this, resultContinuation);
898
+ }
899
+ protoOf(parseMultipart$slambda$slambda).g25 = function ($this$writer, $completion) {
900
+ var tmp = this.h25($this$writer, $completion);
901
+ tmp.e7_1 = Unit_instance;
902
+ tmp.f7_1 = null;
903
+ return tmp.k7();
904
+ };
905
+ protoOf(parseMultipart$slambda$slambda).w7 = function (p1, $completion) {
906
+ return this.g25(p1 instanceof WriterScope ? p1 : THROW_CCE(), $completion);
907
+ };
908
+ protoOf(parseMultipart$slambda$slambda).k7 = function () {
909
+ var suspendResult = this.e7_1;
910
+ $sm: do
911
+ try {
912
+ var tmp = this.c7_1;
913
+ switch (tmp) {
914
+ case 0:
915
+ this.d7_1 = 3;
916
+ this.c7_1 = 1;
917
+ suspendResult = parsePreambleImpl(this.d25_1, this.e25_1, this.f25_1.a1c_1, new Long(8193, 0), this);
918
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
919
+ return suspendResult;
920
+ }
921
+
922
+ continue $sm;
923
+ case 1:
924
+ this.c7_1 = 2;
925
+ suspendResult = this.f25_1.a1c_1.f15(this);
926
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
927
+ return suspendResult;
928
+ }
929
+
930
+ continue $sm;
931
+ case 2:
932
+ return Unit_instance;
933
+ case 3:
934
+ throw this.f7_1;
935
+ }
936
+ } catch ($p) {
937
+ var e = $p;
938
+ if (this.d7_1 === 3) {
939
+ throw e;
940
+ } else {
941
+ this.c7_1 = this.d7_1;
942
+ this.f7_1 = e;
943
+ }
944
+ }
945
+ while (true);
946
+ };
947
+ protoOf(parseMultipart$slambda$slambda).h25 = function ($this$writer, completion) {
948
+ var i = new parseMultipart$slambda$slambda(this.d25_1, this.e25_1, completion);
949
+ i.f25_1 = $this$writer;
950
+ return i;
951
+ };
952
+ function parseMultipart$slambda$slambda_0($firstBoundary, $countedInput, resultContinuation) {
953
+ var i = new parseMultipart$slambda$slambda($firstBoundary, $countedInput, resultContinuation);
954
+ var l = function ($this$writer, $completion) {
955
+ return i.g25($this$writer, $completion);
956
+ };
957
+ l.$arity = 1;
958
+ return l;
959
+ }
960
+ function parseMultipart$slambda($input, $boundaryPrefixed, $maxPartSize, $totalLength, resultContinuation) {
961
+ this.q25_1 = $input;
962
+ this.r25_1 = $boundaryPrefixed;
963
+ this.s25_1 = $maxPartSize;
964
+ this.t25_1 = $totalLength;
965
+ CoroutineImpl.call(this, resultContinuation);
966
+ }
967
+ protoOf(parseMultipart$slambda).c26 = function ($this$produce, $completion) {
968
+ var tmp = this.d26($this$produce, $completion);
969
+ tmp.e7_1 = Unit_instance;
970
+ tmp.f7_1 = null;
971
+ return tmp.k7();
972
+ };
973
+ protoOf(parseMultipart$slambda).w7 = function (p1, $completion) {
974
+ return this.c26((!(p1 == null) ? isInterface(p1, ProducerScope) : false) ? p1 : THROW_CCE(), $completion);
975
+ };
976
+ protoOf(parseMultipart$slambda).k7 = function () {
977
+ var suspendResult = this.e7_1;
978
+ $sm: do
979
+ try {
980
+ var tmp = this.c7_1;
981
+ switch (tmp) {
982
+ case 0:
983
+ this.d7_1 = 25;
984
+ this.v25_1 = counted(this.q25_1);
985
+ this.w25_1 = this.v25_1.n1d();
986
+ this.a26_1 = this.r25_1.eg(get_PrefixString().n());
987
+ this.c7_1 = 1;
988
+ suspendResult = readRemaining(writer(this.u25_1, VOID, VOID, parseMultipart$slambda$slambda_0(this.a26_1, this.v25_1, null)).y1b_1, this);
989
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
990
+ return suspendResult;
991
+ }
992
+
993
+ continue $sm;
994
+ case 1:
995
+ var preambleData = suspendResult;
996
+ if (compare(get_remaining(preambleData), new Long(0, 0)) > 0) {
997
+ this.c7_1 = 2;
998
+ suspendResult = this.u25_1.yy(new Preamble(preambleData), this);
999
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1000
+ return suspendResult;
1001
+ }
1002
+ continue $sm;
1003
+ } else {
1004
+ this.c7_1 = 3;
1005
+ continue $sm;
1006
+ }
1007
+
1008
+ case 2:
1009
+ this.c7_1 = 3;
1010
+ continue $sm;
1011
+ case 3:
1012
+ this.c7_1 = 4;
1013
+ continue $sm;
1014
+ case 4:
1015
+ if (!this.v25_1.c15()) {
1016
+ this.c7_1 = 5;
1017
+ suspendResult = skipIfFound(this.v25_1, get_PrefixString(), this);
1018
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1019
+ return suspendResult;
1020
+ }
1021
+ continue $sm;
1022
+ } else {
1023
+ this.b26_1 = false;
1024
+ this.c7_1 = 6;
1025
+ continue $sm;
1026
+ }
1027
+
1028
+ case 5:
1029
+ this.b26_1 = !suspendResult;
1030
+ this.c7_1 = 6;
1031
+ continue $sm;
1032
+ case 6:
1033
+ if (!this.b26_1) {
1034
+ this.c7_1 = 15;
1035
+ continue $sm;
1036
+ }
1037
+
1038
+ this.c7_1 = 7;
1039
+ suspendResult = skipIfFound(this.v25_1, get_CrLf(), this);
1040
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1041
+ return suspendResult;
1042
+ }
1043
+
1044
+ continue $sm;
1045
+ case 7:
1046
+ this.c7_1 = 8;
1047
+ suspendResult = skipIfFound(this.v25_1, this.a26_1, this);
1048
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1049
+ return suspendResult;
1050
+ }
1051
+
1052
+ continue $sm;
1053
+ case 8:
1054
+ if (suspendResult) {
1055
+ this.c7_1 = 4;
1056
+ continue $sm;
1057
+ } else {
1058
+ this.c7_1 = 9;
1059
+ continue $sm;
1060
+ }
1061
+
1062
+ case 9:
1063
+ this.x25_1 = new ByteChannel();
1064
+ this.z25_1 = CompletableDeferred();
1065
+ var part = new MultipartPart(this.z25_1, this.x25_1);
1066
+ this.c7_1 = 10;
1067
+ suspendResult = this.u25_1.yy(part, this);
1068
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1069
+ return suspendResult;
1070
+ }
1071
+
1072
+ continue $sm;
1073
+ case 10:
1074
+ this.y25_1 = null;
1075
+ this.d7_1 = 14;
1076
+ this.c7_1 = 11;
1077
+ suspendResult = parsePartHeadersImpl(this.v25_1, this);
1078
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1079
+ return suspendResult;
1080
+ }
1081
+
1082
+ continue $sm;
1083
+ case 11:
1084
+ this.y25_1 = suspendResult;
1085
+ if (!this.z25_1.lq(this.y25_1)) {
1086
+ this.y25_1.r21();
1087
+ throw CancellationException_init_$Create$('Multipart processing has been cancelled');
1088
+ }
1089
+
1090
+ this.c7_1 = 12;
1091
+ suspendResult = parsePartBodyImpl(this.r25_1, this.v25_1, this.x25_1, this.y25_1, this.s25_1, this);
1092
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1093
+ return suspendResult;
1094
+ }
1095
+
1096
+ continue $sm;
1097
+ case 12:
1098
+ this.x25_1.q2();
1099
+ this.d7_1 = 25;
1100
+ this.c7_1 = 13;
1101
+ continue $sm;
1102
+ case 13:
1103
+ this.d7_1 = 25;
1104
+ this.c7_1 = 4;
1105
+ continue $sm;
1106
+ case 14:
1107
+ this.d7_1 = 25;
1108
+ var tmp_0 = this.f7_1;
1109
+ if (tmp_0 instanceof Error) {
1110
+ var cause = this.f7_1;
1111
+ if (this.z25_1.nq(cause)) {
1112
+ var tmp0_safe_receiver = this.y25_1;
1113
+ if (tmp0_safe_receiver == null)
1114
+ null;
1115
+ else {
1116
+ tmp0_safe_receiver.r21();
1117
+ }
1118
+ }
1119
+ close(this.x25_1, cause);
1120
+ throw cause;
1121
+ } else {
1122
+ throw this.f7_1;
1123
+ }
1124
+
1125
+ case 15:
1126
+ this.c7_1 = 16;
1127
+ suspendResult = skipIfFound(this.v25_1, get_CrLf(), this);
1128
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1129
+ return suspendResult;
1130
+ }
1131
+
1132
+ continue $sm;
1133
+ case 16:
1134
+ this.c7_1 = 17;
1135
+ suspendResult = skipIfFound(this.v25_1, get_CrLf(), this);
1136
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1137
+ return suspendResult;
1138
+ }
1139
+
1140
+ continue $sm;
1141
+ case 17:
1142
+ if (!(this.t25_1 == null)) {
1143
+ var consumedExceptEpilogue = subtract(this.v25_1.n1d(), this.w25_1);
1144
+ var size = subtract(this.t25_1, consumedExceptEpilogue);
1145
+ if (compare(size, new Long(2147483647, 0)) > 0)
1146
+ throw IOException_init_$Create$('Failed to parse multipart: prologue is too long');
1147
+ if (compare(size, new Long(0, 0)) > 0) {
1148
+ this.c7_1 = 21;
1149
+ suspendResult = readPacket(this.v25_1, convertToInt(size), this);
1150
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1151
+ return suspendResult;
1152
+ }
1153
+ continue $sm;
1154
+ } else {
1155
+ this.c7_1 = 23;
1156
+ continue $sm;
1157
+ }
1158
+ } else {
1159
+ this.c7_1 = 18;
1160
+ suspendResult = readRemaining(this.v25_1, this);
1161
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1162
+ return suspendResult;
1163
+ }
1164
+ continue $sm;
1165
+ }
1166
+
1167
+ case 18:
1168
+ var epilogueContent = suspendResult;
1169
+ if (!epilogueContent.mg()) {
1170
+ this.c7_1 = 19;
1171
+ suspendResult = this.u25_1.yy(new Epilogue(epilogueContent), this);
1172
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1173
+ return suspendResult;
1174
+ }
1175
+ continue $sm;
1176
+ } else {
1177
+ this.c7_1 = 20;
1178
+ continue $sm;
1179
+ }
1180
+
1181
+ case 19:
1182
+ this.c7_1 = 20;
1183
+ continue $sm;
1184
+ case 20:
1185
+ this.c7_1 = 24;
1186
+ continue $sm;
1187
+ case 21:
1188
+ var ARGUMENT = suspendResult;
1189
+ var ARGUMENT_0 = new Epilogue(ARGUMENT);
1190
+ this.c7_1 = 22;
1191
+ suspendResult = this.u25_1.yy(ARGUMENT_0, this);
1192
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1193
+ return suspendResult;
1194
+ }
1195
+
1196
+ continue $sm;
1197
+ case 22:
1198
+ this.c7_1 = 23;
1199
+ continue $sm;
1200
+ case 23:
1201
+ this.c7_1 = 24;
1202
+ continue $sm;
1203
+ case 24:
1204
+ return Unit_instance;
1205
+ case 25:
1206
+ throw this.f7_1;
1207
+ }
1208
+ } catch ($p) {
1209
+ var e = $p;
1210
+ if (this.d7_1 === 25) {
1211
+ throw e;
1212
+ } else {
1213
+ this.c7_1 = this.d7_1;
1214
+ this.f7_1 = e;
1215
+ }
1216
+ }
1217
+ while (true);
1218
+ };
1219
+ protoOf(parseMultipart$slambda).d26 = function ($this$produce, completion) {
1220
+ var i = new parseMultipart$slambda(this.q25_1, this.r25_1, this.s25_1, this.t25_1, completion);
1221
+ i.u25_1 = $this$produce;
1222
+ return i;
1223
+ };
1224
+ function parseMultipart$slambda_0($input, $boundaryPrefixed, $maxPartSize, $totalLength, resultContinuation) {
1225
+ var i = new parseMultipart$slambda($input, $boundaryPrefixed, $maxPartSize, $totalLength, resultContinuation);
1226
+ var l = function ($this$produce, $completion) {
1227
+ return i.c26($this$produce, $completion);
1228
+ };
1229
+ l.$arity = 1;
1230
+ return l;
1231
+ }
1232
+ function $parsePartHeadersImplCOROUTINE$(input, resultContinuation) {
1233
+ CoroutineImpl.call(this, resultContinuation);
1234
+ this.s23_1 = input;
1235
+ }
1236
+ protoOf($parsePartHeadersImplCOROUTINE$).k7 = function () {
1237
+ var suspendResult = this.e7_1;
1238
+ $sm: do
1239
+ try {
1240
+ var tmp = this.c7_1;
1241
+ switch (tmp) {
1242
+ case 0:
1243
+ this.d7_1 = 3;
1244
+ this.t23_1 = new CharArrayBuilder();
1245
+ this.d7_1 = 2;
1246
+ this.c7_1 = 1;
1247
+ suspendResult = parseHeaders(this.s23_1, this.t23_1, VOID, this);
1248
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1249
+ return suspendResult;
1250
+ }
1251
+
1252
+ continue $sm;
1253
+ case 1:
1254
+ var tmp0_elvis_lhs = suspendResult;
1255
+ var tmp_0;
1256
+ if (tmp0_elvis_lhs == null) {
1257
+ throw EOFException_init_$Create$('Failed to parse multipart headers: unexpected end of stream');
1258
+ } else {
1259
+ tmp_0 = tmp0_elvis_lhs;
1260
+ }
1261
+
1262
+ return tmp_0;
1263
+ case 2:
1264
+ this.d7_1 = 3;
1265
+ var tmp_1 = this.f7_1;
1266
+ if (tmp_1 instanceof Error) {
1267
+ var t = this.f7_1;
1268
+ this.t23_1.r21();
1269
+ throw t;
1270
+ } else {
1271
+ throw this.f7_1;
1272
+ }
1273
+
1274
+ case 3:
1275
+ throw this.f7_1;
1276
+ }
1277
+ } catch ($p) {
1278
+ var e = $p;
1279
+ if (this.d7_1 === 3) {
1280
+ throw e;
1281
+ } else {
1282
+ this.c7_1 = this.d7_1;
1283
+ this.f7_1 = e;
1284
+ }
1285
+ }
1286
+ while (true);
1287
+ };
1288
+ function $parsePartBodyImplCOROUTINE$(boundaryPrefixed, input, output, headers, limit, resultContinuation) {
1289
+ CoroutineImpl.call(this, resultContinuation);
1290
+ this.c24_1 = boundaryPrefixed;
1291
+ this.d24_1 = input;
1292
+ this.e24_1 = output;
1293
+ this.f24_1 = headers;
1294
+ this.g24_1 = limit;
1295
+ }
1296
+ protoOf($parsePartBodyImplCOROUTINE$).k7 = function () {
1297
+ var suspendResult = this.e7_1;
1298
+ $sm: do
1299
+ try {
1300
+ var tmp = this.c7_1;
1301
+ switch (tmp) {
1302
+ case 0:
1303
+ this.d7_1 = 6;
1304
+ var tmp0_safe_receiver = this.f24_1.v1h('Content-Length');
1305
+ var contentLength = tmp0_safe_receiver == null ? null : parseDecLong(tmp0_safe_receiver);
1306
+ if (contentLength == null) {
1307
+ this.c7_1 = 3;
1308
+ suspendResult = readUntil(this.d24_1, this.c24_1, this.e24_1, this.g24_1, true, this);
1309
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1310
+ return suspendResult;
1311
+ }
1312
+ continue $sm;
1313
+ } else {
1314
+ var containsUpper = this.g24_1;
1315
+ if (compare(new Long(0, 0), contentLength) <= 0 ? compare(contentLength, containsUpper) <= 0 : false) {
1316
+ this.c7_1 = 1;
1317
+ suspendResult = copyTo(this.d24_1, this.e24_1, contentLength, this);
1318
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1319
+ return suspendResult;
1320
+ }
1321
+ continue $sm;
1322
+ } else {
1323
+ var tmp_0 = this;
1324
+ throwLimitExceeded(contentLength, this.g24_1);
1325
+ }
1326
+ }
1327
+
1328
+ break;
1329
+ case 1:
1330
+ this.j24_1 = suspendResult;
1331
+ this.c7_1 = 2;
1332
+ suspendResult = skipIfFoundReadCount(this.d24_1, this.c24_1, this);
1333
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1334
+ return suspendResult;
1335
+ }
1336
+
1337
+ continue $sm;
1338
+ case 2:
1339
+ var ARGUMENT = suspendResult;
1340
+ this.i24_1 = add(this.j24_1, ARGUMENT);
1341
+ this.c7_1 = 4;
1342
+ continue $sm;
1343
+ case 3:
1344
+ this.i24_1 = suspendResult;
1345
+ this.c7_1 = 4;
1346
+ continue $sm;
1347
+ case 4:
1348
+ this.h24_1 = this.i24_1;
1349
+ this.c7_1 = 5;
1350
+ suspendResult = this.e24_1.t14(this);
1351
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1352
+ return suspendResult;
1353
+ }
1354
+
1355
+ continue $sm;
1356
+ case 5:
1357
+ return this.h24_1;
1358
+ case 6:
1359
+ throw this.f7_1;
1360
+ }
1361
+ } catch ($p) {
1362
+ var e = $p;
1363
+ if (this.d7_1 === 6) {
1364
+ throw e;
1365
+ } else {
1366
+ this.c7_1 = this.d7_1;
1367
+ this.f7_1 = e;
1368
+ }
1369
+ }
1370
+ while (true);
1371
+ };
1372
+ function $skipIfFoundReadCountCOROUTINE$(_this__u8e3s4, prefix, resultContinuation) {
1373
+ CoroutineImpl.call(this, resultContinuation);
1374
+ this.s24_1 = _this__u8e3s4;
1375
+ this.t24_1 = prefix;
1376
+ }
1377
+ protoOf($skipIfFoundReadCountCOROUTINE$).k7 = function () {
1378
+ var suspendResult = this.e7_1;
1379
+ $sm: do
1380
+ try {
1381
+ var tmp = this.c7_1;
1382
+ switch (tmp) {
1383
+ case 0:
1384
+ this.d7_1 = 3;
1385
+ this.c7_1 = 1;
1386
+ suspendResult = skipIfFound(this.s24_1, this.t24_1, this);
1387
+ if (suspendResult === get_COROUTINE_SUSPENDED()) {
1388
+ return suspendResult;
1389
+ }
1390
+
1391
+ continue $sm;
1392
+ case 1:
1393
+ if (suspendResult) {
1394
+ var tmp_0 = this;
1395
+ tmp_0.u24_1 = fromInt(this.t24_1.n());
1396
+ this.c7_1 = 2;
1397
+ continue $sm;
1398
+ } else {
1399
+ var tmp_1 = this;
1400
+ tmp_1.u24_1 = new Long(0, 0);
1401
+ this.c7_1 = 2;
1402
+ continue $sm;
1403
+ }
1404
+
1405
+ case 2:
1406
+ return this.u24_1;
1407
+ case 3:
1408
+ throw this.f7_1;
1409
+ }
1410
+ } catch ($p) {
1411
+ var e = $p;
1412
+ if (this.d7_1 === 3) {
1413
+ throw e;
1414
+ } else {
1415
+ this.c7_1 = this.d7_1;
1416
+ this.f7_1 = e;
1417
+ }
1418
+ }
1419
+ while (true);
1420
+ };
1421
+ var properties_initialized_Multipart_kt_wu0sh0;
1422
+ function _init_properties_Multipart_kt__ato98a() {
1423
+ if (!properties_initialized_Multipart_kt_wu0sh0) {
1424
+ properties_initialized_Multipart_kt_wu0sh0 = true;
1425
+ CrLf = ByteString_init_$Create$(toByteArray('\r\n'));
1426
+ PrefixString = ByteString(new Int8Array([45, 45]));
1427
+ }
1428
+ }
1429
+ function build($this, resultList, from, maxLength, idx, length, charAt) {
1430
+ // Inline function 'kotlin.collections.groupBy' call
1431
+ // Inline function 'kotlin.collections.groupByTo' call
1432
+ var destination = LinkedHashMap_init_$Create$();
1433
+ var _iterator__ex2g4s = from.i();
1434
+ while (_iterator__ex2g4s.j()) {
1435
+ var element = _iterator__ex2g4s.k();
1436
+ var key = charAt(element, idx);
1437
+ // Inline function 'kotlin.collections.getOrPut' call
1438
+ var value = destination.p1(key);
1439
+ var tmp;
1440
+ if (value == null) {
1441
+ var answer = ArrayList_init_$Create$();
1442
+ destination.w1(key, answer);
1443
+ tmp = answer;
1444
+ } else {
1445
+ tmp = value;
1446
+ }
1447
+ var list = tmp;
1448
+ list.g(element);
1449
+ }
1450
+ // Inline function 'kotlin.collections.forEach' call
1451
+ // Inline function 'kotlin.collections.iterator' call
1452
+ var _iterator__ex2g4s_0 = destination.s().i();
1453
+ while (_iterator__ex2g4s_0.j()) {
1454
+ var element_0 = _iterator__ex2g4s_0.k();
1455
+ // Inline function 'kotlin.collections.component1' call
1456
+ var ch = element_0.t().y_1;
1457
+ // Inline function 'kotlin.collections.component2' call
1458
+ var list_0 = element_0.u();
1459
+ var nextIdx = idx + 1 | 0;
1460
+ var children = ArrayList_init_$Create$();
1461
+ var tmp_0 = Companion_instance;
1462
+ // Inline function 'kotlin.collections.filter' call
1463
+ // Inline function 'kotlin.collections.filterTo' call
1464
+ var destination_0 = ArrayList_init_$Create$();
1465
+ var _iterator__ex2g4s_1 = list_0.i();
1466
+ while (_iterator__ex2g4s_1.j()) {
1467
+ var element_1 = _iterator__ex2g4s_1.k();
1468
+ if (length(element_1) > nextIdx) {
1469
+ destination_0.g(element_1);
1470
+ }
1471
+ }
1472
+ build(tmp_0, children, destination_0, maxLength, nextIdx, length, charAt);
1473
+ children.x3();
1474
+ // Inline function 'kotlin.collections.filter' call
1475
+ // Inline function 'kotlin.collections.filterTo' call
1476
+ var destination_1 = ArrayList_init_$Create$();
1477
+ var _iterator__ex2g4s_2 = list_0.i();
1478
+ while (_iterator__ex2g4s_2.j()) {
1479
+ var element_2 = _iterator__ex2g4s_2.k();
1480
+ if (length(element_2) === nextIdx) {
1481
+ destination_1.g(element_2);
1482
+ }
1483
+ }
1484
+ resultList.g(new Node(ch, destination_1, children));
1485
+ }
1486
+ }
1487
+ function AsciiCharTree$Companion$build$lambda(it) {
1488
+ return charSequenceLength(it);
1489
+ }
1490
+ function AsciiCharTree$Companion$build$lambda_0(s, idx) {
1491
+ return new Char(charSequenceGet(s, idx));
1492
+ }
1493
+ function Node(ch, exact, children) {
1494
+ this.e26_1 = ch;
1495
+ this.f26_1 = exact;
1496
+ this.g26_1 = children;
1497
+ var tmp = this;
1498
+ var tmp_0 = 0;
1499
+ // Inline function 'kotlin.arrayOfNulls' call
1500
+ var tmp_1 = Array(256);
1501
+ while (tmp_0 < 256) {
1502
+ var tmp_2 = tmp_0;
1503
+ var tmp0 = this.g26_1;
1504
+ var tmp$ret$3;
1505
+ $l$block_0: {
1506
+ // Inline function 'kotlin.collections.singleOrNull' call
1507
+ var single = null;
1508
+ var found = false;
1509
+ var _iterator__ex2g4s = tmp0.i();
1510
+ while (_iterator__ex2g4s.j()) {
1511
+ var element = _iterator__ex2g4s.k();
1512
+ // Inline function 'kotlin.code' call
1513
+ var this_0 = element.e26_1;
1514
+ if (Char__toInt_impl_vasixd(this_0) === tmp_2) {
1515
+ if (found) {
1516
+ tmp$ret$3 = null;
1517
+ break $l$block_0;
1518
+ }
1519
+ single = element;
1520
+ found = true;
1521
+ }
1522
+ }
1523
+ if (!found) {
1524
+ tmp$ret$3 = null;
1525
+ break $l$block_0;
1526
+ }
1527
+ tmp$ret$3 = single;
1528
+ }
1529
+ tmp_1[tmp_2] = tmp$ret$3;
1530
+ tmp_0 = tmp_0 + 1 | 0;
1531
+ }
1532
+ tmp.h26_1 = tmp_1;
1533
+ }
1534
+ function Companion() {
1535
+ }
1536
+ protoOf(Companion).f23 = function (from) {
1537
+ var tmp = AsciiCharTree$Companion$build$lambda;
1538
+ return this.i26(from, tmp, AsciiCharTree$Companion$build$lambda_0);
1539
+ };
1540
+ protoOf(Companion).i26 = function (from, length, charAt) {
1541
+ var tmp$ret$0;
1542
+ $l$block_0: {
1543
+ // Inline function 'kotlin.collections.maxByOrNull' call
1544
+ var iterator = from.i();
1545
+ if (!iterator.j()) {
1546
+ tmp$ret$0 = null;
1547
+ break $l$block_0;
1548
+ }
1549
+ var maxElem = iterator.k();
1550
+ if (!iterator.j()) {
1551
+ tmp$ret$0 = maxElem;
1552
+ break $l$block_0;
1553
+ }
1554
+ var maxValue = length(maxElem);
1555
+ do {
1556
+ var e = iterator.k();
1557
+ var v = length(e);
1558
+ if (compareTo(maxValue, v) < 0) {
1559
+ maxElem = e;
1560
+ maxValue = v;
1561
+ }
1562
+ }
1563
+ while (iterator.j());
1564
+ tmp$ret$0 = maxElem;
1565
+ }
1566
+ var tmp0_safe_receiver = tmp$ret$0;
1567
+ var tmp;
1568
+ if (tmp0_safe_receiver == null) {
1569
+ tmp = null;
1570
+ } else {
1571
+ // Inline function 'kotlin.let' call
1572
+ tmp = length(tmp0_safe_receiver);
1573
+ }
1574
+ var tmp1_elvis_lhs = tmp;
1575
+ var tmp_0;
1576
+ if (tmp1_elvis_lhs == null) {
1577
+ throw NoSuchElementException_init_$Create$('Unable to build char tree from an empty list');
1578
+ } else {
1579
+ tmp_0 = tmp1_elvis_lhs;
1580
+ }
1581
+ var maxLen = tmp_0;
1582
+ var tmp$ret$2;
1583
+ $l$block_2: {
1584
+ // Inline function 'kotlin.collections.any' call
1585
+ var tmp_1;
1586
+ if (isInterface(from, Collection)) {
1587
+ tmp_1 = from.l();
1588
+ } else {
1589
+ tmp_1 = false;
1590
+ }
1591
+ if (tmp_1) {
1592
+ tmp$ret$2 = false;
1593
+ break $l$block_2;
1594
+ }
1595
+ var _iterator__ex2g4s = from.i();
1596
+ while (_iterator__ex2g4s.j()) {
1597
+ var element = _iterator__ex2g4s.k();
1598
+ if (length(element) === 0) {
1599
+ tmp$ret$2 = true;
1600
+ break $l$block_2;
1601
+ }
1602
+ }
1603
+ tmp$ret$2 = false;
1604
+ }
1605
+ if (tmp$ret$2)
1606
+ throw IllegalArgumentException_init_$Create$('There should be no empty entries');
1607
+ var root = ArrayList_init_$Create$();
1608
+ build(this, root, from, maxLen, 0, length, charAt);
1609
+ root.x3();
1610
+ return new AsciiCharTree(new Node(_Char___init__impl__6a9atx(0), emptyList(), root));
1611
+ };
1612
+ var Companion_instance;
1613
+ function Companion_getInstance_1() {
1614
+ return Companion_instance;
1615
+ }
1616
+ function AsciiCharTree(root) {
1617
+ this.j26_1 = root;
1618
+ }
1619
+ function getImpl($this, index) {
1620
+ return bufferForIndex($this, index)[index % ensureNotNull($this.k21_1).length | 0];
1621
+ }
1622
+ function copy($this, startIndex, endIndex) {
1623
+ if (startIndex === endIndex)
1624
+ return '';
1625
+ var builder = StringBuilder_init_$Create$_0(endIndex - startIndex | 0);
1626
+ var buffer;
1627
+ var base = startIndex - (startIndex % 2048 | 0) | 0;
1628
+ while (base < endIndex) {
1629
+ buffer = bufferForIndex($this, base);
1630
+ // Inline function 'kotlin.comparisons.maxOf' call
1631
+ var b = startIndex - base | 0;
1632
+ var innerStartIndex = Math.max(0, b);
1633
+ // Inline function 'kotlin.comparisons.minOf' call
1634
+ var a = endIndex - base | 0;
1635
+ var innerEndIndex = Math.min(a, 2048);
1636
+ var inductionVariable = innerStartIndex;
1637
+ if (inductionVariable < innerEndIndex)
1638
+ do {
1639
+ var innerIndex = inductionVariable;
1640
+ inductionVariable = inductionVariable + 1 | 0;
1641
+ builder.r6(buffer[innerIndex]);
1642
+ }
1643
+ while (inductionVariable < innerEndIndex);
1644
+ base = base + 2048 | 0;
1645
+ }
1646
+ return builder;
1647
+ }
1648
+ function SubSequenceImpl($outer, start, end) {
1649
+ this.n26_1 = $outer;
1650
+ this.k26_1 = start;
1651
+ this.l26_1 = end;
1652
+ this.m26_1 = null;
1653
+ }
1654
+ protoOf(SubSequenceImpl).a = function () {
1655
+ return this.l26_1 - this.k26_1 | 0;
1656
+ };
1657
+ protoOf(SubSequenceImpl).b = function (index) {
1658
+ var withOffset = index + this.k26_1 | 0;
1659
+ // Inline function 'kotlin.require' call
1660
+ if (!(index >= 0)) {
1661
+ var message = 'index is negative: ' + index;
1662
+ throw IllegalArgumentException_init_$Create$(toString(message));
1663
+ }
1664
+ // Inline function 'kotlin.require' call
1665
+ if (!(withOffset < this.l26_1)) {
1666
+ var message_0 = 'index (' + index + ') should be less than length (' + this.a() + ')';
1667
+ throw IllegalArgumentException_init_$Create$(toString(message_0));
1668
+ }
1669
+ return getImpl(this.n26_1, withOffset);
1670
+ };
1671
+ protoOf(SubSequenceImpl).c = function (startIndex, endIndex) {
1672
+ // Inline function 'kotlin.require' call
1673
+ if (!(startIndex >= 0)) {
1674
+ var message = 'start is negative: ' + startIndex;
1675
+ throw IllegalArgumentException_init_$Create$(toString(message));
1676
+ }
1677
+ // Inline function 'kotlin.require' call
1678
+ if (!(startIndex <= endIndex)) {
1679
+ var message_0 = 'start (' + startIndex + ') should be less or equal to end (' + endIndex + ')';
1680
+ throw IllegalArgumentException_init_$Create$(toString(message_0));
1681
+ }
1682
+ // Inline function 'kotlin.require' call
1683
+ if (!(endIndex <= (this.l26_1 - this.k26_1 | 0))) {
1684
+ var message_1 = 'end should be less than length (' + this.a() + ')';
1685
+ throw IllegalArgumentException_init_$Create$(toString(message_1));
1686
+ }
1687
+ if (startIndex === endIndex)
1688
+ return '';
1689
+ return new SubSequenceImpl(this.n26_1, this.k26_1 + startIndex | 0, this.k26_1 + endIndex | 0);
1690
+ };
1691
+ protoOf(SubSequenceImpl).toString = function () {
1692
+ var tmp0_elvis_lhs = this.m26_1;
1693
+ var tmp;
1694
+ if (tmp0_elvis_lhs == null) {
1695
+ // Inline function 'kotlin.also' call
1696
+ var this_0 = toString(copy(this.n26_1, this.k26_1, this.l26_1));
1697
+ this.m26_1 = this_0;
1698
+ tmp = this_0;
1699
+ } else {
1700
+ tmp = tmp0_elvis_lhs;
1701
+ }
1702
+ return tmp;
1703
+ };
1704
+ protoOf(SubSequenceImpl).equals = function (other) {
1705
+ if (!(!(other == null) ? isCharSequence(other) : false))
1706
+ return false;
1707
+ if (!(charSequenceLength(other) === this.a()))
1708
+ return false;
1709
+ return rangeEqualsImpl(this.n26_1, this.k26_1, other, 0, this.a());
1710
+ };
1711
+ protoOf(SubSequenceImpl).hashCode = function () {
1712
+ var tmp0_safe_receiver = this.m26_1;
1713
+ var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : getStringHashCode(tmp0_safe_receiver);
1714
+ return tmp1_elvis_lhs == null ? hashCodeImpl(this.n26_1, this.k26_1, this.l26_1) : tmp1_elvis_lhs;
1715
+ };
1716
+ function bufferForIndex($this, index) {
1717
+ var list = $this.j21_1;
1718
+ if (list == null) {
1719
+ if (index >= 2048) {
1720
+ throwSingleBuffer($this, index);
1721
+ }
1722
+ var tmp0_elvis_lhs = $this.k21_1;
1723
+ var tmp;
1724
+ if (tmp0_elvis_lhs == null) {
1725
+ throwSingleBuffer($this, index);
1726
+ } else {
1727
+ tmp = tmp0_elvis_lhs;
1728
+ }
1729
+ return tmp;
1730
+ }
1731
+ return list.m(index / ensureNotNull($this.k21_1).length | 0);
1732
+ }
1733
+ function throwSingleBuffer($this, index) {
1734
+ if ($this.m21_1)
1735
+ throw IllegalStateException_init_$Create$('Buffer is already released');
1736
+ throw IndexOutOfBoundsException_init_$Create$('' + index + ' is not in range [0; ' + currentPosition($this) + ')');
1737
+ }
1738
+ function nonFullBuffer($this) {
1739
+ return $this.n21_1 === 0 ? appendNewArray($this) : ensureNotNull($this.k21_1);
1740
+ }
1741
+ function appendNewArray($this) {
1742
+ var newBuffer = $this.i21_1.g1e();
1743
+ var existing = $this.k21_1;
1744
+ $this.k21_1 = newBuffer;
1745
+ $this.n21_1 = newBuffer.length;
1746
+ $this.m21_1 = false;
1747
+ if (!(existing == null)) {
1748
+ var tmp0_elvis_lhs = $this.j21_1;
1749
+ var tmp;
1750
+ if (tmp0_elvis_lhs == null) {
1751
+ // Inline function 'kotlin.also' call
1752
+ var this_0 = ArrayList_init_$Create$();
1753
+ $this.j21_1 = this_0;
1754
+ this_0.g(existing);
1755
+ tmp = this_0;
1756
+ } else {
1757
+ tmp = tmp0_elvis_lhs;
1758
+ }
1759
+ var list = tmp;
1760
+ list.g(newBuffer);
1761
+ }
1762
+ return newBuffer;
1763
+ }
1764
+ function rangeEqualsImpl($this, start, other, otherStart, length) {
1765
+ var inductionVariable = 0;
1766
+ if (inductionVariable < length)
1767
+ do {
1768
+ var i = inductionVariable;
1769
+ inductionVariable = inductionVariable + 1 | 0;
1770
+ if (!(getImpl($this, start + i | 0) === charSequenceGet(other, otherStart + i | 0)))
1771
+ return false;
1772
+ }
1773
+ while (inductionVariable < length);
1774
+ return true;
1775
+ }
1776
+ function hashCodeImpl($this, start, end) {
1777
+ var hc = 0;
1778
+ var inductionVariable = start;
1779
+ if (inductionVariable < end)
1780
+ do {
1781
+ var i = inductionVariable;
1782
+ inductionVariable = inductionVariable + 1 | 0;
1783
+ var tmp = imul(31, hc);
1784
+ // Inline function 'kotlin.code' call
1785
+ var this_0 = getImpl($this, i);
1786
+ hc = tmp + Char__toInt_impl_vasixd(this_0) | 0;
1787
+ }
1788
+ while (inductionVariable < end);
1789
+ return hc;
1790
+ }
1791
+ function currentPosition($this) {
1792
+ return ensureNotNull($this.k21_1).length - $this.n21_1 | 0;
1793
+ }
1794
+ function CharArrayBuilder(pool) {
1795
+ pool = pool === VOID ? get_CharArrayPool() : pool;
1796
+ this.i21_1 = pool;
1797
+ this.j21_1 = null;
1798
+ this.k21_1 = null;
1799
+ this.l21_1 = null;
1800
+ this.m21_1 = false;
1801
+ this.n21_1 = 0;
1802
+ this.o21_1 = 0;
1803
+ }
1804
+ protoOf(CharArrayBuilder).a = function () {
1805
+ return this.o21_1;
1806
+ };
1807
+ protoOf(CharArrayBuilder).b = function (index) {
1808
+ // Inline function 'kotlin.require' call
1809
+ if (!(index >= 0)) {
1810
+ var message = 'index is negative: ' + index;
1811
+ throw IllegalArgumentException_init_$Create$(toString(message));
1812
+ }
1813
+ // Inline function 'kotlin.require' call
1814
+ if (!(index < this.o21_1)) {
1815
+ var message_0 = 'index ' + index + ' is not in range [0, ' + this.o21_1 + ')';
1816
+ throw IllegalArgumentException_init_$Create$(toString(message_0));
1817
+ }
1818
+ return getImpl(this, index);
1819
+ };
1820
+ protoOf(CharArrayBuilder).c = function (startIndex, endIndex) {
1821
+ // Inline function 'kotlin.require' call
1822
+ if (!(startIndex <= endIndex)) {
1823
+ var message = 'startIndex (' + startIndex + ') should be less or equal to endIndex (' + endIndex + ')';
1824
+ throw IllegalArgumentException_init_$Create$(toString(message));
1825
+ }
1826
+ // Inline function 'kotlin.require' call
1827
+ if (!(startIndex >= 0)) {
1828
+ var message_0 = 'startIndex is negative: ' + startIndex;
1829
+ throw IllegalArgumentException_init_$Create$(toString(message_0));
1830
+ }
1831
+ // Inline function 'kotlin.require' call
1832
+ if (!(endIndex <= this.o21_1)) {
1833
+ var message_1 = 'endIndex (' + endIndex + ') is greater than length (' + this.o21_1 + ')';
1834
+ throw IllegalArgumentException_init_$Create$(toString(message_1));
1835
+ }
1836
+ return new SubSequenceImpl(this, startIndex, endIndex);
1837
+ };
1838
+ protoOf(CharArrayBuilder).toString = function () {
1839
+ var tmp0_elvis_lhs = this.l21_1;
1840
+ var tmp;
1841
+ if (tmp0_elvis_lhs == null) {
1842
+ // Inline function 'kotlin.also' call
1843
+ var this_0 = toString(copy(this, 0, this.o21_1));
1844
+ this.l21_1 = this_0;
1845
+ tmp = this_0;
1846
+ } else {
1847
+ tmp = tmp0_elvis_lhs;
1848
+ }
1849
+ return tmp;
1850
+ };
1851
+ protoOf(CharArrayBuilder).equals = function (other) {
1852
+ if (!(!(other == null) ? isCharSequence(other) : false))
1853
+ return false;
1854
+ if (!(this.o21_1 === charSequenceLength(other)))
1855
+ return false;
1856
+ return rangeEqualsImpl(this, 0, other, 0, this.o21_1);
1857
+ };
1858
+ protoOf(CharArrayBuilder).hashCode = function () {
1859
+ var tmp0_safe_receiver = this.l21_1;
1860
+ var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : getStringHashCode(tmp0_safe_receiver);
1861
+ return tmp1_elvis_lhs == null ? hashCodeImpl(this, 0, this.o21_1) : tmp1_elvis_lhs;
1862
+ };
1863
+ protoOf(CharArrayBuilder).r6 = function (value) {
1864
+ nonFullBuffer(this)[ensureNotNull(this.k21_1).length - this.n21_1 | 0] = value;
1865
+ this.l21_1 = null;
1866
+ this.n21_1 = this.n21_1 - 1 | 0;
1867
+ this.o21_1 = this.o21_1 + 1 | 0;
1868
+ return this;
1869
+ };
1870
+ protoOf(CharArrayBuilder).qa = function (value, startIndex, endIndex) {
1871
+ if (value == null)
1872
+ return this;
1873
+ var current = startIndex;
1874
+ while (current < endIndex) {
1875
+ var buffer = nonFullBuffer(this);
1876
+ var offset = buffer.length - this.n21_1 | 0;
1877
+ var tmp0 = endIndex - current | 0;
1878
+ // Inline function 'kotlin.math.min' call
1879
+ var b = this.n21_1;
1880
+ var bytesToCopy = Math.min(tmp0, b);
1881
+ var inductionVariable = 0;
1882
+ if (inductionVariable < bytesToCopy)
1883
+ do {
1884
+ var i = inductionVariable;
1885
+ inductionVariable = inductionVariable + 1 | 0;
1886
+ buffer[offset + i | 0] = charSequenceGet(value, current + i | 0);
1887
+ }
1888
+ while (inductionVariable < bytesToCopy);
1889
+ current = current + bytesToCopy | 0;
1890
+ this.n21_1 = this.n21_1 - bytesToCopy | 0;
1891
+ }
1892
+ this.l21_1 = null;
1893
+ this.o21_1 = this.o21_1 + (endIndex - startIndex | 0) | 0;
1894
+ return this;
1895
+ };
1896
+ protoOf(CharArrayBuilder).h = function (value) {
1897
+ if (value == null)
1898
+ return this;
1899
+ return this.qa(value, 0, charSequenceLength(value));
1900
+ };
1901
+ protoOf(CharArrayBuilder).r21 = function () {
1902
+ var list = this.j21_1;
1903
+ if (!(list == null)) {
1904
+ this.k21_1 = null;
1905
+ var inductionVariable = 0;
1906
+ var last = list.n();
1907
+ if (inductionVariable < last)
1908
+ do {
1909
+ var i = inductionVariable;
1910
+ inductionVariable = inductionVariable + 1 | 0;
1911
+ this.i21_1.h1e(list.m(i));
1912
+ }
1913
+ while (inductionVariable < last);
1914
+ } else {
1915
+ var tmp0_safe_receiver = this.k21_1;
1916
+ if (tmp0_safe_receiver == null)
1917
+ null;
1918
+ else {
1919
+ // Inline function 'kotlin.let' call
1920
+ this.i21_1.h1e(tmp0_safe_receiver);
1921
+ }
1922
+ this.k21_1 = null;
1923
+ }
1924
+ this.m21_1 = true;
1925
+ this.j21_1 = null;
1926
+ this.l21_1 = null;
1927
+ this.o21_1 = 0;
1928
+ this.n21_1 = 0;
1929
+ };
1930
+ function get_CharArrayPool() {
1931
+ _init_properties_CharArrayPool_kt__u4nq0d();
1932
+ return CharArrayPool;
1933
+ }
1934
+ var CharArrayPool;
1935
+ function CharArrayPool$1() {
1936
+ NoPoolImpl.call(this);
1937
+ }
1938
+ protoOf(CharArrayPool$1).g1e = function () {
1939
+ return charArray(2048);
1940
+ };
1941
+ function CharArrayPool$2() {
1942
+ DefaultPool.call(this, 4096);
1943
+ }
1944
+ protoOf(CharArrayPool$2).z1d = function () {
1945
+ return charArray(2048);
1946
+ };
1947
+ var properties_initialized_CharArrayPool_kt_aq0u0f;
1948
+ function _init_properties_CharArrayPool_kt__u4nq0d() {
1949
+ if (!properties_initialized_CharArrayPool_kt_aq0u0f) {
1950
+ properties_initialized_CharArrayPool_kt_aq0u0f = true;
1951
+ var tmp;
1952
+ if (isPoolingDisabled()) {
1953
+ tmp = new CharArrayPool$1();
1954
+ } else {
1955
+ tmp = new CharArrayPool$2();
1956
+ }
1957
+ CharArrayPool = tmp;
1958
+ }
1959
+ }
1960
+ var DefaultHttpMethods;
1961
+ var HexTable;
1962
+ var HexLetterTable;
1963
+ function hashCodeLowerCase(_this__u8e3s4, start, end) {
1964
+ start = start === VOID ? 0 : start;
1965
+ end = end === VOID ? charSequenceLength(_this__u8e3s4) : end;
1966
+ _init_properties_Chars_kt__d3i39x();
1967
+ var hashCode = 0;
1968
+ var inductionVariable = start;
1969
+ if (inductionVariable < end)
1970
+ do {
1971
+ var pos = inductionVariable;
1972
+ inductionVariable = inductionVariable + 1 | 0;
1973
+ // Inline function 'kotlin.code' call
1974
+ var this_0 = charSequenceGet(_this__u8e3s4, pos);
1975
+ // Inline function 'io.ktor.http.cio.internals.toLowerCase' call
1976
+ var this_1 = Char__toInt_impl_vasixd(this_0);
1977
+ var tmp;
1978
+ // Inline function 'kotlin.code' call
1979
+ var this_2 = _Char___init__impl__6a9atx(65);
1980
+ var containsLower = Char__toInt_impl_vasixd(this_2);
1981
+ var tmp_0;
1982
+ // Inline function 'kotlin.code' call
1983
+ var this_3 = _Char___init__impl__6a9atx(90);
1984
+ if (this_1 <= Char__toInt_impl_vasixd(this_3)) {
1985
+ tmp_0 = containsLower <= this_1;
1986
+ } else {
1987
+ tmp_0 = false;
1988
+ }
1989
+ if (tmp_0) {
1990
+ // Inline function 'kotlin.code' call
1991
+ var this_4 = _Char___init__impl__6a9atx(97);
1992
+ var tmp_1 = Char__toInt_impl_vasixd(this_4);
1993
+ // Inline function 'kotlin.code' call
1994
+ var this_5 = _Char___init__impl__6a9atx(65);
1995
+ tmp = tmp_1 + (this_1 - Char__toInt_impl_vasixd(this_5) | 0) | 0;
1996
+ } else {
1997
+ tmp = this_1;
1998
+ }
1999
+ var v = tmp;
2000
+ hashCode = imul(31, hashCode) + v | 0;
2001
+ }
2002
+ while (inductionVariable < end);
2003
+ return hashCode;
2004
+ }
2005
+ function equalsLowerCase(_this__u8e3s4, start, end, other) {
2006
+ start = start === VOID ? 0 : start;
2007
+ end = end === VOID ? charSequenceLength(_this__u8e3s4) : end;
2008
+ _init_properties_Chars_kt__d3i39x();
2009
+ if (!((end - start | 0) === charSequenceLength(other)))
2010
+ return false;
2011
+ var inductionVariable = start;
2012
+ if (inductionVariable < end)
2013
+ do {
2014
+ var pos = inductionVariable;
2015
+ inductionVariable = inductionVariable + 1 | 0;
2016
+ // Inline function 'kotlin.code' call
2017
+ var this_0 = charSequenceGet(_this__u8e3s4, pos);
2018
+ // Inline function 'io.ktor.http.cio.internals.toLowerCase' call
2019
+ var this_1 = Char__toInt_impl_vasixd(this_0);
2020
+ var tmp;
2021
+ // Inline function 'kotlin.code' call
2022
+ var this_2 = _Char___init__impl__6a9atx(65);
2023
+ var containsLower = Char__toInt_impl_vasixd(this_2);
2024
+ var tmp_0;
2025
+ // Inline function 'kotlin.code' call
2026
+ var this_3 = _Char___init__impl__6a9atx(90);
2027
+ if (this_1 <= Char__toInt_impl_vasixd(this_3)) {
2028
+ tmp_0 = containsLower <= this_1;
2029
+ } else {
2030
+ tmp_0 = false;
2031
+ }
2032
+ if (tmp_0) {
2033
+ // Inline function 'kotlin.code' call
2034
+ var this_4 = _Char___init__impl__6a9atx(97);
2035
+ var tmp_1 = Char__toInt_impl_vasixd(this_4);
2036
+ // Inline function 'kotlin.code' call
2037
+ var this_5 = _Char___init__impl__6a9atx(65);
2038
+ tmp = tmp_1 + (this_1 - Char__toInt_impl_vasixd(this_5) | 0) | 0;
2039
+ } else {
2040
+ tmp = this_1;
2041
+ }
2042
+ var tmp_2 = tmp;
2043
+ // Inline function 'kotlin.code' call
2044
+ var this_6 = charSequenceGet(other, pos - start | 0);
2045
+ // Inline function 'io.ktor.http.cio.internals.toLowerCase' call
2046
+ var this_7 = Char__toInt_impl_vasixd(this_6);
2047
+ var tmp_3;
2048
+ // Inline function 'kotlin.code' call
2049
+ var this_8 = _Char___init__impl__6a9atx(65);
2050
+ var containsLower_0 = Char__toInt_impl_vasixd(this_8);
2051
+ var tmp_4;
2052
+ // Inline function 'kotlin.code' call
2053
+ var this_9 = _Char___init__impl__6a9atx(90);
2054
+ if (this_7 <= Char__toInt_impl_vasixd(this_9)) {
2055
+ tmp_4 = containsLower_0 <= this_7;
2056
+ } else {
2057
+ tmp_4 = false;
2058
+ }
2059
+ if (tmp_4) {
2060
+ // Inline function 'kotlin.code' call
2061
+ var this_10 = _Char___init__impl__6a9atx(97);
2062
+ var tmp_5 = Char__toInt_impl_vasixd(this_10);
2063
+ // Inline function 'kotlin.code' call
2064
+ var this_11 = _Char___init__impl__6a9atx(65);
2065
+ tmp_3 = tmp_5 + (this_7 - Char__toInt_impl_vasixd(this_11) | 0) | 0;
2066
+ } else {
2067
+ tmp_3 = this_7;
2068
+ }
2069
+ if (!(tmp_2 === tmp_3))
2070
+ return false;
2071
+ }
2072
+ while (inductionVariable < end);
2073
+ return true;
2074
+ }
2075
+ function parseDecLong(_this__u8e3s4) {
2076
+ _init_properties_Chars_kt__d3i39x();
2077
+ var length = charSequenceLength(_this__u8e3s4);
2078
+ if (length > 19) {
2079
+ numberFormatException(_this__u8e3s4);
2080
+ }
2081
+ if (length === 19)
2082
+ return parseDecLongWithCheck(_this__u8e3s4);
2083
+ var result = new Long(0, 0);
2084
+ var inductionVariable = 0;
2085
+ if (inductionVariable < length)
2086
+ do {
2087
+ var i = inductionVariable;
2088
+ inductionVariable = inductionVariable + 1 | 0;
2089
+ // Inline function 'kotlin.code' call
2090
+ var this_0 = charSequenceGet(_this__u8e3s4, i);
2091
+ var tmp$ret$0 = Char__toInt_impl_vasixd(this_0);
2092
+ var digit = subtract(fromInt(tmp$ret$0), new Long(48, 0));
2093
+ if (compare(digit, new Long(0, 0)) < 0 || compare(digit, new Long(9, 0)) > 0) {
2094
+ numberFormatException_0(_this__u8e3s4, i);
2095
+ }
2096
+ result = add(add(shiftLeft(result, 3), shiftLeft(result, 1)), digit);
2097
+ }
2098
+ while (inductionVariable < length);
2099
+ return result;
2100
+ }
2101
+ function numberFormatException(cs) {
2102
+ _init_properties_Chars_kt__d3i39x();
2103
+ throw NumberFormatException_init_$Create$('Invalid number ' + toString(cs) + ': too large for Long type');
2104
+ }
2105
+ function parseDecLongWithCheck(_this__u8e3s4) {
2106
+ _init_properties_Chars_kt__d3i39x();
2107
+ var result = new Long(0, 0);
2108
+ var inductionVariable = 0;
2109
+ var last = charSequenceLength(_this__u8e3s4) - 1 | 0;
2110
+ if (inductionVariable <= last)
2111
+ do {
2112
+ var i = inductionVariable;
2113
+ inductionVariable = inductionVariable + 1 | 0;
2114
+ // Inline function 'kotlin.code' call
2115
+ var this_0 = charSequenceGet(_this__u8e3s4, i);
2116
+ var tmp$ret$0 = Char__toInt_impl_vasixd(this_0);
2117
+ var digit = subtract(fromInt(tmp$ret$0), new Long(48, 0));
2118
+ if (compare(digit, new Long(0, 0)) < 0 || compare(digit, new Long(9, 0)) > 0) {
2119
+ numberFormatException_0(_this__u8e3s4, i);
2120
+ }
2121
+ result = add(add(shiftLeft(result, 3), shiftLeft(result, 1)), digit);
2122
+ if (compare(result, new Long(0, 0)) < 0) {
2123
+ numberFormatException(_this__u8e3s4);
2124
+ }
2125
+ }
2126
+ while (inductionVariable <= last);
2127
+ return result;
2128
+ }
2129
+ function numberFormatException_0(cs, idx) {
2130
+ _init_properties_Chars_kt__d3i39x();
2131
+ throw NumberFormatException_init_$Create$('Invalid number: ' + toString(cs) + ', wrong digit: ' + toString_1(charSequenceGet(cs, idx)) + ' at position ' + idx);
2132
+ }
2133
+ function DefaultHttpMethods$lambda(it) {
2134
+ _init_properties_Chars_kt__d3i39x();
2135
+ return it.f1u_1.length;
2136
+ }
2137
+ function DefaultHttpMethods$lambda_0(m, idx) {
2138
+ _init_properties_Chars_kt__d3i39x();
2139
+ return new Char(charCodeAt(m.f1u_1, idx));
2140
+ }
2141
+ var properties_initialized_Chars_kt_phjfhp;
2142
+ function _init_properties_Chars_kt__d3i39x() {
2143
+ if (!properties_initialized_Chars_kt_phjfhp) {
2144
+ properties_initialized_Chars_kt_phjfhp = true;
2145
+ var tmp = Companion_instance;
2146
+ var tmp_0 = Companion_getInstance_0().e1u_1;
2147
+ var tmp_1 = DefaultHttpMethods$lambda;
2148
+ DefaultHttpMethods = tmp.i26(tmp_0, tmp_1, DefaultHttpMethods$lambda_0);
2149
+ // Inline function 'kotlin.collections.map' call
2150
+ var this_0 = numberRangeToNumber(0, 255);
2151
+ // Inline function 'kotlin.collections.mapTo' call
2152
+ var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
2153
+ var inductionVariable = this_0.ge_1;
2154
+ var last = this_0.he_1;
2155
+ if (inductionVariable <= last)
2156
+ do {
2157
+ var item = inductionVariable;
2158
+ inductionVariable = inductionVariable + 1 | 0;
2159
+ var v = item;
2160
+ var tmp_2;
2161
+ if (48 <= v ? v <= 57 : false) {
2162
+ tmp_2 = subtract(numberToLong(v), new Long(48, 0));
2163
+ } else {
2164
+ var tmp_3;
2165
+ var tmp_4 = fromInt(v);
2166
+ // Inline function 'kotlin.code' call
2167
+ var this_1 = _Char___init__impl__6a9atx(97);
2168
+ var tmp$ret$0 = Char__toInt_impl_vasixd(this_1);
2169
+ if (compare(tmp_4, fromInt(tmp$ret$0)) >= 0) {
2170
+ var tmp_5 = fromInt(v);
2171
+ // Inline function 'kotlin.code' call
2172
+ var this_2 = _Char___init__impl__6a9atx(102);
2173
+ var tmp$ret$1 = Char__toInt_impl_vasixd(this_2);
2174
+ tmp_3 = compare(tmp_5, fromInt(tmp$ret$1)) <= 0;
2175
+ } else {
2176
+ tmp_3 = false;
2177
+ }
2178
+ if (tmp_3) {
2179
+ // Inline function 'kotlin.code' call
2180
+ var this_3 = _Char___init__impl__6a9atx(97);
2181
+ var tmp$ret$2 = Char__toInt_impl_vasixd(this_3);
2182
+ // Inline function 'kotlin.Long.plus' call
2183
+ var this_4 = subtract(numberToLong(v), fromInt(tmp$ret$2));
2184
+ tmp_2 = add(this_4, fromInt(10));
2185
+ } else {
2186
+ var tmp_6;
2187
+ var tmp_7 = fromInt(v);
2188
+ // Inline function 'kotlin.code' call
2189
+ var this_5 = _Char___init__impl__6a9atx(65);
2190
+ var tmp$ret$4 = Char__toInt_impl_vasixd(this_5);
2191
+ if (compare(tmp_7, fromInt(tmp$ret$4)) >= 0) {
2192
+ var tmp_8 = fromInt(v);
2193
+ // Inline function 'kotlin.code' call
2194
+ var this_6 = _Char___init__impl__6a9atx(70);
2195
+ var tmp$ret$5 = Char__toInt_impl_vasixd(this_6);
2196
+ tmp_6 = compare(tmp_8, fromInt(tmp$ret$5)) <= 0;
2197
+ } else {
2198
+ tmp_6 = false;
2199
+ }
2200
+ if (tmp_6) {
2201
+ // Inline function 'kotlin.code' call
2202
+ var this_7 = _Char___init__impl__6a9atx(65);
2203
+ var tmp$ret$6 = Char__toInt_impl_vasixd(this_7);
2204
+ // Inline function 'kotlin.Long.plus' call
2205
+ var this_8 = subtract(numberToLong(v), fromInt(tmp$ret$6));
2206
+ tmp_2 = add(this_8, fromInt(10));
2207
+ } else {
2208
+ tmp_2 = new Long(-1, -1);
2209
+ }
2210
+ }
2211
+ }
2212
+ var tmp$ret$8 = tmp_2;
2213
+ destination.g(tmp$ret$8);
2214
+ }
2215
+ while (!(item === last));
2216
+ HexTable = toLongArray(destination);
2217
+ // Inline function 'kotlin.collections.map' call
2218
+ var this_9 = numberRangeToNumber(0, 15);
2219
+ // Inline function 'kotlin.collections.mapTo' call
2220
+ var destination_0 = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_9, 10));
2221
+ var inductionVariable_0 = this_9.ge_1;
2222
+ var last_0 = this_9.he_1;
2223
+ if (inductionVariable_0 <= last_0)
2224
+ do {
2225
+ var item_0 = inductionVariable_0;
2226
+ inductionVariable_0 = inductionVariable_0 + 1 | 0;
2227
+ var it = item_0;
2228
+ var tmp_9;
2229
+ if (it < 10) {
2230
+ tmp_9 = toByte(48 + it | 0);
2231
+ } else {
2232
+ // Inline function 'kotlin.code' call
2233
+ var this_10 = Char__minus_impl_a2frrh(Char__plus_impl_qi7pgj(_Char___init__impl__6a9atx(97), it), 10);
2234
+ var tmp$ret$0_0 = Char__toInt_impl_vasixd(this_10);
2235
+ tmp_9 = toByte(tmp$ret$0_0);
2236
+ }
2237
+ var tmp$ret$1_0 = tmp_9;
2238
+ destination_0.g(tmp$ret$1_0);
2239
+ }
2240
+ while (!(item_0 === last_0));
2241
+ HexLetterTable = toByteArray_0(destination_0);
2242
+ }
2243
+ }
2244
+ function UnsupportedMediaTypeExceptionCIO(message) {
2245
+ IOException_init_$Init$(message, this);
2246
+ captureStack(this, UnsupportedMediaTypeExceptionCIO);
2247
+ }
2248
+ function MutableRange(start, end) {
2249
+ this.d23_1 = start;
2250
+ this.e23_1 = end;
2251
+ }
2252
+ protoOf(MutableRange).toString = function () {
2253
+ return 'MutableRange(start=' + this.d23_1 + ', end=' + this.e23_1 + ')';
2254
+ };
2255
+ function skipSpacesAndHorizontalTabs(text, start, end) {
2256
+ var index = start;
2257
+ $l$loop: while (index < end) {
2258
+ var ch = text.b(index);
2259
+ if (!isWhitespace(ch) && !(ch === _Char___init__impl__6a9atx(9)))
2260
+ break $l$loop;
2261
+ index = index + 1 | 0;
2262
+ }
2263
+ return index;
2264
+ }
2265
+ function isPoolingDisabled() {
2266
+ return false;
2267
+ }
2268
+ //region block: init
2269
+ Companion_instance = new Companion();
2270
+ //endregion
2271
+ //region block: exports
2272
+ _.$_$ = _.$_$ || {};
2273
+ _.$_$.a = CIOMultipartDataBase;
11
2274
  //endregion
12
2275
  return _;
13
2276
  }));