is_null is a tricky one isn't it? If you just compare one field (the pointer) to null, then for a fat pointer there are many null values. Might surprise someone down the line, don't know if there is any worse impact than that.
Related topics
Topic | Replies | Views | Activity | |
---|---|---|---|---|
Is there a reason that std::ptr requires T: Sized? | 4 | 896 | January 12, 2023 | |
Zero initialize `AtomicPtr` and `AtomicUsize` | 8 | 1472 | January 12, 2023 | |
Pre-RFC: Zero-Sized References to Zero-Sized Types
|
11 | 2500 | January 12, 2023 | |
Size of () type in *mut () | 5 | 1189 | January 12, 2023 | |
Is the null pointer guaranteed to be aligned? | 27 | 2841 | January 12, 2023 |