fix(CLI): completed list of parameter names

Previously the 'did-you-mean' functionality only knew the global
paramters, but not the method-local ones.
This commit is contained in:
Sebastian Thiel
2015-05-05 20:46:45 +02:00
parent bbab1f2e38
commit 9274938f9f

View File

@@ -259,7 +259,7 @@ ${value_unwrap}\
call = call.${ADD_PARAM_FN}(map.iter().find(|t| t.0 == key).unwrap_or(&("", key)).1, ${value_unwrap})
},
% endif # handle global parameters
_ => err.issues.push(CLIError::UnknownParameter(key.to_string(), ${field_vec(global_parameter_names)})),
_ => err.issues.push(CLIError::UnknownParameter(key.to_string(), ${field_vec(global_parameter_names + [p.name for p in optional_props])})),
}
}
% endif # handle call parameters