Skip to content

Commit 23858ec

Browse files
committed
import xml doc of kt_coro (6ce3e52651d3529194f6ae43298c7dc49d251ead)
1 parent 112fad9 commit 23858ec

File tree

11 files changed

+225
-55
lines changed

11 files changed

+225
-55
lines changed

xml/kt_coro/cpp.xml

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2684,15 +2684,32 @@
26842684

26852685
If `len` is omitted, all characters from position `pos` to the end of
26862686
`this` String are included.
2687+
```haxe
2688+
"abcde".substr(3) // de
2689+
```
26872690

26882691
If `pos` is negative, its value is calculated from the end of `this`
26892692
String by `this.length + pos`. If this yields a negative value, 0 is
26902693
used instead.
2694+
```haxe
2695+
"abcde".substr(-2) // de
2696+
```
26912697

2692-
If the calculated position + `len` exceeds `this.length`, the characters
2693-
from that position to the end of `this` String are returned.
2698+
If `len` is positive, up to `len` characters from the calculated position
2699+
to the end of `this` String are included.
2700+
```haxe
2701+
"abcde".substr(1, 2) // bc
2702+
```
26942703

2695-
If `len` is negative, the result is unspecified.</haxe_doc>
2704+
If `len` is negative, all characters from the calculated position to the end
2705+
of `this` String, except the last `abs(len)` characters, are included.
2706+
```haxe
2707+
"abcde".substr(0, -2) // abc
2708+
"abcde".substr(1, -2) // bc
2709+
```
2710+
2711+
If the calculated position + `len` exceeds `this.length`, the characters
2712+
from that position to the end of `this` String are returned.</haxe_doc>
26962713
</substr>
26972714
<substring public="1" set="method">
26982715
<f a="startIndex:?endIndex">

xml/kt_coro/flash.xml

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2321,15 +2321,32 @@
23212321

23222322
If `len` is omitted, all characters from position `pos` to the end of
23232323
`this` String are included.
2324+
```haxe
2325+
"abcde".substr(3) // de
2326+
```
23242327

23252328
If `pos` is negative, its value is calculated from the end of `this`
23262329
String by `this.length + pos`. If this yields a negative value, 0 is
23272330
used instead.
2331+
```haxe
2332+
"abcde".substr(-2) // de
2333+
```
23282334

2329-
If the calculated position + `len` exceeds `this.length`, the characters
2330-
from that position to the end of `this` String are returned.
2335+
If `len` is positive, up to `len` characters from the calculated position
2336+
to the end of `this` String are included.
2337+
```haxe
2338+
"abcde".substr(1, 2) // bc
2339+
```
23312340

2332-
If `len` is negative, the result is unspecified.</haxe_doc>
2341+
If `len` is negative, all characters from the calculated position to the end
2342+
of `this` String, except the last `abs(len)` characters, are included.
2343+
```haxe
2344+
"abcde".substr(0, -2) // abc
2345+
"abcde".substr(1, -2) // bc
2346+
```
2347+
2348+
If the calculated position + `len` exceeds `this.length`, the characters
2349+
from that position to the end of `this` String are returned.</haxe_doc>
23332350
</substr>
23342351
<substring public="1" set="method">
23352352
<f a="startIndex:?endIndex">

xml/kt_coro/hl.xml

Lines changed: 33 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2405,7 +2405,7 @@
24052405

24062406
@see https://haxe.org/manual/types-abstract-array-access.html</haxe_doc></class>
24072407
<class path="String" params="" file="/home/runner/work/haxe/haxe/std/hl/_std/String.hx">
2408-
<fromCharCode public="1" set="method" line="178" static="1">
2408+
<fromCharCode public="1" set="method" line="177" static="1">
24092409
<f a="code">
24102410
<x path="Int"/>
24112411
<c path="String"/>
@@ -2415,7 +2415,7 @@
24152415
If `code` is negative or has another invalid value, the result is
24162416
unspecified.</haxe_doc>
24172417
</fromCharCode>
2418-
<__alloc__ get="inline" set="null" line="214" static="1">
2418+
<__alloc__ get="inline" set="null" line="213" static="1">
24192419
<f a="b:length">
24202420
<x path="hl.Bytes"/>
24212421
<x path="Int"/>
@@ -2426,39 +2426,39 @@
24262426
<m n=":keep"/>
24272427
</meta>
24282428
</__alloc__>
2429-
<call_toString set="method" line="221" static="1">
2429+
<call_toString set="method" line="220" static="1">
24302430
<f a="v">
24312431
<d/>
24322432
<x path="hl.Bytes"/>
24332433
</f>
24342434
<meta><m n=":keep"/></meta>
24352435
</call_toString>
2436-
<fromUCS2 get="inline" set="null" line="226" static="1">
2436+
<fromUCS2 get="inline" set="null" line="225" static="1">
24372437
<f a="b">
24382438
<x path="hl.Bytes"/>
24392439
<c path="String"/>
24402440
</f>
24412441
<meta><m n=":has_untyped"/></meta>
24422442
</fromUCS2>
2443-
<fromUTF8 set="method" line="233" static="1">
2443+
<fromUTF8 set="method" line="232" static="1">
24442444
<f a="b">
24452445
<x path="hl.Bytes"/>
24462446
<c path="String"/>
24472447
</f>
24482448
<meta><m n=":keep"/></meta>
24492449
</fromUTF8>
2450-
<CHARS expr="new hl.NativeArray&lt;String&gt;(256)" line="243" static="1">
2450+
<CHARS expr="new hl.NativeArray&lt;String&gt;(256)" line="242" static="1">
24512451
<x path="hl.NativeArray"><c path="String"/></x>
24522452
<meta><m n=":value"><e><![CDATA[new hl.NativeArray<String>(256)]]></e></m></meta>
24532453
</CHARS>
2454-
<__char__ set="method" line="244" static="1">
2454+
<__char__ set="method" line="243" static="1">
24552455
<f a="code">
24562456
<x path="Int"/>
24572457
<c path="String"/>
24582458
</f>
24592459
<meta><m n=":keep"/></meta>
24602460
</__char__>
2461-
<__add__ set="method" line="262" static="1">
2461+
<__add__ set="method" line="261" static="1">
24622462
<f a="a:b">
24632463
<c path="String"/>
24642464
<c path="String"/>
@@ -2584,17 +2584,34 @@
25842584

25852585
If `len` is omitted, all characters from position `pos` to the end of
25862586
`this` String are included.
2587+
```haxe
2588+
"abcde".substr(3) // de
2589+
```
25872590

25882591
If `pos` is negative, its value is calculated from the end of `this`
25892592
String by `this.length + pos`. If this yields a negative value, 0 is
25902593
used instead.
2594+
```haxe
2595+
"abcde".substr(-2) // de
2596+
```
25912597

2592-
If the calculated position + `len` exceeds `this.length`, the characters
2593-
from that position to the end of `this` String are returned.
2598+
If `len` is positive, up to `len` characters from the calculated position
2599+
to the end of `this` String are included.
2600+
```haxe
2601+
"abcde".substr(1, 2) // bc
2602+
```
25942603

2595-
If `len` is negative, the result is unspecified.</haxe_doc>
2604+
If `len` is negative, all characters from the calculated position to the end
2605+
of `this` String, except the last `abs(len)` characters, are included.
2606+
```haxe
2607+
"abcde".substr(0, -2) // abc
2608+
"abcde".substr(1, -2) // bc
2609+
```
2610+
2611+
If the calculated position + `len` exceeds `this.length`, the characters
2612+
from that position to the end of `this` String are returned.</haxe_doc>
25962613
</substr>
2597-
<substring public="1" set="method" line="151">
2614+
<substring public="1" set="method" line="150">
25982615
<f a="startIndex:?endIndex">
25992616
<x path="Int"/>
26002617
<x path="Int"/>
@@ -2612,16 +2629,16 @@
26122629
If the (possibly swapped) `startIndex` exceeds `this.length`, the empty
26132630
String `""` is returned.</haxe_doc>
26142631
</substring>
2615-
<toString public="1" set="method" line="174">
2632+
<toString public="1" set="method" line="173">
26162633
<f a=""><c path="String"/></f>
26172634
<haxe_doc>Returns the String itself.</haxe_doc>
26182635
</toString>
2619-
<toUtf8 set="method" line="194"><f a=""><x path="hl.Bytes"/></f></toUtf8>
2620-
<__string set="method" line="198">
2636+
<toUtf8 set="method" line="193"><f a=""><x path="hl.Bytes"/></f></toUtf8>
2637+
<__string set="method" line="197">
26212638
<f a=""><x path="hl.Bytes"/></f>
26222639
<meta><m n=":keep"/></meta>
26232640
</__string>
2624-
<__compare set="method" line="202">
2641+
<__compare set="method" line="201">
26252642
<f a="v">
26262643
<d/>
26272644
<x path="Int"/>

xml/kt_coro/info.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
2-
"commit": "faf831a6743faf207e47c6fc2725d8bf59f9b2be",
2+
"commit": "6ce3e52651d3529194f6ae43298c7dc49d251ead",
33
"branch": "kt_coro"
44
}

xml/kt_coro/js.xml

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2296,15 +2296,32 @@
22962296

22972297
If `len` is omitted, all characters from position `pos` to the end of
22982298
`this` String are included.
2299+
```haxe
2300+
"abcde".substr(3) // de
2301+
```
22992302

23002303
If `pos` is negative, its value is calculated from the end of `this`
23012304
String by `this.length + pos`. If this yields a negative value, 0 is
23022305
used instead.
2306+
```haxe
2307+
"abcde".substr(-2) // de
2308+
```
23032309

2304-
If the calculated position + `len` exceeds `this.length`, the characters
2305-
from that position to the end of `this` String are returned.
2310+
If `len` is positive, up to `len` characters from the calculated position
2311+
to the end of `this` String are included.
2312+
```haxe
2313+
"abcde".substr(1, 2) // bc
2314+
```
23062315

2307-
If `len` is negative, the result is unspecified.</haxe_doc>
2316+
If `len` is negative, all characters from the calculated position to the end
2317+
of `this` String, except the last `abs(len)` characters, are included.
2318+
```haxe
2319+
"abcde".substr(0, -2) // abc
2320+
"abcde".substr(1, -2) // bc
2321+
```
2322+
2323+
If the calculated position + `len` exceeds `this.length`, the characters
2324+
from that position to the end of `this` String are returned.</haxe_doc>
23082325
</substr>
23092326
<new public="1" set="method">
23102327
<f a="string">

xml/kt_coro/jvm.xml

Lines changed: 23 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2352,15 +2352,32 @@
23522352

23532353
If `len` is omitted, all characters from position `pos` to the end of
23542354
`this` String are included.
2355+
```haxe
2356+
"abcde".substr(3) // de
2357+
```
23552358

23562359
If `pos` is negative, its value is calculated from the end of `this`
23572360
String by `this.length + pos`. If this yields a negative value, 0 is
23582361
used instead.
2362+
```haxe
2363+
"abcde".substr(-2) // de
2364+
```
23592365

2360-
If the calculated position + `len` exceeds `this.length`, the characters
2361-
from that position to the end of `this` String are returned.
2366+
If `len` is positive, up to `len` characters from the calculated position
2367+
to the end of `this` String are included.
2368+
```haxe
2369+
"abcde".substr(1, 2) // bc
2370+
```
23622371

2363-
If `len` is negative, the result is unspecified.</haxe_doc>
2372+
If `len` is negative, all characters from the calculated position to the end
2373+
of `this` String, except the last `abs(len)` characters, are included.
2374+
```haxe
2375+
"abcde".substr(0, -2) // abc
2376+
"abcde".substr(1, -2) // bc
2377+
```
2378+
2379+
If the calculated position + `len` exceeds `this.length`, the characters
2380+
from that position to the end of `this` String are returned.</haxe_doc>
23642381
</substr>
23652382
<substring public="1" get="inline" set="null" line="60">
23662383
<f a="startIndex:?endIndex">
@@ -83496,17 +83513,17 @@
8349683513
<x path="Int"/>
8349783514
<c path="String"/>
8349883515
</f></substr>
83499-
<substring public="1" set="method" line="108" static="1"><f a="me:startIndex:?endIndex">
83516+
<substring public="1" set="method" line="106" static="1"><f a="me:startIndex:?endIndex">
8350083517
<c path="String"/>
8350183518
<x path="Int"/>
8350283519
<x path="Int"/>
8350383520
<c path="String"/>
8350483521
</f></substring>
83505-
<toLowerCase public="1" set="method" line="129" static="1"><f a="me">
83522+
<toLowerCase public="1" set="method" line="127" static="1"><f a="me">
8350683523
<c path="String"/>
8350783524
<c path="String"/>
8350883525
</f></toLowerCase>
83509-
<toUpperCase public="1" set="method" line="133" static="1"><f a="me">
83526+
<toUpperCase public="1" set="method" line="131" static="1"><f a="me">
8351083527
<c path="String"/>
8351183528
<c path="String"/>
8351283529
</f></toUpperCase>

xml/kt_coro/lua.xml

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2449,15 +2449,32 @@
24492449

24502450
If `len` is omitted, all characters from position `pos` to the end of
24512451
`this` String are included.
2452+
```haxe
2453+
"abcde".substr(3) // de
2454+
```
24522455

24532456
If `pos` is negative, its value is calculated from the end of `this`
24542457
String by `this.length + pos`. If this yields a negative value, 0 is
24552458
used instead.
2459+
```haxe
2460+
"abcde".substr(-2) // de
2461+
```
24562462

2457-
If the calculated position + `len` exceeds `this.length`, the characters
2458-
from that position to the end of `this` String are returned.
2463+
If `len` is positive, up to `len` characters from the calculated position
2464+
to the end of `this` String are included.
2465+
```haxe
2466+
"abcde".substr(1, 2) // bc
2467+
```
24592468

2460-
If `len` is negative, the result is unspecified.</haxe_doc>
2469+
If `len` is negative, all characters from the calculated position to the end
2470+
of `this` String, except the last `abs(len)` characters, are included.
2471+
```haxe
2472+
"abcde".substr(0, -2) // abc
2473+
"abcde".substr(1, -2) // bc
2474+
```
2475+
2476+
If the calculated position + `len` exceeds `this.length`, the characters
2477+
from that position to the end of `this` String are returned.</haxe_doc>
24612478
</substr>
24622479
<new public="1" get="inline" set="null" line="39">
24632480
<f a="string">

xml/kt_coro/macro.xml

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2222,15 +2222,32 @@
22222222

22232223
If `len` is omitted, all characters from position `pos` to the end of
22242224
`this` String are included.
2225+
```haxe
2226+
"abcde".substr(3) // de
2227+
```
22252228

22262229
If `pos` is negative, its value is calculated from the end of `this`
22272230
String by `this.length + pos`. If this yields a negative value, 0 is
22282231
used instead.
2232+
```haxe
2233+
"abcde".substr(-2) // de
2234+
```
22292235

2230-
If the calculated position + `len` exceeds `this.length`, the characters
2231-
from that position to the end of `this` String are returned.
2236+
If `len` is positive, up to `len` characters from the calculated position
2237+
to the end of `this` String are included.
2238+
```haxe
2239+
"abcde".substr(1, 2) // bc
2240+
```
22322241

2233-
If `len` is negative, the result is unspecified.</haxe_doc>
2242+
If `len` is negative, all characters from the calculated position to the end
2243+
of `this` String, except the last `abs(len)` characters, are included.
2244+
```haxe
2245+
"abcde".substr(0, -2) // abc
2246+
"abcde".substr(1, -2) // bc
2247+
```
2248+
2249+
If the calculated position + `len` exceeds `this.length`, the characters
2250+
from that position to the end of `this` String are returned.</haxe_doc>
22342251
</substr>
22352252
<substring public="1" set="method">
22362253
<f a="startIndex:?endIndex">

0 commit comments

Comments
 (0)