template<typename keyword, typename pool>
tk::grm::use struct

Ensure that a grammar only uses keywords from a pool of pre-defined keywords.

In grammar definitions, every keyword should be wrapped around this use template, which conditionally inherits the keyword type its templated on (as defined in Control/Keywords.h) if the keyword is listed in any of the pools of keywords passed in as the required pool template argument and zero or more additional pools. If the keyword is not in any of the pools, a compiler error is generated, since the struct cannot inherit from base class 'char'. In that case, simply add the new keyword into one of the pools of keywords corresponding to the given grammar. The rationale behind this wrapper is to force the developer to maintain the keywords pool for a grammar. The pools are brigand::set and are used to provide help on command line arguments for a given executable. They allow compile-time iteration with brigand::for_each or generating a run-time std::map associating, e.g., keywords to their help strings.