namespace {
// A functor for use with sort, leading to case insensitive sorting
-class compareNoCase: public binary_function<docstring, docstring, bool>
-{
-public:
- bool operator()(docstring const & s1, docstring const & s2) const {
- return compare_no_case(s1, s2) < 0;
- }
-};
+bool compareNoCase(const docstring & a, const docstring & b) {
+ return compare_no_case(a, b) < 0;
+}
} // namespace
vector<docstring> bibkeys;
for (auto const & bi : *this)
bibkeys.push_back(bi.first);
- sort(bibkeys.begin(), bibkeys.end(), compareNoCase());
+ sort(bibkeys.begin(), bibkeys.end(), &compareNoCase);
return bibkeys;
}
// FIXME We may want to collect these differently, in the first case,
// so that we might have them in order of appearance.
set<docstring> citekeys;
- Toc const toc = *buf.tocBackend().toc("citation");
+ Toc const & toc = *buf.tocBackend().toc("citation");
for (auto const & t : toc) {
if (t.str().empty())
continue;