mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-11-22 09:16:27 -06:00
remove EWOMS_GET_PARAM_LISTS macro
it adds no simplicity and only obfuscates
This commit is contained in:
parent
a2ff5e98ee
commit
399e39b31b
@ -109,17 +109,6 @@
|
||||
getPropValue<TypeTag, Properties::ParamName>(), \
|
||||
/*errorIfNotRegistered=*/false))
|
||||
|
||||
/*!
|
||||
* \ingroup Parameter
|
||||
*
|
||||
* \brief Retrieves the lists of parameters specified at runtime and their values.
|
||||
*
|
||||
* The two arguments besides the TypeTag are assumed to be STL containers which store
|
||||
* std::pair<std::string, std::string>.
|
||||
*/
|
||||
#define EWOMS_GET_PARAM_LISTS(TypeTag, UsedParamList, UnusedParamList) \
|
||||
(::Opm::Parameters::getLists<TypeTag>(UsedParamList, UnusedParamList))
|
||||
|
||||
namespace Opm {
|
||||
namespace Parameters {
|
||||
|
||||
@ -1088,6 +1077,12 @@ const ParamType get(const char *propTagName, const char *paramName, const ParamT
|
||||
return Param<TypeTag>::template get<ParamType>(propTagName, paramName, defaultValue, errorIfNotRegistered);
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Retrieves the lists of parameters specified at runtime and their values.
|
||||
*
|
||||
* The two arguments besides the TypeTag are assumed to be STL containers which store
|
||||
* std::pair<std::string, std::string>.
|
||||
*/
|
||||
template <class TypeTag, class Container>
|
||||
void getLists(Container& usedParams, Container& unusedParams)
|
||||
{
|
||||
|
@ -181,7 +181,7 @@ static inline int setupParameters_(int argc,
|
||||
ParamList usedParams;
|
||||
ParamList unusedParams;
|
||||
|
||||
EWOMS_GET_PARAM_LISTS(TypeTag, usedParams, unusedParams);
|
||||
Parameters::getLists<TypeTag>(usedParams, unusedParams);
|
||||
if (!allowUnused && !unusedParams.empty()) {
|
||||
if (myRank == 0) {
|
||||
if (unusedParams.size() == 1)
|
||||
|
Loading…
Reference in New Issue
Block a user