mirror of
https://github.com/Tencent/rapidjson.git
synced 2025-10-28 19:52:02 +01:00
Fix warnings in clang for C++11
This commit is contained in:
@@ -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) {
|
||||
|
||||
Reference in New Issue
Block a user