Lines Matching refs:compare

20 // basic_string_view::compare
21 // int compare(const basic_string_view& str) const;
22 // int compare(size_type pos1, size_type n1, const basic_string_view& str) const;
23 // int compare(size_type pos1, size_type n1, const basic_string_view& str,
25 // int compare(const charT* s) const;
26 // int compare(size_type pos1, size_type n1,
29 // NB compare should be thought of as a lexographical compare, ie how
84 // int compare(const basic_string_view& str) const;
85 test_value(str_0.compare(str_1), gt); //because r>m
86 test_value(str_1.compare(str_0), lt); //because m<r
88 test_value(str_2.compare(str_0), z);
90 test_value(str_2.compare(str_0), lt);
92 test_value(str_2.compare(str_0), gt);
94 // int compare(size_type pos1, size_type n1, const basic_string_view& str) const;
95 test_value(str_1.compare(0, 6, str_0), lt);
97 test_value(str_1.compare(0, 4, str_2), z);
98 test_value(str_1.compare(0, 5, str_2), gt);
100 // int compare(size_type pos1, size_type n1, const basic_string_view& str,
102 test_value(str_1.compare(0, 6, str_0, 0, 6), z);
103 test_value(str_1.compare(0, 7, str_0, 0, 7), lt);
104 test_value(str_0.compare(0, 7, str_1, 0, 7), gt);
106 // int compare(const charT* s) const;
107 test_value(str_0.compare("costa marbella"), gt);
108 test_value(str_1.compare("costa rica"), lt);
110 test_value(str_2.compare("costa rica"), z);
111 test_value(str_2.compare("cost"), gt);
112 test_value(str_2.compare("costa ricans"), lt);
114 // int compare(size_type pos, size_type n1, const charT* str,
116 test_value(str_1.compare(0, 6, "costa rica", 0, 6), z);
117 test_value(str_1.compare(0, 7, "costa rica", 0, 7), lt);
118 test_value(str_0.compare(0, 7, "costa marbella", 0, 7), gt);