In this article we’ll talk about memory alignment, so before we dive in, let’s start with a real-world example in Rust.
1use std::mem; 2 3struct Member { 4 active: bool, 5 age: i32, 6} 7 8fn main() { 9 println!(” bool: {} bytes”, mem::size_of::
This article is translated from:
https://dev.to/dillendev/memory-alignment-3j7e