Rust references and borrowing from the inside

Now it is time to talk about references and borrowing. To understand this topic, first check out this post where I talk about ownership and move semantics. As we have seen in the named article, the way Rust manages memory allocations is rather unique. This is also true when we talk about referencing some place in the memory, something that can be achieved in C with pointers. GDB In this post I am going to explore what is happening in memory using the GNU Debugger (gdb) with the special command rust-gdb: ...

March 24, 2024 · 13 min · Nicolás Antinori

Rust ownership and move semantics from the inside

Ownership and move semantics is one of the things that makes Rust unique. To understand this topic, you need to understand what Stack and Heap are at a basic level. I wrote a post about that! You can check it out if you need a refresher on those concepts. It is a little bit hard to get used to this feature because it forces you to think about stuff that you didn’t have to worry about in other languages. Enough introduction, let’s cut to the chase! ...

October 18, 2022 · 10 min · Nicolás Antinori

Stack and Heap

Why write about Stack and Heap when there are already a lot of articles out there? I want to improve my writing skills so, I decided to write articles about things I find interesting. This article was supposed to be about how Rust manages memory through ownership. Then I thought “I should first write about Stack and Heap”. So, here we are). To understand memory management first, we need to understand what the Stack and the Heap are. Stack and Heap are memory regions used by a process to store and read values. The memory of a running process can usually be divided in the following four regions: ...

July 26, 2022 · 6 min · Nicolás Antinori