Skip to content

Commit 60aafee

Browse files
committed
Remove Ty::is_region_ptr
1 parent edb0717 commit 60aafee

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/vtable.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,7 @@ pub(crate) fn get_ptr_and_method_ref<'tcx>(
4848
) -> (Pointer, Value) {
4949
let (ptr, vtable) = 'block: {
5050
if let Abi::Scalar(_) = arg.layout().abi {
51-
'descend_newtypes: while !arg.layout().ty.is_unsafe_ptr()
52-
&& !arg.layout().ty.is_region_ptr()
53-
{
51+
'descend_newtypes: while !arg.layout().ty.is_unsafe_ptr() && !arg.layout().ty.is_ref() {
5452
for i in 0..arg.layout().fields.count() {
5553
let field = arg.value_field(fx, mir::Field::new(i));
5654
if !field.layout().is_zst() {

0 commit comments

Comments
 (0)