diff options
| author | Eduardo Sánchez Muñoz <eduardosm-dev@e64.io> | 2024-09-09 12:22:00 +0200 |
|---|---|---|
| committer | Eduardo Sánchez Muñoz <eduardosm-dev@e64.io> | 2024-09-09 13:32:22 +0200 |
| commit | 0b20ffcb63b00acbbe70ae6f59a746bcde4c8b96 (patch) | |
| tree | c180e16946093089cae099b227d33c675805b07a /compiler/rustc_middle/src/ty | |
| parent | adf8d168af9334a8bf940824fcf4207d01e05ae5 (diff) | |
| download | rust-0b20ffcb63b00acbbe70ae6f59a746bcde4c8b96.tar.gz rust-0b20ffcb63b00acbbe70ae6f59a746bcde4c8b96.zip | |
Remove needless returns detected by clippy in the compiler
Diffstat (limited to 'compiler/rustc_middle/src/ty')
| -rw-r--r-- | compiler/rustc_middle/src/ty/context.rs | 2 | ||||
| -rw-r--r-- | compiler/rustc_middle/src/ty/region.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_middle/src/ty/context.rs b/compiler/rustc_middle/src/ty/context.rs index 2a3008897c6..2571cbbf299 100644 --- a/compiler/rustc_middle/src/ty/context.rs +++ b/compiler/rustc_middle/src/ty/context.rs @@ -2003,7 +2003,7 @@ impl<'tcx> TyCtxt<'tcx> { )); } } - return None; + None } /// Checks if the bound region is in Impl Item. diff --git a/compiler/rustc_middle/src/ty/region.rs b/compiler/rustc_middle/src/ty/region.rs index a2a96105777..44956d5b0a6 100644 --- a/compiler/rustc_middle/src/ty/region.rs +++ b/compiler/rustc_middle/src/ty/region.rs @@ -431,7 +431,7 @@ impl BoundRegionKind { pub fn get_id(&self) -> Option<DefId> { match *self { - BoundRegionKind::BrNamed(id, _) => return Some(id), + BoundRegionKind::BrNamed(id, _) => Some(id), _ => None, } } |
