Skip to content

Commit

Permalink
Auto merge of #116866 - slanterns:inspect-stabilize, r=BurntSushi
Browse files Browse the repository at this point in the history
Stabilize `result_option_inspect`

This PR stabilizes `result_option_inspect`:

```rust
// core::option

impl Option<T> {
    pub fn inspect<F: FnOnce(&T)>(self, f: F) -> Self;
}

// core::result

impl Result<T, E> {
    pub fn inspect<F: FnOnce(&T)>(self, f: F) -> Self;
    pub fn inspect_err<F: FnOnce(&E)>(self, f: F) -> Self;
}
```

<br>

Tracking issue: rust-lang/rust#91345.
Implementation PR: rust-lang/rust#91346.

Closes rust-lang/rust#91345.
  • Loading branch information
bors committed Nov 13, 2023
2 parents 5be35aa + ab8c066 commit 971c499
Showing 0 changed files with 0 additions and 0 deletions.

0 comments on commit 971c499

Please sign in to comment.