what does "#pragma once"
mean?
what does "#pragma once"
mean?
It makes sure a header file is only included once per file. If header files are included more than once in the same file, you will get a bunch of errors. I believe it's MS specific though, so I don't think it is the recommended method for ensuring header files are only included once. Use #ifndef--#endif inclusion guards instead.
All the preprocessor directives have a standard usage in the standard - like #define, #include, etc... but #pragma is set aside to be used by your implemenation for any miscellaneous purpose - so if you ever need to know the meaning of a line beginning with #pragma, the place to look is your compiler documentation. In this case, Microsoft.