File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
crates/lad_backends/mdbook_lad_preprocessor/src Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -82,7 +82,7 @@ impl ArgumentVisitor for MarkdownArgumentVisitor<'_> {
82
82
prefix_component. as_os_str ( ) . to_string_lossy ( ) . to_string ( )
83
83
}
84
84
std:: path:: Component :: Normal ( os_str) => {
85
- os_str. to_string_lossy ( ) . to_string ( )
85
+ os_str. to_string_lossy ( ) . to_string ( ) . replace ( " \\ " , "/" )
86
86
}
87
87
} )
88
88
. collect :: < Vec < _ > > ( )
@@ -169,14 +169,17 @@ mod test {
169
169
let mut visitor =
170
170
MarkdownArgumentVisitor :: new_with_linkifier ( & ladfile, |type_id, ladfile| {
171
171
Some (
172
- PathBuf :: from ( "root" )
172
+ PathBuf :: from ( "root\\ asd " )
173
173
. join ( ladfile. get_type_identifier ( & type_id, None ) . to_string ( ) ) ,
174
174
)
175
175
} ) ;
176
176
177
177
let first_type_id = ladfile. types . first ( ) . unwrap ( ) . 0 ;
178
178
visitor. visit_lad_type_id ( first_type_id) ;
179
- assert_eq ! ( visitor. buffer. build( ) , "StructType<[usize](root/usize)>" ) ;
179
+ assert_eq ! (
180
+ visitor. buffer. build( ) ,
181
+ "StructType<[usize](root/asd/usize)>"
182
+ ) ;
180
183
}
181
184
182
185
#[ test]
You can’t perform that action at this time.
0 commit comments