Quantcast
Channel: User HolyBlackCat - Stack Overflow
Viewing all articles
Browse latest Browse all 1306

Answer by HolyBlackCat for Does "automatic storage" now include registers?

$
0
0

The C++ standard doesn't describe registers. The compiler can put whatever it wants in them, but it must do so transparently.

I just want to use the correct term when I talk to my colleagues

The right term is in the header of your quote, "automatic variables". Or perhaps "local variables".

"Stack variables" would also be often understood to include all automatic variables, both in registers and in the actual stack. But this term is prone to "C++ has no stack" nitpicks, as the standard doesn't call it the stack either.

I clarified by specifying Windows with MSVC.

Honestly, I don't see what this changes regarding the choice of terms. If you don't discuss specific generated code/assembly, you normally use abstract terms defined in the standard, so you don't concern yourself with registers.


Viewing all articles
Browse latest Browse all 1306

Trending Articles