© Will Briggs 2019Will BriggsC++ for Lazy Programmershttps://doi.org/10.1007/978-1-4842-5187-4_16
16. Classes (Continued)
Lynchburg, VA, USA
More things to make your classes work, and work well.
Consider the diagrams of what happens in function calls from Chapters 8 and 15. They show what the computer does. It creates a new copy of the function, an “activation record,” containing everything the instance of the function needs, especially local variables. It copies parameters into a part of memory the function can access. It stores what it needs to know about the function it was in (the state of the registers in the CPU – if you don't know what that is, don't worry about it). Finally, it transfers control ...