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>)
| 494 | /// |
| 495 | /// Otherwise, a [`CtOption`] where `is_some()` is [`Choice::FALSE`] is returned. |
| 496 | pub fn zip<U>(self, other: CtOption<U>) -> CtOption<(T, U)> { |
| 497 | CtOption { |
| 498 | value: (self.value, other.value), |
| 499 | is_some: self.is_some & other.is_some, |
| 500 | } |
| 501 | } |
| 502 | |
| 503 | /// Zips `self` and another `CtOption` with function `f`. |
| 504 | /// |
no outgoing calls
no test coverage detected