diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-08-10 04:43:42 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-08-10 04:45:58 +0900 |
| commit | f1bf9d50634899aad30dfb60fdb1e0a7ab305229 (patch) | |
| tree | f14a07c6b146508864cd3d626e6cccb794644388 /crates/shirabe-symfony-console/src | |
| parent | 9d9da0d1512202af7802d13b1c3c33a1a077a84e (diff) | |
| download | php-shirabe-f1bf9d50634899aad30dfb60fdb1e0a7ab305229.tar.gz php-shirabe-f1bf9d50634899aad30dfb60fdb1e0a7ab305229.tar.zst php-shirabe-f1bf9d50634899aad30dfb60fdb1e0a7ab305229.zip | |
refactor(symfony-console): drop the unusable defaultName stubs
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Diffstat (limited to 'crates/shirabe-symfony-console/src')
| -rw-r--r-- | crates/shirabe-symfony-console/src/command/command.rs | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/crates/shirabe-symfony-console/src/command/command.rs b/crates/shirabe-symfony-console/src/command/command.rs index 831795e7..bb4d35e9 100644 --- a/crates/shirabe-symfony-console/src/command/command.rs +++ b/crates/shirabe-symfony-console/src/command/command.rs @@ -53,27 +53,6 @@ impl CommandData { pub const FAILURE: i64 = 1; pub const INVALID: i64 = 2; - /// The default command name. - // NOTE: PHP `protected static $defaultName`; static late-binding property. - pub const DEFAULT_NAME: Option<&'static str> = None; - - /// The default command description. - // NOTE: PHP `protected static $defaultDescription`; static late-binding property. - pub const DEFAULT_DESCRIPTION: Option<&'static str> = None; - - pub fn get_default_name() -> Option<String> { - // TODO(phase-c): PHP uses ReflectionClass to read the #[AsCommand] attribute - // and ReflectionProperty to check that `$defaultName` is declared on the late-static - // class itself (not inherited). Reflection-based late static binding has no direct - // Rust equivalent; human review needed for the porting strategy. - todo!() - } - - pub fn get_default_description() -> Option<String> { - // TODO(phase-c): same Reflection/late-static-binding concern as get_default_name(). - todo!() - } - /// Builds the base-class state. `name` is the name of the command; passing None /// means it must be set in the subclass `configure()`. /// @@ -100,10 +79,6 @@ impl CommandData { helper_set: std::cell::RefCell::new(None), }; - // PHP's __construct also derives the name from getDefaultName() when null and - // sets the default description; both rely on Reflection late-static-binding - // (get_default_name/get_default_description are todo!()), and concrete commands - // always set their name in configure(), so only an explicit name is honored here. if let Some(name) = name { *this.name.borrow_mut() = Some(name); } |
