Merge pull request #3125 from amosbird/self

Simply Self.
This commit is contained in:
alexey-milovidov 2018-09-13 21:56:10 +03:00 committed by GitHub
commit 3a4582baef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 16 additions and 16 deletions

View File

@ -24,7 +24,7 @@ template <typename T>
struct SingleValueDataFixed struct SingleValueDataFixed
{ {
private: private:
using Self = SingleValueDataFixed<T>; using Self = SingleValueDataFixed;
bool has_value = false; /// We need to remember if at least one value has been passed. This is necessary for AggregateFunctionIf. bool has_value = false; /// We need to remember if at least one value has been passed. This is necessary for AggregateFunctionIf.
T value; T value;
@ -563,7 +563,7 @@ public:
template <typename Data> template <typename Data>
struct AggregateFunctionMinData : Data struct AggregateFunctionMinData : Data
{ {
using Self = AggregateFunctionMinData<Data>; using Self = AggregateFunctionMinData;
bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) { return this->changeIfLess(column, row_num, arena); } bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) { return this->changeIfLess(column, row_num, arena); }
bool changeIfBetter(const Self & to, Arena * arena) { return this->changeIfLess(to, arena); } bool changeIfBetter(const Self & to, Arena * arena) { return this->changeIfLess(to, arena); }
@ -574,7 +574,7 @@ struct AggregateFunctionMinData : Data
template <typename Data> template <typename Data>
struct AggregateFunctionMaxData : Data struct AggregateFunctionMaxData : Data
{ {
using Self = AggregateFunctionMaxData<Data>; using Self = AggregateFunctionMaxData;
bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) { return this->changeIfGreater(column, row_num, arena); } bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) { return this->changeIfGreater(column, row_num, arena); }
bool changeIfBetter(const Self & to, Arena * arena) { return this->changeIfGreater(to, arena); } bool changeIfBetter(const Self & to, Arena * arena) { return this->changeIfGreater(to, arena); }
@ -585,7 +585,7 @@ struct AggregateFunctionMaxData : Data
template <typename Data> template <typename Data>
struct AggregateFunctionAnyData : Data struct AggregateFunctionAnyData : Data
{ {
using Self = AggregateFunctionAnyData<Data>; using Self = AggregateFunctionAnyData;
bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) { return this->changeFirstTime(column, row_num, arena); } bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) { return this->changeFirstTime(column, row_num, arena); }
bool changeIfBetter(const Self & to, Arena * arena) { return this->changeFirstTime(to, arena); } bool changeIfBetter(const Self & to, Arena * arena) { return this->changeFirstTime(to, arena); }
@ -596,7 +596,7 @@ struct AggregateFunctionAnyData : Data
template <typename Data> template <typename Data>
struct AggregateFunctionAnyLastData : Data struct AggregateFunctionAnyLastData : Data
{ {
using Self = AggregateFunctionAnyLastData<Data>; using Self = AggregateFunctionAnyLastData;
bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) { return this->changeEveryTime(column, row_num, arena); } bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) { return this->changeEveryTime(column, row_num, arena); }
bool changeIfBetter(const Self & to, Arena * arena) { return this->changeEveryTime(to, arena); } bool changeIfBetter(const Self & to, Arena * arena) { return this->changeEveryTime(to, arena); }
@ -615,7 +615,7 @@ struct AggregateFunctionAnyHeavyData : Data
{ {
size_t counter = 0; size_t counter = 0;
using Self = AggregateFunctionAnyHeavyData<Data>; using Self = AggregateFunctionAnyHeavyData;
bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena) bool changeIfBetter(const IColumn & column, size_t row_num, Arena * arena)
{ {

View File

@ -58,7 +58,7 @@ class ColumnDecimal final : public COWPtrHelper<IColumn, ColumnDecimal<T>>
static_assert(IsDecimalNumber<T>); static_assert(IsDecimalNumber<T>);
private: private:
using Self = ColumnDecimal<T>; using Self = ColumnDecimal;
friend class COWPtrHelper<IColumn, Self>; friend class COWPtrHelper<IColumn, Self>;
public: public:

View File

@ -125,7 +125,7 @@ class ColumnVector final : public COWPtrHelper<IColumn, ColumnVector<T>>
static_assert(!IsDecimalNumber<T>); static_assert(!IsDecimalNumber<T>);
private: private:
using Self = ColumnVector<T>; using Self = ColumnVector;
friend class COWPtrHelper<IColumn, Self>; friend class COWPtrHelper<IColumn, Self>;
struct less; struct less;

View File

@ -27,7 +27,7 @@ template
class HashSetTable : public HashTable<Key, TCell, Hash, Grower, Allocator> class HashSetTable : public HashTable<Key, TCell, Hash, Grower, Allocator>
{ {
public: public:
using Self = HashSetTable<Key, TCell, Hash, Grower, Allocator>; using Self = HashSetTable;
using Cell = TCell; using Cell = TCell;
void merge(const Self & rhs) void merge(const Self & rhs)

View File

@ -269,7 +269,7 @@ protected:
friend class TwoLevelHashTable; friend class TwoLevelHashTable;
using HashValue = size_t; using HashValue = size_t;
using Self = HashTable<Key, Cell, Hash, Grower, Allocator>; using Self = HashTable;
using cell_type = Cell; using cell_type = Cell;
size_t m_size = 0; /// Amount of elements size_t m_size = 0; /// Amount of elements

View File

@ -29,7 +29,7 @@ protected:
friend class iterator; friend class iterator;
friend class Reader; friend class Reader;
using Self = SmallTable<Key, Cell, capacity>; using Self = SmallTable;
using cell_type = Cell; using cell_type = Cell;
size_t m_size = 0; /// Amount of elements. size_t m_size = 0; /// Amount of elements.

View File

@ -43,7 +43,7 @@ protected:
friend class iterator; friend class iterator;
using HashValue = size_t; using HashValue = size_t;
using Self = TwoLevelHashTable<Key, Cell, Hash, Grower, Allocator, ImplTable>; using Self = TwoLevelHashTable;
public: public:
using Impl = ImplTable; using Impl = ImplTable;

View File

@ -83,7 +83,7 @@ private:
} }
public: public:
using Self = SpaceSaving<TKey, Hash, Grower, Allocator>; using Self = SpaceSaving;
struct Counter struct Counter
{ {

View File

@ -69,7 +69,7 @@ public:
using ExceptionCallback = std::function<void()>; using ExceptionCallback = std::function<void()>;
private: private:
using Self = UnionBlockInputStream<mode>; using Self = UnionBlockInputStream;
public: public:
UnionBlockInputStream(BlockInputStreams inputs, BlockInputStreamPtr additional_input_at_end, size_t max_threads, UnionBlockInputStream(BlockInputStreams inputs, BlockInputStreamPtr additional_input_at_end, size_t max_threads,

View File

@ -76,7 +76,7 @@ class SystemLog : private boost::noncopyable
{ {
public: public:
using Self = SystemLog<SystemLog>; using Self = SystemLog;
/** Parameter: table name where to write log. /** Parameter: table name where to write log.
* If table is not exists, then it get created with specified engine. * If table is not exists, then it get created with specified engine.

View File

@ -12,7 +12,7 @@ struct StrongTypedef
, boost::totally_ordered2< StrongTypedef<T, Tag>, T> > , boost::totally_ordered2< StrongTypedef<T, Tag>, T> >
{ {
private: private:
using Self = StrongTypedef<T, Tag>; using Self = StrongTypedef;
T t; T t;
public: public: