be even more precise about "cast" vs "coercion"
This commit is contained in:
parent
5e60d1f87e
commit
bd31e3ed70
90 changed files with 291 additions and 233 deletions
|
@ -652,7 +652,7 @@ fn codegen_stmt<'tcx>(
|
|||
lval.write_cvalue(fx, res);
|
||||
}
|
||||
Rvalue::Cast(
|
||||
CastKind::PointerCoercion(PointerCoercion::ReifyFnPointer),
|
||||
CastKind::PointerCoercion(PointerCoercion::ReifyFnPointer, _),
|
||||
ref operand,
|
||||
to_ty,
|
||||
) => {
|
||||
|
@ -677,7 +677,7 @@ fn codegen_stmt<'tcx>(
|
|||
}
|
||||
}
|
||||
Rvalue::Cast(
|
||||
CastKind::PointerCoercion(PointerCoercion::UnsafeFnPointer),
|
||||
CastKind::PointerCoercion(PointerCoercion::UnsafeFnPointer, _),
|
||||
ref operand,
|
||||
to_ty,
|
||||
) => {
|
||||
|
@ -688,6 +688,7 @@ fn codegen_stmt<'tcx>(
|
|||
Rvalue::Cast(
|
||||
CastKind::PointerCoercion(
|
||||
PointerCoercion::MutToConstPointer | PointerCoercion::ArrayToPointer,
|
||||
_,
|
||||
),
|
||||
..,
|
||||
) => {
|
||||
|
@ -741,7 +742,7 @@ fn codegen_stmt<'tcx>(
|
|||
}
|
||||
}
|
||||
Rvalue::Cast(
|
||||
CastKind::PointerCoercion(PointerCoercion::ClosureFnPointer(_)),
|
||||
CastKind::PointerCoercion(PointerCoercion::ClosureFnPointer(_), _),
|
||||
ref operand,
|
||||
_to_ty,
|
||||
) => {
|
||||
|
@ -763,7 +764,7 @@ fn codegen_stmt<'tcx>(
|
|||
}
|
||||
}
|
||||
Rvalue::Cast(
|
||||
CastKind::PointerCoercion(PointerCoercion::Unsize),
|
||||
CastKind::PointerCoercion(PointerCoercion::Unsize, _),
|
||||
ref operand,
|
||||
_to_ty,
|
||||
) => {
|
||||
|
@ -771,7 +772,7 @@ fn codegen_stmt<'tcx>(
|
|||
crate::unsize::coerce_unsized_into(fx, operand, lval);
|
||||
}
|
||||
Rvalue::Cast(
|
||||
CastKind::PointerCoercion(PointerCoercion::DynStar),
|
||||
CastKind::PointerCoercion(PointerCoercion::DynStar, _),
|
||||
ref operand,
|
||||
_,
|
||||
) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue