diff options
author | thegeorg <thegeorg@yandex-team.ru> | 2022-02-10 16:45:12 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:45:12 +0300 |
commit | 49116032d905455a7b1c994e4a696afc885c1e71 (patch) | |
tree | be835aa92c6248212e705f25388ebafcf84bc7a1 /util/generic/xrange.h | |
parent | 4e839db24a3bbc9f1c610c43d6faaaa99824dcca (diff) | |
download | ydb-49116032d905455a7b1c994e4a696afc885c1e71.tar.gz |
Restoring authorship annotation for <thegeorg@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'util/generic/xrange.h')
-rw-r--r-- | util/generic/xrange.h | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/util/generic/xrange.h b/util/generic/xrange.h index 57c6f89a9c..5fc8c82912 100644 --- a/util/generic/xrange.h +++ b/util/generic/xrange.h @@ -60,11 +60,11 @@ namespace NPrivate { return *this; } - TIterator& operator--() noexcept { - --Value; - return *this; - } - + TIterator& operator--() noexcept { + --Value; + return *this; + } + constexpr TDiff operator-(const TIterator& b) const noexcept { return Value - b.Value; } @@ -169,11 +169,11 @@ namespace NPrivate { return *this; } - TIterator& operator--() noexcept { - Value_ -= Parent_->Step_; - return *this; - } - + TIterator& operator--() noexcept { + Value_ -= Parent_->Step_; + return *this; + } + constexpr TDiff operator-(const TIterator& b) const noexcept { return (Value_ - b.Value_) / Parent_->Step_; } |