Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext

grammar::ci_compare

Return the case-insensitive comparison of s0 and s1.

Synopsis

Defined in header <boost/url/grammar/ci_string.hpp>

int
ci_compare(
    string_view s0,
    string_view s1);
Description

This returns the lexicographical comparison of two strings, ignoring case. The function is defined only for strings containing low-ASCII characters.

Example
assert( ci_compare( "boost", "Boost" ) == 0 );
Exception Safety

Throws nothing.

Return Value

0 if the strings are equal, -1 if s0 is less than s1, or 1 if s0 is greater than s1.

Parameters

Name

Description

s0

The first string

s1

The second string

See Also

ci_is_equal, ci_is_less.

Convenience header <boost/url/grammar.hpp>


PrevUpHomeNext