From 558c22c072d7e7e77e0e5e3493a71727301f7c73 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Sat, 6 Jun 2026 13:52:54 +0900 Subject: fix(self-update-command): resolve finder-related phase-b TODOs - Add Display for SplFileInfo (PHP (string) cast -> getPathname) and use it in clean_backups instead of a debug-format placeholder. - Generalize iterator_to_array's signature to preserve the element type so get_last_backup_version collects real SplFileInfo and returns the last basename, instead of mapping every entry to PhpMixed::Null. - Drop the stale builder-restructure TODO in get_old_installation_finder. Co-Authored-By: Claude Opus 4.8 --- .../src/symfony/component/finder/spl_file_info.rs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'crates/shirabe-external-packages') diff --git a/crates/shirabe-external-packages/src/symfony/component/finder/spl_file_info.rs b/crates/shirabe-external-packages/src/symfony/component/finder/spl_file_info.rs index 31a0e50..3c1be6d 100644 --- a/crates/shirabe-external-packages/src/symfony/component/finder/spl_file_info.rs +++ b/crates/shirabe-external-packages/src/symfony/component/finder/spl_file_info.rs @@ -1,6 +1,12 @@ #[derive(Debug)] pub struct SplFileInfo; +impl std::fmt::Display for SplFileInfo { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + write!(f, "{}", self.get_pathname()) + } +} + impl SplFileInfo { pub fn new(_path: &str) -> Self { todo!() -- cgit v1.3.1