diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2025-02-07 20:06:00 -0500 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2025-02-07 20:06:00 -0500 |
| commit | 362146e2955eb48de85d9df04cec549dfe72624a (patch) | |
| tree | c523a2f2877f80fd6275fa058f96d675c9e06905 /test/text.tm | |
| parent | 2ff7c1aa71585e518d93c9df75d66291fdc8cf42 (diff) | |
Bugfix and minor perf improvements for text concatenation with unstable
clustering
Diffstat (limited to 'test/text.tm')
| -rw-r--r-- | test/text.tm | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/test/text.tm b/test/text.tm index 9edeee07..7d6ce831 100644 --- a/test/text.tm +++ b/test/text.tm @@ -315,3 +315,29 @@ func main(): = yes >> (a++b).length = 1 + + + do: + >> concat := "e" ++ Text.from_codepoints([Int32(0x300)]) + >> concat.length + = 1 + + >> concat2 := concat ++ Text.from_codepoints([Int32(0x302)]) + >> concat2.length + = 1 + + >> concat3 := concat2 ++ Text.from_codepoints([Int32(0x303)]) + >> concat3.length + = 1 + + >> final := Text.from_codepoints([Int32(0x65), Int32(0x300), Int32(0x302), Int32(0x303)]) + >> final.length + = 1 + >> concat3 == final + = yes + + >> concat4 := Text.from_codepoints([Int32(0x65), Int32(0x300)]) ++ Text.from_codepoints([Int32(0x302), Int32(0x303)]) + >> concat4.length + = 1 + >> concat4 == final + = yes |
