#include <Builder.h>
|
| UnusedWalker (std::set< std::string > used, Builder &p) |
|
void | walk (const std::string &fullpath, const std::string &nodename, hit::Node *n) override |
|
|
std::vector< std::string > | errors |
|
Definition at line 39 of file Builder.h.
◆ UnusedWalker()
Moose::UnusedWalker::UnusedWalker |
( |
std::set< std::string > |
used, |
|
|
Builder & |
p |
|
) |
| |
|
inline |
Definition at line 42 of file Builder.h.
std::set< std::string > _used
◆ walk()
void Moose::UnusedWalker::walk |
( |
const std::string & |
fullpath, |
|
|
const std::string & |
nodename, |
|
|
hit::Node * |
n |
|
) |
| |
|
override |
Definition at line 179 of file Builder.C.
184 if (!
_used.count(fullpath) && nodename !=
"active" && nodename !=
"inactive" &&
187 auto section_name = fullpath.substr(0, fullpath.rfind(
"/"));
189 auto candidates =
findSimilar(nodename, paramlist);
190 if (candidates.size() > 0)
191 errors.push_back(hit::errormsg(
192 n,
"unused parameter '", fullpath,
"'\n",
" Did you mean '", candidates[0],
"'?"));
194 errors.push_back(hit::errormsg(n,
"unused parameter '", fullpath,
"'"));
std::vector< std::string > errors
std::set< std::string > _used
std::vector< std::string > listValidParams(std::string §ion_name)
std::vector< std::string > findSimilar(std::string param, std::vector< std::string > options)
bool isSectionActive(std::string path, hit::Node *root)
◆ _builder
Builder& Moose::UnusedWalker::_builder |
|
private |
◆ _used
std::set<std::string> Moose::UnusedWalker::_used |
|
private |
◆ errors
std::vector<std::string> Moose::UnusedWalker::errors |
The documentation for this class was generated from the following files: