diff options
author | andr-savel <andr-savel@yandex-team.ru> | 2022-02-10 16:52:05 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:52:05 +0300 |
commit | 774bb09ec81216d51cb063ed9af52ddbc712ab20 (patch) | |
tree | ab7fbbf3253d4c0e2793218f09378908beb025fb | |
parent | 6dfdbbfba2b329639d9f07db609f9bdba66ab5e4 (diff) | |
download | ydb-774bb09ec81216d51cb063ed9af52ddbc712ab20.tar.gz |
Restoring authorship annotation for <andr-savel@yandex-team.ru>. Commit 2 of 2.
-rw-r--r-- | util/string/split.h | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/util/string/split.h b/util/string/split.h index 46530b14b5..bc46d9e64c 100644 --- a/util/string/split.h +++ b/util/string/split.h @@ -175,26 +175,26 @@ struct TCharDelimiter { }; template <class Iterator, class Condition> -struct TFuncDelimiter { -public: +struct TFuncDelimiter { +public: template <class... Args> TFuncDelimiter(Args&&... args) : Fn(std::forward<Args>(args)...) - { - } - + { + } + inline Iterator Find(Iterator& b, Iterator e) const noexcept { - if ((b = std::find_if(b, e, Fn)) != e) { - return b++; - } - - return b; - } - -private: + if ((b = std::find_if(b, e, Fn)) != e) { + return b++; + } + + return b; + } + +private: Condition Fn; -}; - +}; + template <class Char> struct TFindFirstOf { inline TFindFirstOf(Char* set) |