Introduce NullOp::AlignOf
This commit is contained in:
@@ -648,7 +648,7 @@ impl Visitor<'tcx> for Checker<'mir, 'tcx> {
|
||||
}
|
||||
}
|
||||
|
||||
Rvalue::NullaryOp(NullOp::SizeOf, _) => {}
|
||||
Rvalue::NullaryOp(NullOp::SizeOf | NullOp::AlignOf, _) => {}
|
||||
Rvalue::NullaryOp(NullOp::Box, _) => self.check_op(ops::HeapAllocation),
|
||||
|
||||
Rvalue::UnaryOp(_, ref operand) => {
|
||||
|
||||
@@ -520,6 +520,7 @@ impl<'tcx> Validator<'_, 'tcx> {
|
||||
Rvalue::NullaryOp(op, _) => match op {
|
||||
NullOp::Box => return Err(Unpromotable),
|
||||
NullOp::SizeOf => {}
|
||||
NullOp::AlignOf => {}
|
||||
},
|
||||
|
||||
Rvalue::UnaryOp(op, operand) => {
|
||||
|
||||
Reference in New Issue
Block a user