diff --git a/src/CLI2.cpp b/src/CLI2.cpp index a6560fded..bb86cb5bf 100644 --- a/src/CLI2.cpp +++ b/src/CLI2.cpp @@ -49,21 +49,10 @@ A2::A2 (const std::string& raw, Lexer::Type lextype) } //////////////////////////////////////////////////////////////////////////////// -A2::A2 (const A2& other) -: _lextype (other._lextype) -, _tags (other._tags) -, _attributes (other._attributes) -{ -} +A2::A2 (const A2& other) = default; //////////////////////////////////////////////////////////////////////////////// -A2& A2::operator= (const A2& other) -{ - _lextype = other._lextype; - _tags = other._tags; - _attributes = other._attributes; - return *this; -} +A2& A2::operator= (const A2& other) = default; //////////////////////////////////////////////////////////////////////////////// bool A2::hasTag (const std::string& tag) const diff --git a/src/Lexer.cpp b/src/Lexer.cpp index 703681e68..39e8866d6 100644 --- a/src/Lexer.cpp +++ b/src/Lexer.cpp @@ -50,9 +50,7 @@ Lexer::Lexer (const std::string& text) } //////////////////////////////////////////////////////////////////////////////// -Lexer::~Lexer () -{ -} +Lexer::~Lexer () = default; //////////////////////////////////////////////////////////////////////////////// // When a Lexer object is constructed with a string, this method walks through diff --git a/src/Variant.cpp b/src/Variant.cpp index 133320f55..d0afa4234 100644 --- a/src/Variant.cpp +++ b/src/Variant.cpp @@ -166,19 +166,7 @@ const std::string& Variant::source () const } //////////////////////////////////////////////////////////////////////////////// -Variant& Variant::operator= (const Variant& other) -{ - _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; -} +Variant& Variant::operator= (const Variant& other) = default; //////////////////////////////////////////////////////////////////////////////// bool Variant::operator&& (const Variant& other) const