book
book copied to clipboard
ch04-01 a sentence that might need to be changed
- [x] I have checked the latest
main
branch to see if this has already been fixed - [x] I have searched existing issues and pull requests for duplicates
URL to the section(s) of the book with this problem: https://github.com/rust-lang/book/blob/main/src/ch04-01-what-is-ownership.md
Description of the problem: Pushing to the stack is faster than allocating on the heap because the allocator never has to search for a place to store new data;
it's been explained before this that allocation is just for heap. this sentence calls pushing as allocating.
Suggested fix: Pushing to the stack is faster than allocating on the heap because it never has to search for a place to store new data;
I might be confused but I feelt that too when I read it.