Tcl Source Code

View Ticket
Login
Ticket UUID: 667ec8ff04ac1d444a2d787c5898a8734d31e0b3
Title: string compare equivalent of lsort -dictionary
Type: RFE Version: 8.6.9
Submitter: anonymous Created on: 2019-01-28 17:49:50
Subsystem: 18. Commands M-Z Assigned To: nobody
Priority: 5 Medium Severity: Important
Status: Open Last Modified: 2019-08-24 19:33:18
Resolution: None Closed By: nobody
    Closed on:
Description:
Hello,

it would be nice to get the command used by `lsort -dictionary` as a standalone proc, in order to compose more complicated comparison procs (for lsort -command) and to improve consistency.
I'd say that `string compare -dictionary` would be the best target for this.
User Comments: hadrien added on 2019-08-24 19:33:18:
I've read a bit the source code, and just plugging DictionaryCompare into TclStringCmp shouldn't be too hard (for someone who knows the codebase). This is really lacking, I think; forcing the user to use an unsightly hack around `lsort -dictionary`.