File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,6 @@ use std::path::PathBuf;
7
7
pub struct StructAttrs {
8
8
name : String ,
9
9
rename_all : Option < RenameAll > ,
10
- rename : Option < String > ,
11
10
export : Option < PathBuf > ,
12
11
}
13
12
@@ -16,7 +15,6 @@ impl StructAttrs {
16
15
let mut struct_attrs = Self {
17
16
name : struct_name,
18
17
rename_all : None ,
19
- rename : None ,
20
18
export : None ,
21
19
} ;
22
20
@@ -41,7 +39,7 @@ impl StructAttrs {
41
39
let value = get_nested_value ( & meta)
42
40
. expect ( "Failed to parse rename attribute" ) ;
43
41
44
- struct_attrs. rename = Some ( value) ;
42
+ struct_attrs. name = value;
45
43
}
46
44
"rename_all" => {
47
45
let value = get_nested_value ( & meta)
@@ -88,7 +86,7 @@ impl StructAttrs {
88
86
}
89
87
90
88
pub fn get_name ( & self ) -> & String {
91
- self . rename . as_ref ( ) . unwrap_or ( & self . name )
89
+ & self . name
92
90
}
93
91
94
92
pub fn get_export_path ( & self ) -> PathBuf {
You can’t perform that action at this time.
0 commit comments