4 ms·
The change of the meaning of 'auto' already broke the old code. In C, 'auto' is used to specify a storage class; in C++, it stands for the type. So, the valid C
by Koshkin 9y ago
The change of the meaning of 'auto' already broke the old code. In C, 'auto' is used to specify a storage class; in C++, it stands for the type. So, the valid C code
auto float x;
when compiled with a C++ compiler, produces an error message.
- beojan 9y agoIf we're talking about actual C++ code, auto is a reserved keyword (so it wouldn't be used as an identifier) but it was useless, so it wouldn't be used as a keyword in any real (C++) code.
- TheCoelacanth 9y agoThat was virtually never used in the wild, though.