about summary refs log tree commit diff
path: root/src/liballoc
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2016-06-03 22:32:15 -0700
committerbors <bors@rust-lang.org>2016-06-03 22:32:15 -0700
commit7738479d72418ddc08febee0fa7097df334d357e (patch)
tree02db04b160da2230fa0097d6fea5331237945e29 /src/liballoc
parentc81c75076c05990af6f71e56ccc12d7b196ee25c (diff)
parentbc7595c8abbf4e3b737e926d61814686e0ebda77 (diff)
downloadrust-7738479d72418ddc08febee0fa7097df334d357e.tar.gz
rust-7738479d72418ddc08febee0fa7097df334d357e.zip
Auto merge of #33460 - shepmaster:16-bit-pointers, r=Aatch
Support 16-bit pointers as well as i/usize

I'm opening this pull request to get some feedback from the community.

Although Rust doesn't support any platforms with a native 16-bit pointer at the moment, the [AVR-Rust][ar] fork is working towards that goal. Keeping this forked logic up-to-date with the changes in master has been onerous so I'd like to merge these changes so that they get carried along when refactoring happens. I do not believe this should increase the maintenance burden.

This is based on the original work of Dylan McKay (@dylanmckay).

[ar]: https://github.com/avr-rust/rust
Diffstat (limited to 'src/liballoc')
-rw-r--r--src/liballoc/raw_vec.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/liballoc/raw_vec.rs b/src/liballoc/raw_vec.rs
index 8b3168b29aa..58c841151c0 100644
--- a/src/liballoc/raw_vec.rs
+++ b/src/liballoc/raw_vec.rs
@@ -578,9 +578,9 @@ impl<T> Drop for RawVec<T> {
 // * We don't overflow `usize::MAX` and actually allocate too little
 //
 // On 64-bit we just need to check for overflow since trying to allocate
-// `> isize::MAX` bytes will surely fail. On 32-bit we need to add an extra
-// guard for this in case we're running on a platform which can use all 4GB in
-// user-space. e.g. PAE or x32
+// `> isize::MAX` bytes will surely fail. On 32-bit and 16-bit we need to add
+// an extra guard for this in case we're running on a platform which can use
+// all 4GB in user-space. e.g. PAE or x32
 
 #[inline]
 fn alloc_guard(alloc_size: usize) {