unicode morphisms: switch to 0 terminator instead of '\0'

This commit is contained in:
Michael Sippel 2025-03-19 17:28:04 +01:00
parent 24b332c682
commit f8725c0624
Signed by: senvas
GPG key ID: F96CF119C34B64A6

View file

@ -3,7 +3,7 @@
```
morph_string_as_ascii_to_utf8 ()
<Seq ~ <ValueTerminated '\0'> Char~Ascii~x86.UInt8>
<Seq ~ <ValueTerminated 0> Char~Ascii~x86.UInt8>
--> <Seq Char~Unicode>
~ UTF-8
~ <Seq~<ValueTerminated 0> x86.UInt8>
@ -17,7 +17,7 @@ morph_string_as_utf8_to_ascii ()
<Seq Char~Unicode>
~ UTF-8
~ <Seq~<ValueTerminated 0> x86.UInt8>
--> <Seq ~ <ValueTerminated '\0'> Char~Ascii~x86.UInt8>
--> <Seq ~ <ValueTerminated 0> Char~Ascii~x86.UInt8>
```
while( *src ) {
if( *src < 128 ) {
@ -32,7 +32,7 @@ morph_string_as_utf8_to_ascii ()
```
morph_string_as_ascii_to_utf32 ()
<Seq ~ <ValueTerminated '\0'> Char~Ascii~x86.UInt8>
<Seq ~ <ValueTerminated 0> Char~Ascii~x86.UInt8>
--> <Seq Char~Unicode>
~ UTF-32LE
~ <Seq~<ValueTerminated 0> x86.UInt32>