1
Fork 0

Rollup merge of #109378 - MU001999:master, r=scottmcm

Remove Ty::is_region_ptr

Fixes #109372
This commit is contained in:
Matthias Krüger 2023-03-22 22:44:42 +01:00 committed by GitHub
commit 2ee07a19b7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 12 additions and 24 deletions

View file

@ -1925,11 +1925,6 @@ impl<'tcx> Ty<'tcx> {
}
}
#[inline]
pub fn is_region_ptr(self) -> bool {
matches!(self.kind(), Ref(..))
}
#[inline]
pub fn is_mutable_ptr(self) -> bool {
matches!(
@ -1956,7 +1951,7 @@ impl<'tcx> Ty<'tcx> {
/// Tests if this is any kind of primitive pointer type (reference, raw pointer, fn pointer).
#[inline]
pub fn is_any_ptr(self) -> bool {
self.is_region_ptr() || self.is_unsafe_ptr() || self.is_fn_ptr()
self.is_ref() || self.is_unsafe_ptr() || self.is_fn_ptr()
}
#[inline]