Registry / Library

library · v0.1.1
Utf8 Width
Return the byte width of a Unicode scalar encoded as UTF-8. Reject surrogate code points and values beyond Unicode.
Use Utf8 Width
use vendor::utf8_width::utf8_width;
Run the example
nest demo utf8_width@0.1.1
blyxc native-run utf8_width-demo/main.blyx
Example source and expected output
use vendor::utf8_width::utf8_width;
fn main() {
println!(utf8_width(128512));
}
Expected output
4
Published versions
| Version | Package | Source commit | SHA-256 |
|---|---|---|---|
| 0.1.1 | Download ZIP · Browse files | c1a859ce06 | e1aa85be4cdcfbaff6436c3765f3f188928c977c9c95a41c228b9276d320b61b |
| 0.1.0 | Download ZIP · Browse files | 6349f23784 | 166349c62a937c290f4b4f4ef97cfc0f1adf9e55b90d49c1bbd1c500c3cc13d1 |