about summary refs log tree commit diff
path: root/src/libstd/rt
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2013-11-22 12:41:36 -0800
committerbors <bors@rust-lang.org>2013-11-22 12:41:36 -0800
commit09ed7913e43cf0234a1bbe3f29dcd52c6a166961 (patch)
treea8cc359123596c1e10e134dda52e62a7e92656da /src/libstd/rt
parentcd9069ca734fe89fe446c16dc821e54b973506f5 (diff)
parent861e6f5cd26b4a568d64d78ec85f3e67ab2eea7b (diff)
downloadrust-09ed7913e43cf0234a1bbe3f29dcd52c6a166961.tar.gz
rust-09ed7913e43cf0234a1bbe3f29dcd52c6a166961.zip
auto merge of #10612 : pnkfelix/rust/remove-cut-and-pasted-rt-fixme, r=pcwalton
I cannot tell whether the original comment was unsure about the
arithmetic calculations, or if it was unsure about the assumptions
being made about the alignment of the current allocation pointer.

The arithmetic calculation looks fine to me, though.  This technique
is documented e.g. in Henry Warren's "Hacker's Delight" (section 3-1).

(I am sure one can find it elsewhere too, its not an obscure
property.)
Diffstat (limited to 'src/libstd/rt')
-rw-r--r--src/libstd/rt/global_heap.rs1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/libstd/rt/global_heap.rs b/src/libstd/rt/global_heap.rs
index c6e2724b0f2..08d111da351 100644
--- a/src/libstd/rt/global_heap.rs
+++ b/src/libstd/rt/global_heap.rs
@@ -20,7 +20,6 @@ extern {
 #[inline]
 pub fn get_box_size(body_size: uint, body_align: uint) -> uint {
     let header_size = size_of::<raw::Box<()>>();
-    // FIXME (#2699): This alignment calculation is suspicious. Is it right?
     let total_size = align_to(header_size, body_align) + body_size;
     total_size
 }