@@ -51,6 +51,7 @@ pub(crate) enum SectionData<'a> {
51
51
lad_type : & ' a LadType ,
52
52
} ,
53
53
FunctionDetail {
54
+ types_directory : PathBuf ,
54
55
function : & ' a LadFunction ,
55
56
} ,
56
57
}
@@ -214,7 +215,10 @@ impl<'a> Section<'a> {
214
215
Section :: new (
215
216
child_parent_path. clone ( ) ,
216
217
self . ladfile ,
217
- SectionData :: FunctionDetail { function } ,
218
+ SectionData :: FunctionDetail {
219
+ function,
220
+ types_directory : PathBuf :: from ( "../types" ) ,
221
+ } ,
218
222
)
219
223
} )
220
224
. collect ( )
@@ -230,7 +234,10 @@ impl<'a> Section<'a> {
230
234
Some ( Section :: new (
231
235
child_parent_path. clone ( ) ,
232
236
self . ladfile ,
233
- SectionData :: FunctionDetail { function } ,
237
+ SectionData :: FunctionDetail {
238
+ function,
239
+ types_directory : PathBuf :: from ( "../../types" ) ,
240
+ } ,
234
241
) )
235
242
} )
236
243
. collect ( ) ,
@@ -350,12 +357,14 @@ impl<'a> Section<'a> {
350
357
} ,
351
358
]
352
359
}
353
- SectionData :: FunctionDetail { function } => {
354
- let types_directory = PathBuf :: from ( "../types" ) ;
360
+ SectionData :: FunctionDetail {
361
+ function,
362
+ ref types_directory,
363
+ } => {
355
364
vec ! [ SectionItem :: FunctionDetails {
356
365
function,
357
366
ladfile: self . ladfile,
358
- types_directory,
367
+ types_directory: types_directory . clone ( ) ,
359
368
} ]
360
369
}
361
370
}
0 commit comments