diff options
author | stanly <stanly@yandex-team.ru> | 2022-02-10 16:46:49 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:46:49 +0300 |
commit | cde218e65dfef5ce03a48d641fd8f7913cf17b2d (patch) | |
tree | d3349caea4095825a55b5ba24fe758067b29ce6f /library/cpp/deprecated/kmp | |
parent | 9f813499b4ef585cb3c2bb93de93ef003daf4fc4 (diff) | |
download | ydb-cde218e65dfef5ce03a48d641fd8f7913cf17b2d.tar.gz |
Restoring authorship annotation for <stanly@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/deprecated/kmp')
-rw-r--r-- | library/cpp/deprecated/kmp/kmp.h | 2 | ||||
-rw-r--r-- | library/cpp/deprecated/kmp/kmp_ut.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/library/cpp/deprecated/kmp/kmp.h b/library/cpp/deprecated/kmp/kmp.h index a7f72eece6..48df76df18 100644 --- a/library/cpp/deprecated/kmp/kmp.h +++ b/library/cpp/deprecated/kmp/kmp.h @@ -86,7 +86,7 @@ public: ComputePrefixFunction(patternBegin, patternEnd, &pf); PrefixFunction.Reset(pf); } - + void Push(const T& symbol) { while ((State >= 0) && (Pattern[State] != symbol)) { Y_ASSERT(State <= (ssize_t) Pattern.size()); diff --git a/library/cpp/deprecated/kmp/kmp_ut.cpp b/library/cpp/deprecated/kmp/kmp_ut.cpp index c2eda83c57..3fa94c02d8 100644 --- a/library/cpp/deprecated/kmp/kmp_ut.cpp +++ b/library/cpp/deprecated/kmp/kmp_ut.cpp @@ -27,11 +27,11 @@ public: void Test() { TVector<int> ans = {0, 2}; UNIT_ASSERT_EQUAL(FindAll("a", "aba"), ans); - ans = {0}; + ans = {0}; UNIT_ASSERT_EQUAL(FindAll("aba", "aba"), ans); ans.clear(); UNIT_ASSERT_EQUAL(FindAll("abad", "aba"), ans); - ans = {0, 2}; + ans = {0, 2}; UNIT_ASSERT_EQUAL(FindAll("ab", "abab"), ans); } |