We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents de2b8d9 + 70611bf commit 5092eecCopy full SHA for 5092eec
src/lib.rs
@@ -280,8 +280,11 @@ fn format_ast(krate: &ast::Crate,
280
config: &Config)
281
-> FileMap {
282
let mut file_map = FileMap::new();
283
+ // We always skip children for the "Plain" write mode, since there is
284
+ // nothing to distinguish the nested module contents.
285
+ let skip_children = config.skip_children || config.write_mode == config::WriteMode::Plain;
286
for (path, module) in modules::list_files(krate, parse_session.codemap()) {
- if config.skip_children && path.as_path() != main_file {
287
+ if skip_children && path.as_path() != main_file {
288
continue;
289
}
290
let path = path.to_str().unwrap();
0 commit comments