diff options
author | aosipenko <aosipenko@yandex-team.ru> | 2022-02-10 16:48:08 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:48:08 +0300 |
commit | 948fd24d47d4b3b7815aaef1686aea00ef3f4288 (patch) | |
tree | 8ad4c39c2a5f8b341bc02e3b0c5e8f26c40373cb /library/cpp/containers/comptrie | |
parent | d2eb4aae699fa2f6901bf32d22eec019c8f29838 (diff) | |
download | ydb-948fd24d47d4b3b7815aaef1686aea00ef3f4288.tar.gz |
Restoring authorship annotation for <aosipenko@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/containers/comptrie')
-rw-r--r-- | library/cpp/containers/comptrie/comptrie_builder.inl | 6 | ||||
-rw-r--r-- | library/cpp/containers/comptrie/comptrie_trie.h | 2 | ||||
-rw-r--r-- | library/cpp/containers/comptrie/comptrie_ut.cpp | 14 |
3 files changed, 11 insertions, 11 deletions
diff --git a/library/cpp/containers/comptrie/comptrie_builder.inl b/library/cpp/containers/comptrie/comptrie_builder.inl index f273fa6571..51a6f976d0 100644 --- a/library/cpp/containers/comptrie/comptrie_builder.inl +++ b/library/cpp/containers/comptrie/comptrie_builder.inl @@ -160,8 +160,8 @@ public: return 0; size_t median = (from + to) / 2; - size_t leftsize = (size_t)MeasureRange(builder, from, median); - size_t rightsize = (size_t)MeasureRange(builder, median + 1, to); + size_t leftsize = (size_t)MeasureRange(builder, from, median); + size_t rightsize = (size_t)MeasureRange(builder, median + 1, to); return builder->ArcMeasure(&(*this)[median], leftsize, rightsize); } @@ -825,7 +825,7 @@ void TCompactTrieBuilder<T, D, S>::TCompactTrieBuilderImpl::NodeLinkTo(TNode* th template <class T, class D, class S> size_t TCompactTrieBuilder<T, D, S>::TCompactTrieBuilderImpl::NodeMeasureSubtree(TNode* thiz) const { - return (size_t)thiz->Subtree()->Measure(this); + return (size_t)thiz->Subtree()->Measure(this); } template <class T, class D, class S> diff --git a/library/cpp/containers/comptrie/comptrie_trie.h b/library/cpp/containers/comptrie/comptrie_trie.h index 40ec1e52b3..63e3e50304 100644 --- a/library/cpp/containers/comptrie/comptrie_trie.h +++ b/library/cpp/containers/comptrie/comptrie_trie.h @@ -655,7 +655,7 @@ typename TCompactTrie<T, D, S>::TData TCompactTrie<T, D, S>::TConstIterator::Get template <class T, class D, class S> void TCompactTrie<T, D, S>::TConstIterator::GetValue(typename TCompactTrie<T, D, S>::TData& data) const { const char* ptr = GetValuePtr(); - if (ptr) { + if (ptr) { Packer.UnpackLeaf(ptr, data); } else { data = typename TCompactTrie<T, D, S>::TData(); diff --git a/library/cpp/containers/comptrie/comptrie_ut.cpp b/library/cpp/containers/comptrie/comptrie_ut.cpp index 74bee09b5d..969518fa1f 100644 --- a/library/cpp/containers/comptrie/comptrie_ut.cpp +++ b/library/cpp/containers/comptrie/comptrie_ut.cpp @@ -340,13 +340,13 @@ static bool LexicographicStep(TString& s) { template <class T> void TCompactTrieTest::CheckUpperBound(const char* data, size_t datalen) { TCompactTrie<T> trie(data, datalen); - typedef typename TCompactTrie<T>::TKey TKey; - typedef typename TCompactTrie<T>::TData TData; + typedef typename TCompactTrie<T>::TKey TKey; + typedef typename TCompactTrie<T>::TData TData; TString key; do { const TKey wideKey = MakeWideKey<T>(key); - typename TCompactTrie<T>::TConstIterator it = trie.UpperBound(wideKey); + typename TCompactTrie<T>::TConstIterator it = trie.UpperBound(wideKey); UNIT_ASSERT_C(it == trie.End() || it.GetKey() >= wideKey, "key=" + key); TData data; const bool found = trie.Find(wideKey, &data); @@ -454,7 +454,7 @@ void TCompactTrieTest::CheckIterator(const char* data, size_t datalen) { std::reverse(items.begin(), items.end()); typename TCompactTrie<T>::TConstIterator revIt = trie.End(); typename TCompactTrie<T>::TConstIterator const begin = trie.Begin(); - typename TCompactTrie<T>::TConstIterator emptyIt; + typename TCompactTrie<T>::TConstIterator emptyIt; size_t pos = 0; while (revIt != begin) { revIt--; @@ -465,11 +465,11 @@ void TCompactTrieTest::CheckIterator(const char* data, size_t datalen) { revIt = begin; UNIT_ASSERT(revIt == trie.Begin()); UNIT_ASSERT(!revIt.IsEmpty()); - UNIT_ASSERT(revIt != emptyIt); + UNIT_ASSERT(revIt != emptyIt); UNIT_ASSERT(revIt != trie.End()); ++revIt; // Call a method that uses Skipper. - revIt = emptyIt; - UNIT_ASSERT(revIt == emptyIt); + revIt = emptyIt; + UNIT_ASSERT(revIt == emptyIt); UNIT_ASSERT(revIt.IsEmpty()); UNIT_ASSERT(revIt != trie.End()); // Checking the move assignment operator. |