Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding iosSimulatorArm64 target #186

Merged
merged 3 commits into from
Feb 18, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions ktoml-core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ kotlin {
macosX64()
macosArm64()
ios()
iosSimulatorArm64()

Check failure

Code scanning / ktlint

[TOO_MANY_BLANK_LINES] too many consecutive blank lines: do not use more than two consecutive blank lines

[TOO_MANY_BLANK_LINES] too many consecutive blank lines: do not use more than two consecutive blank lines


sourceSets {
all {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/**
* Specific implementation for utilities
*/

package com.akuleshov7.ktoml.utils

@Suppress("MAGIC_NUMBER")
internal actual fun StringBuilder.appendCodePointCompat(codePoint: Int): StringBuilder = when (codePoint) {
nulls marked this conversation as resolved.
Show resolved Hide resolved
in 0 until Char.MIN_SUPPLEMENTARY_CODE_POINT -> append(codePoint.toChar())
in Char.MIN_SUPPLEMENTARY_CODE_POINT..Char.MAX_CODE_POINT -> {
append(Char.MIN_HIGH_SURROGATE + ((codePoint - 0x10000) shr 10))
append(Char.MIN_LOW_SURROGATE + (codePoint and 0x3ff))
}
else -> throw IllegalArgumentException()
}