globals.cpp 910 B

1234567891011121314151617181920
  1. //-------------------------------------------------------------------------------------------------------
  2. // Copyright (C) Microsoft. All rights reserved.
  3. // Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. //-------------------------------------------------------------------------------------------------------
  5. #include "ParserPch.h"
  6. // strings for builtin names
  7. #define HASH_NAME(name, hashCS, hashCI) \
  8. const StaticSymLen<sizeof(#name)> g_ssym_##name = \
  9. { \
  10. hashCS, \
  11. sizeof(#name) - 1, \
  12. _u(#name) \
  13. }; \
  14. C_ASSERT(offsetof(StaticSymLen<sizeof(#name)>, luHash) == offsetof(StaticSym, luHash)); \
  15. C_ASSERT(offsetof(StaticSymLen<sizeof(#name)>, cch) == offsetof(StaticSym, cch)); \
  16. C_ASSERT(offsetof(StaticSymLen<sizeof(#name)>, sz) == offsetof(StaticSym, sz)); \
  17. #include "objnames.h"
  18. #undef HASH_NAME