Skip to content

Commit f6f31dd

Browse files
committed
book: improve paragraph on stack de-allocation
1 parent 1661947 commit f6f31dd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/doc/trpl/the-stack-and-the-heap.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ and just consider the local variables we’re allocating. So in this case, when
4141
This is automatically handled for you, as you can see, we didn’t have to write
4242
any special Rust code or anything.
4343

44-
When the function is over, its stack frame gets deallocated. This happens
45-
automatically, we didn’t have to do anything special here.
44+
When the function exits, its stack frame gets deallocated. This happens
45+
automatically as well.
4646

4747
That’s all there is for this simple program. The key thing to understand here
4848
is that stack allocation is very, very fast. Since we know all the local

0 commit comments

Comments
 (0)