use shirabe_php_shim::PhpMixed; pub trait PromiseInterface { fn then( &self, on_fulfilled: Option) -> Option>>, on_rejected: Option) -> Option>>, ) -> Box; /// PHP closure shape: `fn(mixed): mixed`. Convenience wrapper around `then` /// for call sites that don't deal in `Option`. fn then_with( &self, _on_fulfilled: Option PhpMixed>>, _on_rejected: Option PhpMixed>>, ) -> Box { todo!() } /// PHP closure shape: `fn(mixed): mixed`, returning a `Box`. fn then_boxed( &self, _on_fulfilled: Option Box>>, _on_rejected: Option Box>>, ) -> Box { todo!() } /// Variant used by composer_repository where accept returns PhpMixed but reject returns /// an error/PhpMixed and the result is the same Promise pipeline. fn then_with_reject_boxed( &self, _on_fulfilled: Box anyhow::Result>, _on_rejected: Box anyhow::Result>, ) -> Box { todo!() } }