Skip to content

Commit

Permalink
Rollup merge of rust-lang#35189 - mLuby:patch-1, r=steveklabnik
Browse files Browse the repository at this point in the history
Update the-stack-and-the-heap.md

Was surprised to learn that heaps were used in this way, then realized upon reading [the linked paper](http://www.cs.cmu.edu/afs/cs/academic/class/15213-f98/doc/dsa.pdf) that it's a totally different type of heap—an important distinction.
  • Loading branch information
GuillaumeGomez committed Aug 5, 2016
2 parents 8a923d4 + d90c166 commit 6e5e7e2
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/doc/book/the-stack-and-the-heap.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ The stack is very fast, and is where memory is allocated in Rust by default.
But the allocation is local to a function call, and is limited in size. The
heap, on the other hand, is slower, and is explicitly allocated by your
program. But it’s effectively unlimited in size, and is globally accessible.
Note this meaning of heap, which allocates arbitrary-sized blocks of memory in arbitrary
order, is quite different from the heap data structure.

# The Stack

Expand Down

0 comments on commit 6e5e7e2

Please sign in to comment.