diff options
| author | Tim Diekmann <tim.diekmann@3dvision.de> | 2020-03-25 18:30:14 +0100 |
|---|---|---|
| committer | Tim Diekmann <tim.diekmann@3dvision.de> | 2020-03-26 17:12:18 +0100 |
| commit | d9d35cc6967501818863adcb556991357098557d (patch) | |
| tree | 05ba8556062da6f8526dd02e3630fa86f5356178 /src/libstd | |
| parent | 2f215b61b6368dad7b10295267a8f1a5a1bfafe8 (diff) | |
Add comment to `AllocRef` implementation for `System`
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/alloc.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libstd/alloc.rs b/src/libstd/alloc.rs index f295565bec3..6e8ac7c9036 100644 --- a/src/libstd/alloc.rs +++ b/src/libstd/alloc.rs @@ -134,6 +134,8 @@ pub use alloc_crate::alloc::*; #[derive(Debug, Default, Copy, Clone)] pub struct System; +// The AllocRef impl checks the layout size to be non-zero and forwards to the GlobalAlloc impl, +// which is in `std::sys::*::alloc`. #[unstable(feature = "allocator_api", issue = "32838")] unsafe impl AllocRef for System { #[inline] |
