I'd like to sort a list of words according to their lexicographical order using expl3 code. My words are in a seq variable that I access in a stack-like manner (this is not relevant, though). I've learnt of the l3sort package, but it seems as though its functions worked only for numerical variables, because I've had no trouble with my code to sort a list of integers but I've ran into trouble with non-numerical data (meaning "plain" characters; no fancy macros, expandable stuff, or the likes).
Is there a ready-made way to do this in expl3/LaTeX3? On the negative, could somebody possibly provide some hints as to how to do this?
l3sortto sort non-numerical stuff with the help of\pdftex_strcmp:D. – cgnieder Sep 29 '13 at 09:56\pdftex_strcmp:Dfunction. But on theexpl3doc, you can read that "D [...] means: Do not use. This special case is used for TEX primitives. Programmers outside the kernel team should not use these functions!" On theinterface3doc there is but the shortest comment made on this function. Is it fine using it? What are the plans for thel3sortmodule in the short-term? Is it going to be bundled with the other "regular"expl3modules and thus not need to be loaded as an extra package? – Marcos Sep 29 '13 at 11:27! Missing number, treated as zeroby using the function\int_compare:nNnTF. It makes sense to me, since what the function is reading is actually an alphabetic character token, but I didn't found an alternative in the form of, let's say, str_compare:nNTF – Marcos Sep 29 '13 at 11:35