We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4ca7a34 commit 50510e4Copy full SHA for 50510e4
src/librustc/mir/interpret/value.rs
@@ -275,17 +275,6 @@ impl<'tcx, Tag> Scalar<Tag> {
275
}
276
277
278
- #[inline]
279
- pub fn is_null_ptr(self, cx: &impl HasDataLayout) -> bool {
280
- match self {
281
- Scalar::Raw { data, size } => {
282
- assert_eq!(size as u64, cx.data_layout().pointer_size.bytes());
283
- data == 0
284
- },
285
- Scalar::Ptr(_) => false,
286
- }
287
288
-
289
#[inline]
290
pub fn from_bool(b: bool) -> Self {
291
Scalar::Raw { data: b as u128, size: 1 }
0 commit comments