Artifacts Associated With Ticket 4ed788c618
Ticket change [b5acf31629] (rid 220402) by juliannoble2 on 2023-11-18 19:30:45:
- assignee initialized to: "nobody"
- closer initialized to: "nobody"
- cmimetype initialized to: "text/x-fossil-plain"
- comment initialized to:
regexp of \Ustuvwxyz is mentioned in the re_syntax docs below \uwxyz but behaves quite differently. \u can be used in braced expressions - whereas \U only seems to function properly in unbraced regexes where the \U entries become literal characters. It is unclear whether this is intentional or awaiting implementation in the core for regexp. The docs for \U mention 'reserved for a Unicode extension up to 21 bits'. The wording here could be clarified if that means it is not intended to function out of the box. Character ranges for braced \U regexes work in the range up to FFFF when the upper bound is expressed as \U0000FFFF or equivalent, but only up to FFFD if the upper bound is expressed as \U0010FFFF (I note that FFFE and FFFF are 'noncharacters' - but there are 32 other noncharacters in the BMP that aren't excluded. For best utility, I wouldn't expect any to be excluded in this context - but if the wording in docs refers to 'characters' rather than codepoints or whatever terminology is appropriate here, and it really is the intention to exclude noncharacters; then that's another point that may need explanation) 90b1rc % regexp -all -inline -indices {[\U00000080-\U0000FFFF]} X\UFFFEY {1 1} % regexp -all -inline -indices {[\U00000080-\U0010FFFF]} X\UFFFEY % Higher tests can be done with substituted regexes rather than braced ones - but that is much less convenient as regexes get more complex, and different enough from the \u behaviour that it may warrant more explicit documentation if it isn't intended to operate similarly without some sort of extra package. 90b1rc % regexp -all -inline -indices "\[\U00000080-\U0010FFFF\]" X\U1FFFFY {1 1} This isn't specific to the 90-b1 release candidate - but I notice that there are at least 3 different behaviours for certain \U regexes in recent years, which I guess isn't surprising given the complex work being done to support unicode in Tcl, but it does underscore a need to have the docs reflect intended behaviour. 8.6.12 %regexp -all -inline -indices {[\U80-\U0000FFFF]} X\U0001FFFFY {1 1} bawt 8.7a5 %regexp -all -inline -indices {[\U80-\U0000FFFF]} X\U0001FFFFY {1 1} {2 2} 8.7a6 (+) % regexp -all -inline -indices {[\U80-\U0000FFFF]} X\U0001FFFFY % - foundin initialized to: "9-0-b1-rc"
- is_private initialized to: "0"
- login: "juliannoble2"
- priority initialized to: "5 Medium"
- private_contact initialized to: "957fdfcd8744611e3fe1f4896c7538b1d9bf47b2"
- resolution initialized to: "None"
- severity initialized to: "Important"
- status initialized to: "Open"
- submitter initialized to: "juliannoble2"
- subsystem initialized to: "43. Regexp"
- title initialized to: "regexp \U not fully implemented - unclear in docs"
- type initialized to: "Bug"
Ticket change [359d7a3b8b] (rid 220488) by jan.nijtmans on 2023-11-20 22:26:15:
- assignee changed to: "jan.nijtmans"
- foundin changed to: "8.7"
- icomment: "Does [f31a38e35051b303|this] help?"
- login: "jan.nijtmans"
- mimetype: "text/x-fossil-wiki"
Ticket change [a84c9b7876] (rid 220489) by juliannoble2 on 2023-11-21 02:39:29:
- icomment: "It does indeed - thanks!"
- login: "juliannoble2"
- mimetype: "text/plain"
Ticket change [376c827602] (rid 220503) by jan.nijtmans on 2023-11-22 13:12:44:
- closedate changed to: "2460271.05051652"
- closer changed to: "jan.nijtmans"
- icomment:
Fixed [21eaa89b6be5c67a|here]. Many thanks for the report!
- login: "jan.nijtmans"
- mimetype: "text/x-fossil-wiki"
- resolution changed to: "Fixed"
- status changed to: "Closed"