Mark shared global vals to fix K/N worker thread crash
(cherry picked from commit e346f0c5c0fb138cdf4a506e4e7f61234d60d10e)
This commit is contained in:
committed by
Vasily Levchenko
parent
f5db71e985
commit
65270b6ba6
@@ -5,6 +5,8 @@
|
|||||||
|
|
||||||
package kotlin.text
|
package kotlin.text
|
||||||
|
|
||||||
|
import kotlin.native.concurrent.SharedImmutable
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the index within this string of the first occurrence of the specified character, starting from the specified offset.
|
* Returns the index within this string of the first occurrence of the specified character, starting from the specified offset.
|
||||||
*/
|
*/
|
||||||
@@ -336,6 +338,7 @@ public actual fun String.compareTo(other: String, ignoreCase: Boolean): Int {
|
|||||||
else compareToIgnoreCase(this, other)
|
else compareToIgnoreCase(this, other)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@SharedImmutable
|
||||||
private val STRING_CASE_INSENSITIVE_ORDER = Comparator<String> { a, b -> a.compareTo(b, ignoreCase = true) }
|
private val STRING_CASE_INSENSITIVE_ORDER = Comparator<String> { a, b -> a.compareTo(b, ignoreCase = true) }
|
||||||
|
|
||||||
public actual val String.Companion.CASE_INSENSITIVE_ORDER: Comparator<String>
|
public actual val String.Companion.CASE_INSENSITIVE_ORDER: Comparator<String>
|
||||||
|
|||||||
Reference in New Issue
Block a user