Zips `self` with another [`CtOption`]. If `self.is_some() && other.is_some()`, this method returns a new [`CtOption`] for a 2-tuple of their contents where `is_some()` is [`Choice::TRUE`]. Otherwise, a [`CtOption`] where `is_some()` is [`Choice::FALSE`] is returned.
(self, other: CtOption<U>)
| 492 | /// |
| 493 | /// Otherwise, a [`CtOption`] where `is_some()` is [`Choice::FALSE`] is returned. |
| 494 | pub fn zip<U>(self, other: CtOption<U>) -> CtOption<(T, U)> { |
| 495 | CtOption { |
| 496 | value: (self.value, other.value), |
| 497 | is_some: self.is_some & other.is_some, |
| 498 | } |
| 499 | } |
| 500 | |
| 501 | /// Zips `self` and another `CtOption` with function `f`. |
| 502 | /// |
no outgoing calls
no test coverage detected