Human unreadable documentation - the ugly seam between simple D and complex D

Tobias Pankrath via Digitalmars-d digitalmars-d at puremagic.com
Fri Mar 27 09:55:33 PDT 2015


> Regarding the scscscshghshshshhswarzThing, here we discuss the 
> readability and accessibility of the documentation, not the 
> power of the library. Every other language will use a variation 
> of  "sortBy" instead of the scscshwcwscThing. I'm happy that D 
> has in the default lib functions like levenshteinDistance, but 
> this will not attract the average or "just starting to learn" 
> developer. On the contrary, sorting correctly some names is a 
> more common task than calculating the Levenshtein distance, but 
> there is no function for it in phobos.

You may have a point that schwartzSort has a bad name (I 
disagree), but putting another algorithm does not make the 
documentation worse per se. Dunno, what problem you have with the 
levenshteinDistance.

> On the contrary, sorting correctly some names is a more common 
> task than calculating the Levenshtein distance, but there is no 
> function for it in phobos.

What do you mean by correct? http://unicode.org/reports/tr10/? 
"We even have something obscure like levenshteinDistance but no 
implementation for the unicode collation algorithm, which all 
newcomers are looking for!" is a) a questionable comparison 
between a relative simple algorithm and a monster and b) wrong, 
because 99% of programmers don't even know about the algorithm 
itself, thus they aren't looking for it.

BTW. python's startwith does the Köln example wrong. Kö and 
Ko\u0308 dont match.


More information about the Digitalmars-d mailing list