Fix warnings in clang for C++11

This commit is contained in:
Milo Yip
2016-01-23 14:37:15 +08:00
parent 534da223f7
commit a6eb15d274
12 changed files with 121 additions and 11 deletions

View File

@@ -11,6 +11,7 @@ using namespace rapidjson;
class Person {
public:
Person(const std::string& name, unsigned age) : name_(name), age_(age) {}
Person(const Person& rhs) : name_(rhs.name_), age_(rhs.age_) {}
virtual ~Person();
protected:
@@ -38,6 +39,7 @@ Person::~Person() {
class Education {
public:
Education(const std::string& school, double GPA) : school_(school), GPA_(GPA) {}
Education(const Education& rhs) : school_(rhs.school_), GPA_(rhs.GPA_) {}
template <typename Writer>
void Serialize(Writer& writer) const {
@@ -102,6 +104,7 @@ Dependent::~Dependent() {
class Employee : public Person {
public:
Employee(const std::string& name, unsigned age, bool married) : Person(name, age), dependents_(), married_(married) {}
Employee(const Employee& rhs) : Person(rhs), dependents_(rhs.dependents_), married_(rhs.married_) {}
virtual ~Employee();
void AddDependent(const Dependent& dependent) {