diff options
| author | bors <bors@rust-lang.org> | 2017-11-07 20:55:01 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2017-11-07 20:55:01 +0000 |
| commit | ee2286149a5f0b148334841d4f067dc819dcca3b (patch) | |
| tree | 5b4b0668d459e417c61355d519ff3675b6ec80a5 /src/rustllvm/RustWrapper.cpp | |
| parent | 7f6417e9b72de63666fd92caf1a6b96a778b60ed (diff) | |
| parent | 604f049cd5060129cf14f7bd340d442811345ea8 (diff) | |
| download | rust-ee2286149a5f0b148334841d4f067dc819dcca3b.tar.gz rust-ee2286149a5f0b148334841d4f067dc819dcca3b.zip | |
Auto merge of #44932 - cuviper:unsized-ptr-is_null, r=alexcrichton
Remove `T: Sized` on pointer `as_ref()` and `as_mut()` `NonZero::is_zero()` was already casting all pointers to thin `*mut u8` to check for null. The same test on unsized fat pointers can also be used with `as_ref()` and `as_mut()` to get fat references. (This PR formerly changed `is_null()` too, but checking just the data pointer is not obviously correct for trait objects, especially if `*const self` sorts of methods are ever allowed.)
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions
