diff options
| author | bors <bors@rust-lang.org> | 2023-06-28 15:39:04 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2023-06-28 15:39:04 +0000 |
| commit | ea4c5c5ca55ae9614552c0d285ee6c051cf88b30 (patch) | |
| tree | dbbd40abef29572b61a2448980fbd2bdfceb8022 /compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp | |
| parent | 750c7a11da90087c824c4782507c159e4c26ea5a (diff) | |
| parent | cee4c4169c0f98bafe2e2c6cd6d3d2d401e5ce18 (diff) | |
| download | rust-ea4c5c5ca55ae9614552c0d285ee6c051cf88b30.tar.gz rust-ea4c5c5ca55ae9614552c0d285ee6c051cf88b30.zip | |
Auto merge of #11035 - y21:issue10729, r=Jarcho
[`option_if_let_else`]: suggest `.as_ref()` if scrutinee is of type `&Option<_>` Fixes #10729 `Option::map_or` takes ownership, so if matching on an `&Option<_>`, we need to suggest `.as_ref()` before calling `map_or` to get the same effect and to not cause a borrowck error. changelog: [`option_if_let_else`]: suggest `.as_ref()`/`.as_mut()` if scrutinee is of type `&Option<_>`/`&mut Option<_>`
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
