655 int cx_strcasecmp( |
655 int cx_strcasecmp( |
656 cxstring s1, |
656 cxstring s1, |
657 cxstring s2 |
657 cxstring s2 |
658 ); |
658 ); |
659 |
659 |
|
660 /** |
|
661 * Compares two strings. |
|
662 * |
|
663 * This function has a compatible signature for the use as a CxListComparator. |
|
664 * |
|
665 * @param s1 the first string |
|
666 * @param s2 the second string |
|
667 * @return negative if \p s1 is smaller than \p s2, positive if \p s1 is larger |
|
668 * than \p s2, zero if both strings equal |
|
669 */ |
|
670 __attribute__((__warn_unused_result__, __nonnull__)) |
|
671 int cx_strcmp_p( |
|
672 void const *s1, |
|
673 void const *s2 |
|
674 ); |
|
675 |
|
676 /** |
|
677 * Compares two strings ignoring case. |
|
678 * |
|
679 * This function has a compatible signature for the use as a CxListComparator. |
|
680 * |
|
681 * @param s1 the first string |
|
682 * @param s2 the second string |
|
683 * @return negative if \p s1 is smaller than \p s2, positive if \p s1 is larger |
|
684 * than \p s2, zero if both strings equal ignoring case |
|
685 */ |
|
686 __attribute__((__warn_unused_result__, __nonnull__)) |
|
687 int cx_strcasecmp_p( |
|
688 void const *s1, |
|
689 void const *s2 |
|
690 ); |
|
691 |
660 |
692 |
661 /** |
693 /** |
662 * Creates a duplicate of the specified string. |
694 * Creates a duplicate of the specified string. |
663 * |
695 * |
664 * The new string will contain a copy allocated by \p allocator. |
696 * The new string will contain a copy allocated by \p allocator. |