Use unsafe cast instead of conversion that creates new array
This commit is contained in:
1 parent
9751f80347
commit
5d3c14de2f
26 files changed
+101
-86
No files matched your search
+1
-1
@@ -40,6 +40,6 @@ interface Hash : HashFunction {
|
||||
}
|
||||
|
||||
fun String.encodeToUByteArray() : UByteArray{
|
||||
return encodeToByteArray().toUByteArray()
|
||||
return encodeToByteArray().asUByteArray()
|
||||
}
|
||||
|
||||
+1
-1
@@ -53,4 +53,4 @@ fun UByteArray.toHexString() : String {
|
||||
it.toString(16)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user