|
2026-10-22
| ||
| 17:19 | • Ticket [d63061a1ac] PRIVATE != CONTROL in Unicode status still Closed with 3... artifact: 066022a0fe user: serhiy.storchaka | |
|
2026-10-21
| ||
| 10:03 | • Closed ticket [d63061a1ac]. artifact: 5afb5bf649 user: serhiy.storchaka | |
|
2024-08-25
| ||
| 13:22 | Merge [123c58d051c8c1ab]: "merge release", "Remove private characters from regexp control table, but... check-in: 23e01ffee0 user: pooryorick tags: unchained, INCOMPATIBLE_LICENSE | |
|
2024-03-03
| ||
| 21:30 | Fix [d63061a1ac]: PRIVATE != CONTROL in Unicode check-in: 0480bdc823 user: jan.nijtmans tags: core-8-6-branch | |
|
2024-01-21
| ||
| 16:16 | • Ticket [d63061a1ac] PRIVATE != CONTROL in Unicode status still Open with 3 o... artifact: f2dfc53016 user: jan.nijtmans | |
|
2024-01-19
| ||
| 12:41 | • Ticket [d63061a1ac]: 3 changes artifact: 68ba061ebc user: jan.nijtmans | |
| 06:14 | • Ticket [d63061a1ac]: 3 changes artifact: 3753d481e2 user: apnadkarni | |
|
2024-01-18
| ||
| 07:45 | • Ticket [d63061a1ac]: 3 changes artifact: 02aadb0be1 user: jan.nijtmans | |
|
2024-01-15
| ||
| 10:46 | Bug [d63061a1ac]: "PRIVATE != CONTROL in Unicode". Leave out "Co" (private-use characters) from "str... closed check-in: 5219e3ff14 user: jan.nijtmans tags: bug-d63061a1ac | |
| 10:44 | • New ticket [d63061a1ac] PRIVATE != CONTROL in Unicode. artifact: 42bedce348 user: jan.nijtmans | |
PRIVATE != CONTROL in Unicode
% string is control \u000A # Unicode category "Cc" 1 % string is control \uE000 # Unicode category "Co" 1 % string is control \uFFFF # Unicode category "Cn" 0 % string is control \uFC00 # Unicode category "Cs" 0
Currently, "string is control" gives "1" if the character is of one of the Unicode categories "Cc" (a C0 or C1 control code), "Cf" (a format control character), "Co" (a private-use character), but not for "Cs" (a surrogate code point) or "Cn" (a reserved unassigned code point or a noncharacter).
Why is "Co" (a private-use character) included? It's not logical: This range is normally used for Glyphs (in e.g. China/Japan) which didn't have an entry assigned yet in an official Unicode version. Normally those are not Control codes.
Therfore, it would be more logical to leave out characters from the "Co" category from the "string is control" implementation.
For Tcl 8.6, this only affects the range from U+E000 - U+F8FF. For Tcl 8.7, it affects the ranges U+F0000 - U+FFFFD and U+100000 - U+10FFFD as well.
23e01ffee0Merge [123c58d051c8c1ab]: "merge release", "Remove private characters from regexp control table, but add them back in [:cntrl:] class (so no change in regexp handling). Eliminated (size_t) type-casts. Backported from 8.7", and "Fix [d63061a1ac]: PRIVATE != CONTROL in Unicode". check-in2024-08-25 13:22:030480bdc823Fix [d63061a1ac]: PRIVATE != CONTROL in Unicode check-in2024-03-03 21:30:395219e3ff14Bug [d63061a1ac]: "PRIVATE != CONTROL in Unicode". Leave out "Co" (private-use characters) from "string is control". check-in2024-01-15 10:46:33
This ticket is not important enough to rush into Tcl 8.6.14. I will start dicussion about it after 8.6.14 is released.
But ... if someone (Ashok ....) want to comment on it already, here is the place to do it.
I would agree that Co being classified as a control character does not make sense and should be removed. Additionally, I have mixed feelings about Cf characters also being classified as control characters. On one hand, I can see why if they are referenced as "format controls". On the other hand, I think most programmers' expectation is that the string is matched against the "traditional" Cc category members. I suppose we can punt that distinction to the future when general Unicode categorization of code points is added to Tcl.
> I would agree that Co being classified as a control character does not make sense and should be removed.
Thanks!
> I suppose we can punt that distinction to the future
I'm thinking about "string is Cc", "string is Cf" for this. But it would also
fit into the regexp syntax as \p{Cc} \p{Cf}. See [https://unicode.org/reports/tr18/].
Of course, this would be a hell of a job to implement completely. But starting
with "1.2.5 General Category Property", short form only, would be nice.
See: [3464428]. Looks like Ruby got it 'wrong' too ...
Fixed by [0480bdc823] (in 8.6.15 and 9.0.0): private-use characters (category Co) are no longer string is control. Cc and Cf are unchanged.