mozilla/rust — pull request #11533 by alexcrichton (2014-01-14 06:27:04+00:00)
Title: std: Fix Rc with Gc inside of it

The code in Rc assumes that the inner box is allocated on the global exchange
heap, which is not always true. If T has managed pointers inside of it, it's
allocate on the local heap instead.

This commit reconciles these two modes of T by carefully interacting with the
inner box (with special treatment of its deallocation).

Closes #11532