From e87d37a294a4c754585309d391d793a2c9a1287e Mon Sep 17 00:00:00 2001 From: nsfisis Date: Wed, 24 Jun 2026 04:16:08 +0900 Subject: feat(console): implement application description for `list` Replace the todo!() in TextDescriptor::describe_application with a real option-only InputDefinition built via InputDefinition::from_options, which shares InputOption behind Rc instead of reconstructing by value. Drop the now-unused Command::clone_box and switch the descriptors to borrow the shared commands directly. Co-Authored-By: Claude Opus 4.8 (1M context) --- .../src/symfony/console/descriptor/xml_descriptor.rs | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'crates/shirabe-external-packages/src/symfony/console/descriptor/xml_descriptor.rs') diff --git a/crates/shirabe-external-packages/src/symfony/console/descriptor/xml_descriptor.rs b/crates/shirabe-external-packages/src/symfony/console/descriptor/xml_descriptor.rs index fc2b948..77fca93 100644 --- a/crates/shirabe-external-packages/src/symfony/console/descriptor/xml_descriptor.rs +++ b/crates/shirabe-external-packages/src/symfony/console/descriptor/xml_descriptor.rs @@ -120,13 +120,9 @@ impl XmlDescriptor { commands_xml.set_attribute("namespace", namespace); } - let command_list: Vec<_> = description - .get_commands() - .values() - .map(|c| c.borrow().clone_box()) - .collect(); - for command in command_list { - let command_xml = self.get_command_document(command.as_ref(), short); + for command in description.get_commands().values() { + let command = command.borrow(); + let command_xml = self.get_command_document(&*command, short); self.append_document(&commands_xml, &command_xml.as_node()); } -- cgit v1.3.1