mirror of
https://github.com/open-source-parsers/jsoncpp.git
synced 2025-10-18 03:29:46 +02:00
C++11: override keyword
Source : http://en.cppreference.com/w/cpp/language/override
This commit is contained in:
@@ -1903,9 +1903,9 @@ public:
|
||||
: collectComments_(collectComments)
|
||||
, reader_(features)
|
||||
{}
|
||||
virtual bool parse(
|
||||
bool parse(
|
||||
char const* beginDoc, char const* endDoc,
|
||||
Value* root, std::string* errs) {
|
||||
Value* root, std::string* errs) override {
|
||||
bool ok = reader_.parse(beginDoc, endDoc, *root, collectComments_);
|
||||
if (errs) {
|
||||
*errs = reader_.getFormattedErrorMessages();
|
||||
|
@@ -816,7 +816,7 @@ struct BuiltStyledStreamWriter : public StreamWriter
|
||||
std::string const& nullSymbol,
|
||||
std::string const& endingLineFeedSymbol,
|
||||
bool useSpecialFloats);
|
||||
virtual int write(Value const& root, std::ostream* sout);
|
||||
int write(Value const& root, std::ostream* sout) override;
|
||||
private:
|
||||
void writeValue(Value const& value);
|
||||
void writeArrayValue(Value const& value);
|
||||
|
@@ -265,8 +265,8 @@ TestResult& checkStringEqual(TestResult& result,
|
||||
} \
|
||||
\
|
||||
public: /* overidden from TestCase */ \
|
||||
virtual const char* testName() const { return #FixtureType "/" #name; } \
|
||||
virtual void runTestCase(); \
|
||||
const char* testName() const override { return #FixtureType "/" #name; } \
|
||||
void runTestCase() override; \
|
||||
}; \
|
||||
\
|
||||
void Test##FixtureType##name::runTestCase()
|
||||
|
Reference in New Issue
Block a user