From 271aa22aee4b5eb32c052b3f16afaa21cb91b810 Mon Sep 17 00:00:00 2001 From: Jason Volk Date: Fri, 19 Aug 2016 18:48:56 -0700 Subject: [PATCH] ircd: Add rfc1459::less overload on string pointers. --- include/ircd/rfc1459.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/include/ircd/rfc1459.h b/include/ircd/rfc1459.h index 66cccd519..754003773 100644 --- a/include/ircd/rfc1459.h +++ b/include/ircd/rfc1459.h @@ -72,6 +72,7 @@ using character::tolower; struct less { bool operator()(const std::string &a, const std::string &b) const; + bool operator()(const std::string *const &a, const std::string *const &b) const; }; inline bool is_print(const char &c) { return is(c, character::PRINT); } @@ -103,6 +104,14 @@ inline bool is_xdigit(const char &c) return is_digit(c) || ('a' <= c && c <= 'f') || ('A' <= c && c <= 'F'); } +inline bool +less::operator()(const std::string *const &a, + const std::string *const &b) +const +{ + return operator()(*a, *b); +} + inline bool less::operator()(const std::string &a, const std::string &b)