aboutsummaryrefslogtreecommitdiffstats
path: root/library
diff options
context:
space:
mode:
authorsamoylovboris <samoylovboris@yandex-team.ru>2022-02-10 16:49:56 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:49:56 +0300
commit1cefd0c80e17cf625858624e103f07eb08f7b1b2 (patch)
tree5d5cb817648f650d76cf1076100726fd9b8448e8 /library
parentb1a065aac47f61f2d8e3670ace40bd939af406f9 (diff)
downloadydb-1cefd0c80e17cf625858624e103f07eb08f7b1b2.tar.gz
Restoring authorship annotation for <samoylovboris@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'library')
-rw-r--r--library/cpp/containers/comptrie/search_iterator.h30
-rw-r--r--library/cpp/string_utils/base64/base64_ut.cpp36
-rw-r--r--library/cpp/string_utils/base64/ya.make4
3 files changed, 35 insertions, 35 deletions
diff --git a/library/cpp/containers/comptrie/search_iterator.h b/library/cpp/containers/comptrie/search_iterator.h
index 07dcc75921..247f7e5936 100644
--- a/library/cpp/containers/comptrie/search_iterator.h
+++ b/library/cpp/containers/comptrie/search_iterator.h
@@ -41,17 +41,17 @@ public:
{
}
- bool operator==(const TSearchIterator& other) const {
+ bool operator==(const TSearchIterator& other) const {
Y_ASSERT(Trie && other.Trie);
- return Trie == other.Trie &&
- DataPos == other.DataPos &&
- DataEnd == other.DataEnd &&
- ValuePos == other.ValuePos;
- }
- bool operator!=(const TSearchIterator& other) const {
- return !(*this == other);
- }
-
+ return Trie == other.Trie &&
+ DataPos == other.DataPos &&
+ DataEnd == other.DataEnd &&
+ ValuePos == other.ValuePos;
+ }
+ bool operator!=(const TSearchIterator& other) const {
+ return !(*this == other);
+ }
+
inline bool Advance(TSymbol label) {
Y_ASSERT(Trie);
if (DataPos == nullptr || DataPos >= DataEnd) {
@@ -132,9 +132,9 @@ bool TSearchIterator<TTrie>::HasValue() const {
template <class TTrie>
inline size_t TSearchIterator<TTrie>::GetHash() const {
Y_ASSERT(Trie);
- return MultiHash(
- static_cast<const void*>(Trie),
- static_cast<const void*>(DataPos),
- static_cast<const void*>(DataEnd),
- static_cast<const void*>(ValuePos));
+ return MultiHash(
+ static_cast<const void*>(Trie),
+ static_cast<const void*>(DataPos),
+ static_cast<const void*>(DataEnd),
+ static_cast<const void*>(ValuePos));
}
diff --git a/library/cpp/string_utils/base64/base64_ut.cpp b/library/cpp/string_utils/base64/base64_ut.cpp
index f7807ed9b5..bcc1e65879 100644
--- a/library/cpp/string_utils/base64/base64_ut.cpp
+++ b/library/cpp/string_utils/base64/base64_ut.cpp
@@ -267,24 +267,24 @@ Y_UNIT_TEST_SUITE(TBase64) {
UNIT_ASSERT_EXCEPTION(Base64StrictDecode("\1\1\1\2"), yexception);
}
- Y_UNIT_TEST(TestDecodeUneven) {
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven(""), "");
-
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("YWFh"), "aaa");
-
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("MTI="), "12");
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("MTI,"), "12");
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("MTI"), "12");
-
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("QQ=="), "A");
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("QQ,,"), "A");
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("QQ"), "A");
-
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("dnluZHg="), "vyndx");
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("dnluZHg,"), "vyndx");
- UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("dnluZHg"), "vyndx");
- }
-
+ Y_UNIT_TEST(TestDecodeUneven) {
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven(""), "");
+
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("YWFh"), "aaa");
+
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("MTI="), "12");
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("MTI,"), "12");
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("MTI"), "12");
+
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("QQ=="), "A");
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("QQ,,"), "A");
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("QQ"), "A");
+
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("dnluZHg="), "vyndx");
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("dnluZHg,"), "vyndx");
+ UNIT_ASSERT_VALUES_EQUAL(Base64DecodeUneven("dnluZHg"), "vyndx");
+ }
+
Y_UNIT_TEST(TestDecodeRandom) {
TString input;
constexpr size_t testSize = 240000;
diff --git a/library/cpp/string_utils/base64/ya.make b/library/cpp/string_utils/base64/ya.make
index 43899cf12b..f5258c446c 100644
--- a/library/cpp/string_utils/base64/ya.make
+++ b/library/cpp/string_utils/base64/ya.make
@@ -19,5 +19,5 @@ PEERDIR(
)
END()
-
-RECURSE_FOR_TESTS(ut)
+
+RECURSE_FOR_TESTS(ut)