Make a member function a const member function.

Issue found by cppcheck.
This commit is contained in:
Mark de Wever 2010-07-18 16:29:05 +00:00
parent 7badda3692
commit dd09a963da
2 changed files with 4 additions and 2 deletions

View File

@ -133,7 +133,9 @@ void persist_context::set_node(const std::string &name) {
active_ = &(root_node_.child(name));
namespace_ = name_space(namespace_.namespace_ + "." + name);
}
std::string persist_context::get_node() {
std::string persist_context::get_node() const
{
return namespace_.namespace_;
}

View File

@ -183,7 +183,7 @@ public:
bool clear_var(std::string &);
config get_var(const std::string &) const;
bool set_var(const std::string &, const config &);
std::string get_node();
std::string get_node() const;
void set_node(const std::string &);
bool valid() const { return valid_; };
bool dirty() const {