Commit 5f85ed5f authored by Josh Chase's avatar Josh Chase Committed by Ryan Hunt

Don't rename struct generic type parameters

parent 270491f4
......@@ -119,8 +119,14 @@ impl Item for Struct {
fn rename_for_config(&mut self, config: &Config) {
config.export.rename(&mut self.name);
for &mut (_, ref mut ty, _) in &mut self.fields {
let generic_parameter = match ty.get_root_path() {
Some(ref p) => self.generic_params.contains(p),
None => false,
};
if !generic_parameter {
ty.rename_for_config(config);
}
}
let field_rules = [
self.annotations.parse_atom::<RenameRule>("rename-all"),
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment