a_module.cpp 785 B

12345678910111213141516171819202122232425262728293031323334
  1. #include <entt/entity/registry.hpp>
  2. #ifndef LIB_EXPORT
  3. #if defined _WIN32 || defined __CYGWIN__
  4. #define LIB_EXPORT __declspec(dllexport)
  5. #elif defined __GNUC__
  6. #define LIB_EXPORT __attribute__((visibility("default")))
  7. #else
  8. #define LIB_EXPORT
  9. #endif
  10. #endif
  11. ENTT_SHARED_TYPE(int);
  12. ENTT_SHARED_TYPE(char);
  13. ENTT_SHARED_TYPE(double);
  14. ENTT_SHARED_TYPE(float);
  15. LIB_EXPORT typename entt::registry<>::component_type a_module_int_type() {
  16. entt::registry<> registry;
  17. (void)registry.type<double>();
  18. (void)registry.type<float>();
  19. return registry.type<int>();
  20. }
  21. LIB_EXPORT typename entt::registry<>::component_type a_module_char_type() {
  22. entt::registry<> registry;
  23. (void)registry.type<double>();
  24. (void)registry.type<float>();
  25. return registry.type<char>();
  26. }