Returns true if the pointer is null. # Examples ``` # let _context = cust::quick_init().unwrap(); use cust::memory::*; use std::ptr; unsafe { let null : *mut u64 = ptr::null_mut(); assert!(DevicePointer::wrap(null).is_null()); } ```
(self)
| 76 | /// } |
| 77 | /// ``` |
| 78 | pub fn is_null(self) -> bool { |
| 79 | self.ptr == 0 |
| 80 | } |
| 81 | |
| 82 | /// Returns a null device pointer. |
| 83 | /// |
no outgoing calls
no test coverage detected