mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
clang-tidy: use = default
Found with modernize-use-equals-default Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
parent
4aaaa8dcc8
commit
3cafb5257e
9 changed files with 7 additions and 50 deletions
15
src/CLI2.cpp
15
src/CLI2.cpp
|
@ -49,21 +49,10 @@ A2::A2 (const std::string& raw, Lexer::Type lextype)
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
A2::A2 (const A2& other)
|
A2::A2 (const A2& other) = default;
|
||||||
: _lextype (other._lextype)
|
|
||||||
, _tags (other._tags)
|
|
||||||
, _attributes (other._attributes)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
A2& A2::operator= (const A2& other)
|
A2& A2::operator= (const A2& other) = default;
|
||||||
{
|
|
||||||
_lextype = other._lextype;
|
|
||||||
_tags = other._tags;
|
|
||||||
_attributes = other._attributes;
|
|
||||||
return *this;
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
bool A2::hasTag (const std::string& tag) const
|
bool A2::hasTag (const std::string& tag) const
|
||||||
|
|
|
@ -49,11 +49,6 @@ Lexer::Lexer (const std::string& text)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
Lexer::~Lexer ()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
// When a Lexer object is constructed with a string, this method walks through
|
// When a Lexer object is constructed with a string, this method walks through
|
||||||
// the stream of low-level tokens.
|
// the stream of low-level tokens.
|
||||||
|
|
|
@ -54,7 +54,7 @@ public:
|
||||||
date, duration };
|
date, duration };
|
||||||
|
|
||||||
Lexer (const std::string&);
|
Lexer (const std::string&);
|
||||||
~Lexer ();
|
~Lexer () = default;
|
||||||
bool token (std::string&, Lexer::Type&);
|
bool token (std::string&, Lexer::Type&);
|
||||||
static std::vector <std::string> split (const std::string&);
|
static std::vector <std::string> split (const std::string&);
|
||||||
static std::string typeToString (Lexer::Type);
|
static std::string typeToString (Lexer::Type);
|
||||||
|
|
|
@ -166,19 +166,7 @@ const std::string& Variant::source () const
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
Variant& Variant::operator= (const Variant& other)
|
Variant& Variant::operator= (const Variant& other) = default;
|
||||||
{
|
|
||||||
_type = other._type;
|
|
||||||
_bool = other._bool;
|
|
||||||
_integer = other._integer;
|
|
||||||
_real = other._real;
|
|
||||||
_string = other._string;
|
|
||||||
_date = other._date;
|
|
||||||
_duration = other._duration;
|
|
||||||
_source = other._source;
|
|
||||||
|
|
||||||
return *this;
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
bool Variant::operator&& (const Variant& other) const
|
bool Variant::operator&& (const Variant& other) const
|
||||||
|
|
|
@ -238,11 +238,6 @@ Column::Column ()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
Column::~Column ()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
void Column::renderHeader (
|
void Column::renderHeader (
|
||||||
std::vector <std::string>& lines,
|
std::vector <std::string>& lines,
|
||||||
|
|
|
@ -41,7 +41,7 @@ public:
|
||||||
static Column* uda (const std::string&);
|
static Column* uda (const std::string&);
|
||||||
|
|
||||||
Column ();
|
Column ();
|
||||||
virtual ~Column ();
|
virtual ~Column () = default;
|
||||||
|
|
||||||
const std::string& name () const { return _name; }
|
const std::string& name () const { return _name; }
|
||||||
const std::string& style () const { return _style; }
|
const std::string& style () const { return _style; }
|
||||||
|
|
|
@ -124,7 +124,7 @@ public:
|
||||||
Chart (char);
|
Chart (char);
|
||||||
Chart (const Chart&); // Unimplemented
|
Chart (const Chart&); // Unimplemented
|
||||||
Chart& operator= (const Chart&); // Unimplemented
|
Chart& operator= (const Chart&); // Unimplemented
|
||||||
~Chart ();
|
~Chart () = default;
|
||||||
|
|
||||||
void scan (std::vector <Task>&);
|
void scan (std::vector <Task>&);
|
||||||
void scanForPeak (std::vector <Task>&);
|
void scanForPeak (std::vector <Task>&);
|
||||||
|
@ -184,11 +184,6 @@ Chart::Chart (char type)
|
||||||
_period = type;
|
_period = type;
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
Chart::~Chart ()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
// Scan all tasks, quantize the dates by day, and find the peak pending count
|
// Scan all tasks, quantize the dates by day, and find the peak pending count
|
||||||
// and corresponding epoch.
|
// and corresponding epoch.
|
||||||
|
|
|
@ -235,11 +235,6 @@ Command::Command ()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
|
||||||
Command::~Command ()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
std::string Command::keyword () const
|
std::string Command::keyword () const
|
||||||
{
|
{
|
||||||
|
|
|
@ -53,7 +53,7 @@ public:
|
||||||
};
|
};
|
||||||
|
|
||||||
Command ();
|
Command ();
|
||||||
virtual ~Command ();
|
virtual ~Command () = default;
|
||||||
|
|
||||||
static void factory (std::map <std::string, Command*>&);
|
static void factory (std::map <std::string, Command*>&);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue