diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-05-17 02:53:53 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-05-17 02:53:53 +0900 |
| commit | a1c7e6908a26e10f6e1f23a51721664b5e2d838d (patch) | |
| tree | c575c76f1b43359ed74913da4c6a2636643f1ba0 /crates/shirabe/src/autoload/class_map_generator.rs | |
| parent | 7f606f36fef0c0467c3c0db3d0da33af486dae8a (diff) | |
| download | php-shirabe-a1c7e6908a26e10f6e1f23a51721664b5e2d838d.tar.gz php-shirabe-a1c7e6908a26e10f6e1f23a51721664b5e2d838d.tar.zst php-shirabe-a1c7e6908a26e10f6e1f23a51721664b5e2d838d.zip | |
chore(style): cargo fmt
Diffstat (limited to 'crates/shirabe/src/autoload/class_map_generator.rs')
| -rw-r--r-- | crates/shirabe/src/autoload/class_map_generator.rs | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/crates/shirabe/src/autoload/class_map_generator.rs b/crates/shirabe/src/autoload/class_map_generator.rs index 3cfe83a..df61795 100644 --- a/crates/shirabe/src/autoload/class_map_generator.rs +++ b/crates/shirabe/src/autoload/class_map_generator.rs @@ -29,7 +29,13 @@ impl ClassMapGenerator { .map(|(k, v)| (k, Box::new(PhpMixed::String(v)))) .collect(), ); - std::fs::write(file, format!("<?php return {};", shirabe_php_shim::var_export(&maps_php, true)))?; + std::fs::write( + file, + format!( + "<?php return {};", + shirabe_php_shim::var_export(&maps_php, true) + ), + )?; Ok(()) } @@ -41,12 +47,21 @@ impl ClassMapGenerator { autoload_type: Option<String>, scanned_files: &mut IndexMap<String, bool>, ) -> anyhow::Result<IndexMap<String, String>> { - let generator = ExternalClassMapGenerator::new(vec!["php".to_string(), "inc".to_string(), "hh".to_string()]); + let generator = ExternalClassMapGenerator::new(vec![ + "php".to_string(), + "inc".to_string(), + "hh".to_string(), + ]); let mut file_list = FileList::new(); file_list.files = scanned_files.clone(); generator.avoid_duplicate_scans(&file_list); - generator.scan_paths(path, excluded.as_deref(), autoload_type.as_deref().unwrap_or("classmap"), namespace.as_deref())?; + generator.scan_paths( + path, + excluded.as_deref(), + autoload_type.as_deref().unwrap_or("classmap"), + namespace.as_deref(), + )?; let class_map = generator.get_class_map(); |
