Open
Description
I went through the stdlib_string_type module and I want to recommend some changes. Correct me if I am wrong at any point.
- The lgt, llt, lge and lle work very similarly to the operators >, <, >=, <= respectively according to me there is not much need for all these functions.
- Instead of all these we can have a general function compare(str1,str2) this function will return an integer value:
- 1 if str1 is lexicographically greater than str2,
- 0 if str1 is lexicographically equal to str2,
- -1 if str1 is lexicographically smaller than str2.
- We can also include a function like compare_ignore_case(str1,str2) this function is similar to compare but is not case sensitive. (can improve nomenclature of the functions)