Skip to content

compilation gives a warning #683

Closed
Closed
@mkm85

Description

@mkm85
[ 22%] Building CXX object src/lib_json/CMakeFiles/jsoncpp_lib_static.dir/json_value.cpp.o
/home/mkm/sandbox/jsoncpp/src/lib_json/json_value.cpp: In member function ‘Json::Value Json::Value::removeMember(const string&)’:
/home/mkm/sandbox/jsoncpp/src/lib_json/json_value.cpp:1203:34: warning: ‘Json::Value Json::Value::removeMember(const char*)’ is deprecated:  [-Wdeprecated-declarations]
   return removeMember(key.c_str());
                                  ^
/home/mkm/sandbox/jsoncpp/src/lib_json/json_value.cpp:1190:7: note: declared here
 Value Value::removeMember(const char* key)
       ^~~~~

A possible solution is to call a shared non deprecated private function instead of calling one deprecated function from another deprecated function

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions