aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/deprecated
diff options
context:
space:
mode:
authoryazevnul <yazevnul@yandex-team.ru>2022-02-10 16:46:46 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:46:46 +0300
commit8cbc307de0221f84c80c42dcbe07d40727537e2c (patch)
tree625d5a673015d1df891e051033e9fcde5c7be4e5 /library/cpp/deprecated
parent30d1ef3941e0dc835be7609de5ebee66958f215a (diff)
downloadydb-8cbc307de0221f84c80c42dcbe07d40727537e2c.tar.gz
Restoring authorship annotation for <yazevnul@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/deprecated')
-rw-r--r--library/cpp/deprecated/accessors/accessors_impl.h72
-rw-r--r--library/cpp/deprecated/enum_codegen/enum_codegen.h2
-rw-r--r--library/cpp/deprecated/enum_codegen/enum_codegen_ut.cpp6
-rw-r--r--library/cpp/deprecated/kmp/kmp.h8
-rw-r--r--library/cpp/deprecated/kmp/kmp_ut.cpp4
-rw-r--r--library/cpp/deprecated/mapped_file/mapped_file.cpp2
-rw-r--r--library/cpp/deprecated/mapped_file/mapped_file.h8
-rw-r--r--library/cpp/deprecated/mapped_file/ut/mapped_file_ut.cpp4
-rw-r--r--library/cpp/deprecated/split/delim_string_iter.h4
-rw-r--r--library/cpp/deprecated/split/delim_string_iter_ut.cpp26
-rw-r--r--library/cpp/deprecated/split/split_iterator.cpp4
-rw-r--r--library/cpp/deprecated/split/split_iterator.h4
12 files changed, 72 insertions, 72 deletions
diff --git a/library/cpp/deprecated/accessors/accessors_impl.h b/library/cpp/deprecated/accessors/accessors_impl.h
index 6b2b987351..66ba8d2d71 100644
--- a/library/cpp/deprecated/accessors/accessors_impl.h
+++ b/library/cpp/deprecated/accessors/accessors_impl.h
@@ -27,8 +27,8 @@ namespace NAccessors {
template <typename Tb>
struct TIndirectMemoryRegionBegin {
- Y_HAS_MEMBER(Begin);
- Y_HAS_MEMBER(begin);
+ Y_HAS_MEMBER(Begin);
+ Y_HAS_MEMBER(begin);
template <typename Tc>
struct TByBegin {
@@ -51,10 +51,10 @@ namespace NAccessors {
}
};
- using TGet = std::conditional_t<
+ using TGet = std::conditional_t<
TMemoryAccessorBase<Ta>::SimpleMemory,
TNoMemoryIndirectionBegin<Ta>,
- std::conditional_t<
+ std::conditional_t<
TMemoryAccessorBase<Ta>::ContinuousMemory,
TIndirectMemoryRegionBegin<Ta>,
typename TMemoryAccessorBase<Ta>::TBadAccessor>>;
@@ -77,8 +77,8 @@ namespace NAccessors {
template <typename Tb>
struct TIndirectMemoryRegionEnd {
- Y_HAS_MEMBER(End);
- Y_HAS_MEMBER(end);
+ Y_HAS_MEMBER(End);
+ Y_HAS_MEMBER(end);
template <typename Tc>
struct TByEnd {
@@ -101,10 +101,10 @@ namespace NAccessors {
}
};
- using TGet = std::conditional_t<
+ using TGet = std::conditional_t<
TMemoryAccessorBase<Ta>::SimpleMemory,
TNoMemoryIndirectionEnd<Ta>,
- std::conditional_t<
+ std::conditional_t<
TMemoryAccessorBase<Ta>::ContinuousMemory,
TIndirectMemoryRegionEnd<Ta>,
typename TMemoryAccessorBase<Ta>::TBadAccessor>>;
@@ -125,8 +125,8 @@ namespace NAccessors {
template <typename Tb>
struct TIndirectMemoryRegionClear {
- Y_HAS_MEMBER(Clear);
- Y_HAS_MEMBER(clear);
+ Y_HAS_MEMBER(Clear);
+ Y_HAS_MEMBER(clear);
template <typename Tc>
struct TByClear {
@@ -150,10 +150,10 @@ namespace NAccessors {
}
};
- using TDo = std::conditional_t<
+ using TDo = std::conditional_t<
THasClear<Tb>::value,
TByClear<Tb>,
- std::conditional_t<
+ std::conditional_t<
THasclear<Tb>::value,
TByclear<Tb>,
TByNone<Tb>>>;
@@ -163,7 +163,7 @@ namespace NAccessors {
}
};
- using TDo = std::conditional_t<TMemoryAccessorBase<Ta>::SimpleMemory, TNoMemoryIndirectionClear<Ta>, TIndirectMemoryRegionClear<Ta>>;
+ using TDo = std::conditional_t<TMemoryAccessorBase<Ta>::SimpleMemory, TNoMemoryIndirectionClear<Ta>, TIndirectMemoryRegionClear<Ta>>;
static void Do(Ta& b) {
TDo::Do(b);
@@ -172,8 +172,8 @@ namespace NAccessors {
template <typename Tb>
struct TReserve {
- Y_HAS_MEMBER(Reserve);
- Y_HAS_MEMBER(reserve);
+ Y_HAS_MEMBER(Reserve);
+ Y_HAS_MEMBER(reserve);
template <typename Tc>
struct TByReserve {
@@ -195,10 +195,10 @@ namespace NAccessors {
}
};
- using TDo = std::conditional_t<
+ using TDo = std::conditional_t<
THasReserve<Tb>::value,
TByReserve<Tb>,
- std::conditional_t<
+ std::conditional_t<
THasreserve<Tb>::value,
TByreserve<Tb>,
TByNone<Tb>>>;
@@ -210,8 +210,8 @@ namespace NAccessors {
template <typename Tb>
struct TResize {
- Y_HAS_MEMBER(Resize);
- Y_HAS_MEMBER(resize);
+ Y_HAS_MEMBER(Resize);
+ Y_HAS_MEMBER(resize);
template <typename Tc>
struct TByResize {
@@ -236,9 +236,9 @@ namespace NAccessors {
template <typename Tb>
struct TAppend {
- Y_HAS_MEMBER(Append);
- Y_HAS_MEMBER(append);
- Y_HAS_MEMBER(push_back);
+ Y_HAS_MEMBER(Append);
+ Y_HAS_MEMBER(append);
+ Y_HAS_MEMBER(push_back);
template <typename Tc>
struct TByAppend {
@@ -267,10 +267,10 @@ namespace NAccessors {
}
};
- using TDo = std::conditional_t<
+ using TDo = std::conditional_t<
THasAppend<Tb>::value,
TByAppend<Tb>,
- std::conditional_t<
+ std::conditional_t<
THasappend<Tb>::value,
TByappend<Tb>,
TBypush_back<Tb>>>;
@@ -284,9 +284,9 @@ namespace NAccessors {
template <typename Tb>
struct TAppendRegion {
- Y_HAS_MEMBER(Append);
- Y_HAS_MEMBER(append);
- Y_HAS_MEMBER(insert);
+ Y_HAS_MEMBER(Append);
+ Y_HAS_MEMBER(append);
+ Y_HAS_MEMBER(insert);
template <typename Tc>
struct TByAppend {
@@ -325,13 +325,13 @@ namespace NAccessors {
}
};
- using TDo = std::conditional_t<
+ using TDo = std::conditional_t<
THasAppend<Tb>::value,
TByAppend<Tb>,
- std::conditional_t<
+ std::conditional_t<
THasappend<Tb>::value,
TByappend<Tb>,
- std::conditional_t<
+ std::conditional_t<
THasinsert<Tb>::value,
TByinsert<Tb>,
TByNone<Tb>>>>;
@@ -362,8 +362,8 @@ namespace NAccessors {
template <typename Tb>
struct TIndirectMemoryRegionAssign {
- Y_HAS_MEMBER(Assign);
- Y_HAS_MEMBER(assign);
+ Y_HAS_MEMBER(Assign);
+ Y_HAS_MEMBER(assign);
template <typename Tc>
struct TByAssign {
@@ -394,13 +394,13 @@ namespace NAccessors {
}
};
- using TDo = std::conditional_t<
+ using TDo = std::conditional_t<
THasAssign<Tb>::value,
TByAssign<Tb>,
- std::conditional_t<
+ std::conditional_t<
THasassign<Tb>::value,
TByassign<Tb>,
- std::conditional_t<
+ std::conditional_t<
TMemoryTraits<Tb>::OwnsMemory,
TByClearAppend<Tb>,
TByConstruction<Tb>>>>;
@@ -410,7 +410,7 @@ namespace NAccessors {
}
};
- using TDo = std::conditional_t<TMemoryAccessorBase<Ta>::SimpleMemory, TNoMemoryIndirectionAssign<Ta>, TIndirectMemoryRegionAssign<Ta>>;
+ using TDo = std::conditional_t<TMemoryAccessorBase<Ta>::SimpleMemory, TNoMemoryIndirectionAssign<Ta>, TIndirectMemoryRegionAssign<Ta>>;
static void Do(Ta& b, const TElementType* beg, const TElementType* end) {
TDo::Do(b, beg, end);
diff --git a/library/cpp/deprecated/enum_codegen/enum_codegen.h b/library/cpp/deprecated/enum_codegen/enum_codegen.h
index dfb04ecac2..26addd9495 100644
--- a/library/cpp/deprecated/enum_codegen/enum_codegen.h
+++ b/library/cpp/deprecated/enum_codegen/enum_codegen.h
@@ -22,7 +22,7 @@
} \
} \
\
- static inline IOutputStream& operator<<(IOutputStream& os, type value) { \
+ static inline IOutputStream& operator<<(IOutputStream& os, type value) { \
switch (value) { \
MAP(ENUM_LTLT_IMPL_ITEM) \
default: \
diff --git a/library/cpp/deprecated/enum_codegen/enum_codegen_ut.cpp b/library/cpp/deprecated/enum_codegen/enum_codegen_ut.cpp
index f8f1c9b6df..06ddb8107d 100644
--- a/library/cpp/deprecated/enum_codegen/enum_codegen_ut.cpp
+++ b/library/cpp/deprecated/enum_codegen/enum_codegen_ut.cpp
@@ -26,12 +26,12 @@ enum EMultiplier {
ENUM_TO_STRING(EMultiplier, MULTIPLIER_MAP)
-Y_UNIT_TEST_SUITE(EnumCodegen) {
- Y_UNIT_TEST(GenWithValue) {
+Y_UNIT_TEST_SUITE(EnumCodegen) {
+ Y_UNIT_TEST(GenWithValue) {
UNIT_ASSERT_VALUES_EQUAL(6, MB);
}
- Y_UNIT_TEST(ToCString) {
+ Y_UNIT_TEST(ToCString) {
UNIT_ASSERT_VALUES_EQUAL("RED", ToCString(RED));
UNIT_ASSERT_VALUES_EQUAL("BLUE", ToCString(BLUE));
UNIT_ASSERT_VALUES_EQUAL("GREEN", (TStringBuilder() << GREEN));
diff --git a/library/cpp/deprecated/kmp/kmp.h b/library/cpp/deprecated/kmp/kmp.h
index a7f72eece6..ce7783e2fc 100644
--- a/library/cpp/deprecated/kmp/kmp.h
+++ b/library/cpp/deprecated/kmp/kmp.h
@@ -18,9 +18,9 @@ void ComputePrefixFunction(const T* begin, const T* end, ssize_t** result) {
j = resultHolder[j];
++i;
++j;
- Y_ASSERT(i >= 0);
- Y_ASSERT(j >= 0);
- Y_ASSERT(j < len);
+ Y_ASSERT(i >= 0);
+ Y_ASSERT(j >= 0);
+ Y_ASSERT(j < len);
if ((i < len) && (begin[i] == begin[j]))
resultHolder[i] = resultHolder[j];
else
@@ -41,7 +41,7 @@ public:
TKMPMatcher(const TString& pattern);
bool SubStr(const char* begin, const char* end, const char*& result) const {
- Y_ASSERT(begin <= end);
+ Y_ASSERT(begin <= end);
ssize_t m = Pattern.size();
ssize_t n = end - begin;
ssize_t i, j;
diff --git a/library/cpp/deprecated/kmp/kmp_ut.cpp b/library/cpp/deprecated/kmp/kmp_ut.cpp
index c2eda83c57..dc60429596 100644
--- a/library/cpp/deprecated/kmp/kmp_ut.cpp
+++ b/library/cpp/deprecated/kmp/kmp_ut.cpp
@@ -71,8 +71,8 @@ public:
int data[] = {1, 2, 3, 5, 2, 2, 3, 2, 4, 3, 2};
TKMPSimpleCallback callback(pattern, pattern + 2);
TKMPStreamMatcher<int> matcher(pattern, pattern + 2, &callback);
- for (auto& i : data)
- matcher.Push(i);
+ for (auto& i : data)
+ matcher.Push(i);
UNIT_ASSERT_EQUAL(2, callback.GetCount());
}
};
diff --git a/library/cpp/deprecated/mapped_file/mapped_file.cpp b/library/cpp/deprecated/mapped_file/mapped_file.cpp
index b0e4511299..90752ea263 100644
--- a/library/cpp/deprecated/mapped_file/mapped_file.cpp
+++ b/library/cpp/deprecated/mapped_file/mapped_file.cpp
@@ -15,7 +15,7 @@ TMappedFile::TMappedFile(TFileMap* map, const char* dbgName) {
}
TMappedFile::TMappedFile(const TFile& file, TFileMap::EOpenMode om, const char* dbgName)
- : Map_(nullptr)
+ : Map_(nullptr)
{
init(file, om, dbgName);
}
diff --git a/library/cpp/deprecated/mapped_file/mapped_file.h b/library/cpp/deprecated/mapped_file/mapped_file.h
index 45859ed65a..3245f74249 100644
--- a/library/cpp/deprecated/mapped_file/mapped_file.h
+++ b/library/cpp/deprecated/mapped_file/mapped_file.h
@@ -23,7 +23,7 @@ private:
public:
TMappedFile() {
- Map_ = nullptr;
+ Map_ = nullptr;
}
~TMappedFile() {
@@ -31,7 +31,7 @@ public:
}
explicit TMappedFile(const TString& name) {
- Map_ = nullptr;
+ Map_ = nullptr;
init(name, TFileMap::oRdOnly);
}
@@ -51,7 +51,7 @@ public:
if (Map_) {
Map_->Unmap();
delete Map_;
- Map_ = nullptr;
+ Map_ = nullptr;
}
}
@@ -60,7 +60,7 @@ public:
}
void* getData(size_t pos = 0) const {
- Y_ASSERT(!Map_ || (pos <= getSize()));
+ Y_ASSERT(!Map_ || (pos <= getSize()));
return (Map_ ? (void*)((unsigned char*)Map_->Ptr() + pos) : nullptr);
}
diff --git a/library/cpp/deprecated/mapped_file/ut/mapped_file_ut.cpp b/library/cpp/deprecated/mapped_file/ut/mapped_file_ut.cpp
index afbd5b3358..6eaa063562 100644
--- a/library/cpp/deprecated/mapped_file/ut/mapped_file_ut.cpp
+++ b/library/cpp/deprecated/mapped_file/ut/mapped_file_ut.cpp
@@ -3,9 +3,9 @@
#include <util/system/fs.h>
-Y_UNIT_TEST_SUITE(TMappedFileTest) {
+Y_UNIT_TEST_SUITE(TMappedFileTest) {
static const char* FileName_("./mappped_file");
- Y_UNIT_TEST(TestFileMapEmpty) {
+ Y_UNIT_TEST(TestFileMapEmpty) {
TFile file(FileName_, CreateAlways | WrOnly);
file.Close();
diff --git a/library/cpp/deprecated/split/delim_string_iter.h b/library/cpp/deprecated/split/delim_string_iter.h
index 8e4ca171a0..af0d86872d 100644
--- a/library/cpp/deprecated/split/delim_string_iter.h
+++ b/library/cpp/deprecated/split/delim_string_iter.h
@@ -173,8 +173,8 @@ public:
TKeyValueDelimStringIter(const TStringBuf str, const TStringBuf delim);
bool Valid() const;
TKeyValueDelimStringIter& operator++();
- const TStringBuf& Key() const;
- const TStringBuf& Value() const;
+ const TStringBuf& Key() const;
+ const TStringBuf& Value() const;
private:
TDelimStringIter DelimIter;
diff --git a/library/cpp/deprecated/split/delim_string_iter_ut.cpp b/library/cpp/deprecated/split/delim_string_iter_ut.cpp
index 18a8b2a160..644d72e56f 100644
--- a/library/cpp/deprecated/split/delim_string_iter_ut.cpp
+++ b/library/cpp/deprecated/split/delim_string_iter_ut.cpp
@@ -16,22 +16,22 @@ static void AssertStringSplit(const TString& str, const TString& delim, const TV
UNIT_ASSERT(!it.Valid());
};
-Y_UNIT_TEST_SUITE(TDelimStrokaIterTestSuite) {
- Y_UNIT_TEST(SingleCharacterAsDelimiter) {
+Y_UNIT_TEST_SUITE(TDelimStrokaIterTestSuite) {
+ Y_UNIT_TEST(SingleCharacterAsDelimiter) {
AssertStringSplit(
"Hello words!", " ", {"Hello", "words!"});
}
- Y_UNIT_TEST(MultipleCharactersAsDelimiter) {
+ Y_UNIT_TEST(MultipleCharactersAsDelimiter) {
AssertStringSplit(
"0, 1, 1, 2, 3, 5, 8, 13, 21, 34", "1, ", {"0, ", "", "2, 3, 5, 8, 13, 2", "34"});
}
- Y_UNIT_TEST(NoDelimitersPresent) {
+ Y_UNIT_TEST(NoDelimitersPresent) {
AssertStringSplit("This string could be yours", "\t", {"This string could be yours"});
}
- Y_UNIT_TEST(Cdr) {
+ Y_UNIT_TEST(Cdr) {
TDelimStringIter it("a\tc\t", "\t");
UNIT_ASSERT_STRINGS_EQUAL(*it, "a");
UNIT_ASSERT_STRINGS_EQUAL(it.Cdr(), "c\t");
@@ -39,7 +39,7 @@ Y_UNIT_TEST_SUITE(TDelimStrokaIterTestSuite) {
UNIT_ASSERT_STRINGS_EQUAL(it.Cdr(), "");
}
- Y_UNIT_TEST(ForIter) {
+ Y_UNIT_TEST(ForIter) {
TVector<TStringBuf> expected = {"1", "", "3@4", ""};
TVector<TStringBuf> got;
@@ -52,8 +52,8 @@ Y_UNIT_TEST_SUITE(TDelimStrokaIterTestSuite) {
}
static void AssertKeyValueStringSplit(
- const TStringBuf str,
- const TStringBuf delim,
+ const TStringBuf str,
+ const TStringBuf delim,
const TVector<std::pair<TStringBuf, TStringBuf>>& expected) {
TKeyValueDelimStringIter it(str, delim);
@@ -66,28 +66,28 @@ static void AssertKeyValueStringSplit(
UNIT_ASSERT(!it.Valid());
}
-Y_UNIT_TEST_SUITE(TKeyValueDelimStringIterTestSuite) {
- Y_UNIT_TEST(SingleCharacterAsDelimiter) {
+Y_UNIT_TEST_SUITE(TKeyValueDelimStringIterTestSuite) {
+ Y_UNIT_TEST(SingleCharacterAsDelimiter) {
AssertKeyValueStringSplit(
"abc=123,cde=qwer", ",",
{{"abc", "123"},
{"cde", "qwer"}});
}
- Y_UNIT_TEST(MultipleCharactersAsDelimiter) {
+ Y_UNIT_TEST(MultipleCharactersAsDelimiter) {
AssertKeyValueStringSplit(
"abc=xyz@@qwerty=zxcv", "@@",
{{"abc", "xyz"},
{"qwerty", "zxcv"}});
}
- Y_UNIT_TEST(NoDelimiters) {
+ Y_UNIT_TEST(NoDelimiters) {
AssertKeyValueStringSplit(
"abc=zz", ",",
{{"abc", "zz"}});
}
- Y_UNIT_TEST(EmptyElements) {
+ Y_UNIT_TEST(EmptyElements) {
AssertKeyValueStringSplit(
"@@abc=zxy@@@@qwerty=y@@", "@@",
{{"", ""},
diff --git a/library/cpp/deprecated/split/split_iterator.cpp b/library/cpp/deprecated/split/split_iterator.cpp
index 32262d25bd..ca46799dd6 100644
--- a/library/cpp/deprecated/split/split_iterator.cpp
+++ b/library/cpp/deprecated/split/split_iterator.cpp
@@ -155,7 +155,7 @@ TDelimitersSplitWithoutTags::TDelimitersSplitWithoutTags(const TString& s, const
}
size_t TDelimitersSplitWithoutTags::SkipTag(size_t pos) const {
- Y_ASSERT('<' == Str[pos]);
+ Y_ASSERT('<' == Str[pos]);
while ((pos < Len) && ('>' != Str[pos]))
++pos;
return pos + 1;
@@ -236,7 +236,7 @@ TCharSplitWithoutTags::TCharSplitWithoutTags(const TString& s)
}
size_t TCharSplitWithoutTags::SkipTag(size_t pos) const {
- Y_ASSERT('<' == Str[pos]);
+ Y_ASSERT('<' == Str[pos]);
while ((pos < Len) && ('>' != Str[pos]))
++pos;
return pos + 1;
diff --git a/library/cpp/deprecated/split/split_iterator.h b/library/cpp/deprecated/split/split_iterator.h
index 0eacc29228..b1a39d81be 100644
--- a/library/cpp/deprecated/split/split_iterator.h
+++ b/library/cpp/deprecated/split/split_iterator.h
@@ -25,7 +25,7 @@ struct TNumPair {
: Begin(begin)
, End(end)
{
- Y_ASSERT(begin <= end);
+ Y_ASSERT(begin <= end);
}
T Length() const {
@@ -264,7 +264,7 @@ public:
TSplitIterator(const TSplit& split)
: Split(split)
, Pos(Split.Begin())
- , CurrentStroka(nullptr)
+ , CurrentStroka(nullptr)
{
}