blaise/stdlib
Graeme Geldenhuys 8f38fd1416 feat(stdlib): add CodePointToString UTF-8 encoder to strutils
Adds CodePointToString(CP: Integer): string, the inverse of CodePointAt /
CodePointFromByteIndex.  It encodes a Unicode codepoint (0..U+10FFFF) as
its 1..4 byte UTF-8 sequence, providing the codepoint-aware replacement for
the Char(n) cast used in other Pascal dialects.  Chr(n) only writes a single
raw byte, which is invalid for codepoints above 127; CodePointToString emits
the correct multi-byte form.  Out-of-range values yield an empty string.

E2E tests cover single-byte ASCII, the two-byte 0xC2 0xB1 encoding of U+00B1,
a round-trip across all four UTF-8 length classes, and out-of-range handling.
2026-06-19 09:28:53 +01:00
..
src/main/pascal feat(stdlib): add CodePointToString UTF-8 encoder to strutils 2026-06-19 09:28:53 +01:00
project.xml refactor: split rtl/ into runtime/ + stdlib/, rename bcl.testing to blaise.testing 2026-05-16 00:51:18 +01:00