Artifacts Associated With Ticket 769895ffffffffffffffffffffffffffffffffff
Ticket change [e8d9931cd9] (rid 104714) by dgp on 2003-07-11 21:43:11:
- assignee initialized to: "nijtmans"
- cmimetype initialized to: "text/plain"
- comment initialized to:
Docs for Tcl_UtfPrev(src, start) say: Given src, a pointer to some location in a UTF-8 string, Tcl_UtfPrev returns a pointer to the previous UTF-8 charac- ter in the string. This function will not back up to a position before start, the start of the UTF-8 string. If src was already at start, the return value will be start. The source code comments just before Tcl_UtfPrev also say: * Given a pointer to some current location in a UTF-8 string, * move backwards one character. This works correctly when the * pointer is in the middle of a UTF-8 character. So the claim is that the src argument can be a pointer to a trailing byte of a multi-byte character. However, that does not appear to be what the routine really does. Instead, the routine starts a search at one byte before the src argument, and searches backward for the beginning of a UTF8 character byte-sequence and returns that. So, for example, CONST char *word="ab\303\521"; Tcl_UtfPrev(word+3,word); will return word+2 (pointer to the é character in UTF8) and not word+1 (pointer to the 'b') as I would expect. One feature of the current Tcl_UtfPrev() implementation is that it is currently safe to pass in a 'src' argument, that points one byte past the end of the allocated buffer, which can be useful, even though it seems counter to the documentation. Either implementation or documentation ought to be changed to bring them into agreement. - foundin initialized to: "obsolete: 8.4.3"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "dgp"
- subsystem initialized to: "44. UTF-8 Strings"
- title initialized to: "Tcl_UtfPrev not as documented ?"
- type initialized to: "Bug"
Ticket change [051adf18fd] (rid 88998) by dgp on 2003-07-12 04:43:34:
- assignee changed to: "hobbs"
Ticket change [7c11e33d0f] (rid 97012) by hobbs on 2003-07-17 07:24:36:
- icomment:
Logged In: YES user_id=72656 I think docs should be changed. IIRC there are uses of this that only Tk makes use of that have to be checked against.
- login: "hobbs"
- mimetype: "text/plain"
- username: "hobbs"
- icomment:
Ticket change [a6b55502d2] (rid 98651) by dgp on 2003-07-17 10:08:13:
- assignee changed to: "dgp"
- icomment:
Logged In: YES user_id=80530 Yes, that is the consensus. Clarify the docs to accurately describe existing behavior. claiming...
- login: "dgp"
- mimetype: "text/plain"
- priority changed to: "9 Immediate"
- username: "dgp"
Ticket change [9ee9d78718] (rid 96558) by dgp on 2003-07-18 12:59:07:
- priority changed to: "8"
Ticket change [a44dcae1ac] (rid 110188) by dkf on 2003-07-19 05:10:46:
- assignee changed to: "dkf"
- priority changed to: "9 Immediate"
Ticket change [527a6bc074] (rid 126324) by dkf on 2003-07-19 05:18:36:
- closedate changed to: "2003-07-18T22:18:36"
- closer changed to: "dkf"
- icomment:
Logged In: YES user_id=79902 Minor tightening of Tcl_UtfNext() done at same time.
- login: "dkf"
- mimetype: "text/plain"
- resolution changed to: "Fixed"
- status changed to: "Closed"
- username: "dkf"