MacroProcessor: Add the argument name for set_if error messages

fixes #13345
This commit is contained in:
Michael Friedrich 2016-12-07 21:53:01 +01:00
parent b7caf0820d
commit b51a2c1c25

View File

@ -512,7 +512,8 @@ Value MacroProcessor::ResolveArguments(const Value& command, const Dictionary::P
} catch (const std::exception& ex) { } catch (const std::exception& ex) {
/* tried to convert a string */ /* tried to convert a string */
Log(LogWarning, "PluginUtility") Log(LogWarning, "PluginUtility")
<< "Error evaluating set_if value '" << set_if_resolved << "': " << ex.what(); << "Error evaluating set_if value '" << set_if_resolved
<< "' used in argument '" << arg.Key << "': " << ex.what();
continue; continue;
} }
} }
@ -550,7 +551,8 @@ Value MacroProcessor::ResolveArguments(const Value& command, const Dictionary::P
for (const CommandArgument& arg : args) { for (const CommandArgument& arg : args) {
if (arg.AValue.IsObjectType<Dictionary>()) { if (arg.AValue.IsObjectType<Dictionary>()) {
Log(LogWarning, "PluginUtility", "Tried to use dictionary in argument"); Log(LogWarning, "PluginUtility")
<< "Tried to use dictionary in argument '" << arg.Key << "'.";
continue; continue;
} else if (arg.AValue.IsObjectType<Array>()) { } else if (arg.AValue.IsObjectType<Array>()) {
bool first = true; bool first = true;