Re: [Libclc-developers] Re: clc_ultostr doc change
Status: Planning
Brought to you by:
augestad
|
From: regis <re...@in...> - 2003-04-03 18:35:50
|
Hallvard B Furuseth wrote: > > regis writes: > >> so that is a vote for ultostr? > > > > Mhh Yes, > > except that the mangled names of all the string functions suck. > > Say it on c.l.c. With suggestions for other names. Then I'll probably > speak up against you, I think most names are fine:-) - Given a function name, It's hard to guess what it is supposed to do. - Given a wanted feature by the user, it is hard for him to guess what is the corresponding function. - Given a function already used by the user, it is hard to remember it for the next use. What clc_stpcpy is supposed to do? What does the 'p' stand? What clc_strtok_r is supposed to do? What does the '_r' mean? What clc_strlcpy is supposed to do? What does the 'l' mean? These are as many questions the new user asks at the first sight of these functions... Even for the standard strspn, I still don't know what spn stands for... Clearer (and unforgetable) names (with prefix clc_str_. Thinking of it, it would be better to reserve the long prefix clc_string_ for a possible future ADT for strings that expand/shrink automatically...) from_unsigned_long() to_uppercase() trim_left() trim_right() trim() or trim_both() split() normalize() reverse() compare_case_insensitive() etc. ( I would merge clc_stpcpy() and clc_strdup() to the single function clc_str_copy() with a possibly NULL extra output arg. ) |