diff --git a/CMakeLists.txt b/CMakeLists.txt index 597995e606..07ed954d9c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -38,6 +38,8 @@ option(ENTT_USE_LIBCPP "Use libc++ by adding -stdlib=libc++ flag if available." option(ENTT_USE_SANITIZER "Enable sanitizers by adding -fsanitize=address -fno-omit-frame-pointer -fsanitize=undefined flags if available." OFF) option(ENTT_USE_CLANG_TIDY "Enable static analysis with clang-tidy" OFF) +option(ENTT_MODULES "Build as a module library (requires c++20)" ON) + if(ENTT_USE_LIBCPP) if(NOT WIN32) include(CheckCXXSourceCompiles) @@ -224,6 +226,182 @@ if(ENTT_HAS_NATVIS) ) endif() +if(ENTT_MODULES) + +message(STATUS "Building with module support") + +add_library(EnTTModules) +add_library(EnTT::Module ALIAS EnTTModules) + +target_compile_features(EnTTModules PUBLIC cxx_std_20) + +if(ENTT_HAS_LIBCPP) + target_compile_options(EnTTModules BEFORE PUBLIC -stdlib=libc++) +endif() + +if(ENTT_HAS_SANITIZER) + target_compile_options(EnTTModules INTERFACE $<$:-fsanitize=address -fno-omit-frame-pointer -fsanitize=undefined>) + target_link_libraries(EnTTModules INTERFACE $<$:-fsanitize=address -fno-omit-frame-pointer -fsanitize=undefined>) +endif() + +target_sources(EnTTModules + PRIVATE FILE_SET CXX_MODULES + FILES + src/entt.cpp + + PRIVATE FILE_SET HEADERS + BASE_DIRS src + FILES + src/entt/config/config.h + src/entt/config/macro.h + src/entt/config/version.h + src/entt/container/dense_map.hpp + src/entt/container/dense_set.hpp + src/entt/container/table.hpp + src/entt/container/fwd.hpp + src/entt/core/algorithm.hpp + src/entt/core/any.hpp + src/entt/core/attribute.h + src/entt/core/bit.hpp + src/entt/core/compressed_pair.hpp + src/entt/core/enum.hpp + src/entt/core/family.hpp + src/entt/core/fwd.hpp + src/entt/core/hashed_string.hpp + src/entt/core/ident.hpp + src/entt/core/iterator.hpp + src/entt/core/memory.hpp + src/entt/core/monostate.hpp + src/entt/core/ranges.hpp + src/entt/core/tuple.hpp + src/entt/core/type_info.hpp + src/entt/core/type_traits.hpp + src/entt/core/utility.hpp + src/entt/entity/component.hpp + src/entt/entity/entity.hpp + src/entt/entity/fwd.hpp + src/entt/entity/group.hpp + src/entt/entity/handle.hpp + src/entt/entity/mixin.hpp + src/entt/entity/helper.hpp + src/entt/entity/organizer.hpp + src/entt/entity/ranges.hpp + src/entt/entity/registry.hpp + src/entt/entity/runtime_view.hpp + src/entt/entity/snapshot.hpp + src/entt/entity/sparse_set.hpp + src/entt/entity/storage.hpp + src/entt/entity/view.hpp + src/entt/graph/adjacency_matrix.hpp + src/entt/graph/dot.hpp + src/entt/graph/flow.hpp + src/entt/graph/fwd.hpp + src/entt/locator/locator.hpp + src/entt/meta/adl_pointer.hpp + src/entt/meta/container.hpp + src/entt/meta/context.hpp + src/entt/meta/factory.hpp + src/entt/meta/fwd.hpp + src/entt/meta/meta.hpp + src/entt/meta/node.hpp + src/entt/meta/pointer.hpp + src/entt/meta/policy.hpp + src/entt/meta/range.hpp + src/entt/meta/resolve.hpp + src/entt/meta/template.hpp + src/entt/meta/type_traits.hpp + src/entt/meta/utility.hpp + src/entt/poly/fwd.hpp + src/entt/poly/poly.hpp + src/entt/process/fwd.hpp + src/entt/process/process.hpp + src/entt/process/scheduler.hpp + src/entt/resource/cache.hpp + src/entt/resource/fwd.hpp + src/entt/resource/loader.hpp + src/entt/resource/resource.hpp + src/entt/signal/delegate.hpp + src/entt/signal/dispatcher.hpp + src/entt/signal/emitter.hpp + src/entt/signal/fwd.hpp + src/entt/signal/sigh.hpp + src/entt/entt.hpp + src/entt/fwd.hpp + + src/entt/container/dense_map.inc + src/entt/container/dense_set.inc + src/entt/container/table.inc + src/entt/container/fwd.inc + src/entt/core/algorithm.inc + src/entt/core/any.inc + src/entt/core/attribute.inc + src/entt/core/bit.inc + src/entt/core/compressed_pair.inc + src/entt/core/enum.inc + src/entt/core/family.inc + src/entt/core/fwd.inc + src/entt/core/hashed_string.inc + src/entt/core/ident.inc + src/entt/core/iterator.inc + src/entt/core/memory.inc + src/entt/core/monostate.inc + src/entt/core/ranges.inc + src/entt/core/tuple.inc + src/entt/core/type_info.inc + src/entt/core/type_traits.inc + src/entt/core/utility.inc + src/entt/entity/component.inc + src/entt/entity/entity.inc + src/entt/entity/fwd.inc + src/entt/entity/group.inc + src/entt/entity/handle.inc + src/entt/entity/mixin.inc + src/entt/entity/helper.inc + src/entt/entity/organizer.inc + src/entt/entity/ranges.inc + src/entt/entity/registry.inc + src/entt/entity/runtime_view.inc + src/entt/entity/snapshot.inc + src/entt/entity/sparse_set.inc + src/entt/entity/storage.inc + src/entt/entity/view.inc + src/entt/graph/adjacency_matrix.inc + src/entt/graph/dot.inc + src/entt/graph/flow.inc + src/entt/graph/fwd.inc + src/entt/locator/locator.inc + src/entt/meta/adl_pointer.inc + src/entt/meta/container.inc + src/entt/meta/context.inc + src/entt/meta/factory.inc + src/entt/meta/fwd.inc + src/entt/meta/meta.inc + src/entt/meta/node.inc + src/entt/meta/pointer.inc + src/entt/meta/policy.inc + src/entt/meta/range.inc + src/entt/meta/resolve.inc + src/entt/meta/template.inc + src/entt/meta/type_traits.inc + src/entt/meta/utility.inc + src/entt/poly/fwd.inc + src/entt/poly/poly.inc + src/entt/process/fwd.inc + src/entt/process/process.inc + src/entt/process/scheduler.inc + src/entt/resource/cache.inc + src/entt/resource/fwd.inc + src/entt/resource/loader.inc + src/entt/resource/resource.inc + src/entt/signal/delegate.inc + src/entt/signal/dispatcher.inc + src/entt/signal/emitter.inc + src/entt/signal/fwd.inc + src/entt/signal/sigh.inc +) + +endif() + # Install EnTT and all related files option(ENTT_INSTALL "Install EnTT and all related files." OFF) @@ -253,7 +431,7 @@ if(ENTT_INSTALL) include(CMakePackageConfigHelpers) install( - TARGETS EnTT + TARGETS EnTT EnTTModules EXPORT EnTTTargets ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} ) diff --git a/src/entt.cpp b/src/entt.cpp new file mode 100644 index 0000000000..69c2421c1a --- /dev/null +++ b/src/entt.cpp @@ -0,0 +1,79 @@ +module; + +#include + +export module entt; + +#include "entt/container/dense_map.inc" +#include "entt/container/dense_set.inc" +#include "entt/container/fwd.inc" +#include "entt/container/table.inc" +#include "entt/core/algorithm.inc" +#include "entt/core/any.inc" +#include "entt/core/attribute.inc" +#include "entt/core/bit.inc" +#include "entt/core/compressed_pair.inc" +#include "entt/core/enum.inc" +#include "entt/core/family.inc" +#include "entt/core/fwd.inc" +#include "entt/core/hashed_string.inc" +#include "entt/core/ident.inc" +#include "entt/core/iterator.inc" +#include "entt/core/memory.inc" +#include "entt/core/monostate.inc" +#include "entt/core/ranges.inc" +#include "entt/core/tuple.inc" +#include "entt/core/type_info.inc" +#include "entt/core/type_traits.inc" +#include "entt/core/utility.inc" +#include "entt/entity/component.inc" +#include "entt/entity/entity.inc" +#include "entt/entity/fwd.inc" +#include "entt/entity/group.inc" +#include "entt/entity/handle.inc" +#include "entt/entity/helper.inc" +#include "entt/entity/mixin.inc" +#include "entt/entity/organizer.inc" +#include "entt/entity/ranges.inc" +#include "entt/entity/registry.inc" +#include "entt/entity/runtime_view.inc" +#include "entt/entity/snapshot.inc" +#include "entt/entity/sparse_set.inc" +#include "entt/entity/storage.inc" +#include "entt/entity/view.inc" +#include "entt/graph/adjacency_matrix.inc" +#include "entt/graph/dot.inc" +#include "entt/graph/flow.inc" +#include "entt/graph/fwd.inc" +#include "entt/locator/locator.inc" +#include "entt/meta/adl_pointer.inc" +#include "entt/meta/container.inc" +#include "entt/meta/context.inc" +#include "entt/meta/factory.inc" +#include "entt/meta/fwd.inc" +#include "entt/meta/meta.inc" +#include "entt/meta/node.inc" +#include "entt/meta/pointer.inc" +#include "entt/meta/policy.inc" +#include "entt/meta/range.inc" +#include "entt/meta/resolve.inc" +#include "entt/meta/template.inc" +#include "entt/meta/type_traits.inc" +#include "entt/meta/utility.inc" +#include "entt/poly/fwd.inc" +#include "entt/poly/poly.inc" +#include "entt/process/fwd.inc" +#include "entt/process/process.inc" +#include "entt/process/scheduler.inc" +#include "entt/resource/cache.inc" +#include "entt/resource/fwd.inc" +#include "entt/resource/loader.inc" +#include "entt/resource/resource.inc" +#include "entt/signal/delegate.inc" +#include "entt/signal/dispatcher.inc" +#include "entt/signal/emitter.inc" +#include "entt/signal/fwd.inc" +#include "entt/signal/sigh.inc" + +#include "entt/operators.inc" +#include "entt/std.inc" \ No newline at end of file diff --git a/src/entt/container/dense_map.inc b/src/entt/container/dense_map.inc new file mode 100644 index 0000000000..ac46f75074 --- /dev/null +++ b/src/entt/container/dense_map.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::dense_map; +} // namespace entt diff --git a/src/entt/container/dense_set.inc b/src/entt/container/dense_set.inc new file mode 100644 index 0000000000..8387b683af --- /dev/null +++ b/src/entt/container/dense_set.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::dense_set; +} // namespace entt \ No newline at end of file diff --git a/src/entt/container/fwd.inc b/src/entt/container/fwd.inc new file mode 100644 index 0000000000..544c9982d5 --- /dev/null +++ b/src/entt/container/fwd.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::table; +} // namespace entt \ No newline at end of file diff --git a/src/entt/container/table.inc b/src/entt/container/table.inc new file mode 100644 index 0000000000..657a2b1c0f --- /dev/null +++ b/src/entt/container/table.inc @@ -0,0 +1,4 @@ +export namespace entt { +using ::entt::basic_table; +} // namespace entt + diff --git a/src/entt/core/algorithm.inc b/src/entt/core/algorithm.inc new file mode 100644 index 0000000000..ed20ff29f2 --- /dev/null +++ b/src/entt/core/algorithm.inc @@ -0,0 +1,5 @@ +export namespace entt { +using ::entt::std_sort; +using ::entt::insertion_sort; +using ::entt::radix_sort; +} // namespace entt diff --git a/src/entt/core/any.inc b/src/entt/core/any.inc new file mode 100644 index 0000000000..7739af4081 --- /dev/null +++ b/src/entt/core/any.inc @@ -0,0 +1,6 @@ +export namespace entt { +using ::entt::basic_any; +using ::entt::any_cast; +using ::entt::make_any; +using ::entt::forward_as_any; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/attribute.inc b/src/entt/core/attribute.inc new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/entt/core/bit.inc b/src/entt/core/bit.inc new file mode 100644 index 0000000000..da034fe769 --- /dev/null +++ b/src/entt/core/bit.inc @@ -0,0 +1,6 @@ +export namespace entt { +using ::entt::popcount; +using ::entt::has_single_bit; +using ::entt::next_power_of_two; +using ::entt::fast_mod; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/compressed_pair.inc b/src/entt/core/compressed_pair.inc new file mode 100644 index 0000000000..26ca499d94 --- /dev/null +++ b/src/entt/core/compressed_pair.inc @@ -0,0 +1,4 @@ +export namespace entt { +using ::entt::compressed_pair; +using ::entt::swap; +} // namespace entt diff --git a/src/entt/core/enum.inc b/src/entt/core/enum.inc new file mode 100644 index 0000000000..645381cb24 --- /dev/null +++ b/src/entt/core/enum.inc @@ -0,0 +1,4 @@ +export namespace entt { +using ::entt::enum_as_bitmask; +using ::entt::enum_as_bitmask_v; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/family.inc b/src/entt/core/family.inc new file mode 100644 index 0000000000..0bcd24b7b1 --- /dev/null +++ b/src/entt/core/family.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::family; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/fwd.inc b/src/entt/core/fwd.inc new file mode 100644 index 0000000000..87b5c212c7 --- /dev/null +++ b/src/entt/core/fwd.inc @@ -0,0 +1,7 @@ +export namespace entt { +using ::entt::any_policy; +using ::entt::id_type; +using ::entt::any; +using ::entt::hashed_string; +using ::entt::hashed_wstring; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/hashed_string.inc b/src/entt/core/hashed_string.inc new file mode 100644 index 0000000000..0cf98879fd --- /dev/null +++ b/src/entt/core/hashed_string.inc @@ -0,0 +1,9 @@ +export namespace entt { +using ::entt::basic_hashed_string; + +inline namespace literals { +using ::entt::literals::operator ""_hs; +using ::entt::literals::operator ""_hws; +} // namespace literals + +} \ No newline at end of file diff --git a/src/entt/core/ident.inc b/src/entt/core/ident.inc new file mode 100644 index 0000000000..2043136205 --- /dev/null +++ b/src/entt/core/ident.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::ident; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/iterator.inc b/src/entt/core/iterator.inc new file mode 100644 index 0000000000..2d48fc9ce8 --- /dev/null +++ b/src/entt/core/iterator.inc @@ -0,0 +1,7 @@ +export namespace entt { +using ::entt::input_iterator_pointer; +using ::entt::iota_iterator; +using ::entt::operator==; +using ::entt::operator!=; +using ::entt::iterable_adaptor; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/memory.inc b/src/entt/core/memory.inc new file mode 100644 index 0000000000..42dd583126 --- /dev/null +++ b/src/entt/core/memory.inc @@ -0,0 +1,11 @@ +export namespace entt { +using ::entt::to_address; +using ::entt::propagate_on_container_copy_assignment; +using ::entt::propagate_on_container_move_assignment; +using ::entt::propagate_on_container_swap; +using ::entt::allocation_deleter; +using ::entt::allocate_unique; +using ::entt::uses_allocator_construction_args; +using ::entt::make_obj_using_allocator; +using ::entt::uninitialized_construct_using_allocator; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/monostate.inc b/src/entt/core/monostate.inc new file mode 100644 index 0000000000..c3f3f86204 --- /dev/null +++ b/src/entt/core/monostate.inc @@ -0,0 +1,4 @@ +export namespace entt { +using ::entt::monostate; +using ::entt::monostate_v; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/ranges.inc b/src/entt/core/ranges.inc new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/entt/core/tuple.inc b/src/entt/core/tuple.inc new file mode 100644 index 0000000000..e1a75d4211 --- /dev/null +++ b/src/entt/core/tuple.inc @@ -0,0 +1,6 @@ +export namespace entt { +using ::entt::is_tuple; +using ::entt::is_tuple_v; +using ::entt::unwrap_tuple; +using ::entt::forward_apply; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/type_info.inc b/src/entt/core/type_info.inc new file mode 100644 index 0000000000..7720e8da93 --- /dev/null +++ b/src/entt/core/type_info.inc @@ -0,0 +1,7 @@ +export namespace entt { +using ::entt::type_index; +using ::entt::type_hash; +using ::entt::type_name; +using ::entt::type_info; +using ::entt::type_id; +} // namespace entt \ No newline at end of file diff --git a/src/entt/core/type_traits.inc b/src/entt/core/type_traits.inc new file mode 100644 index 0000000000..84d2d32c5f --- /dev/null +++ b/src/entt/core/type_traits.inc @@ -0,0 +1,60 @@ +export namespace entt { +using ::entt::choice; +using ::entt::choice_t; +using ::entt::type_identity; +using ::entt::type_identity_t; +using ::entt::size_of; +using ::entt::size_of_v; +using ::entt::unpack_as_type; +using ::entt::unpack_as_value; +using ::entt::integral_constant; +using ::entt::tag; +using ::entt::type_list; +using ::entt::type_list_element; +using ::entt::type_list_element_t; +using ::entt::type_list_index; +using ::entt::type_list_index_v; +using ::entt::type_list_cat; +using ::entt::type_list_cat_t; +using ::entt::type_list_unique; +using ::entt::type_list_unique_t; +using ::entt::type_list_contains; +using ::entt::type_list_contains_v; +using ::entt::type_list_diff; +using ::entt::type_list_diff_t; +using ::entt::type_list_transform; +using ::entt::type_list_transform_t; +using ::entt::value_list; +using ::entt::value_list_element; +using ::entt::value_list_element_t; +using ::entt::value_list_index; +using ::entt::value_list_index_v; +using ::entt::value_list_cat; +using ::entt::value_list_cat_t; +using ::entt::value_list_unique; +using ::entt::value_list_unique_t; +using ::entt::value_list_contains; +using ::entt::value_list_contains_v; +using ::entt::value_list_diff; +using ::entt::value_list_diff_t; +using ::entt::is_applicable; +using ::entt::is_applicable_v; +using ::entt::is_applicable_r; +using ::entt::is_applicable_r_v; +using ::entt::is_complete; +using ::entt::is_complete_v; +using ::entt::is_iterator; +using ::entt::is_iterator_v; +using ::entt::is_ebco_eligible; +using ::entt::is_ebco_eligible_v; +using ::entt::is_transparent; +using ::entt::is_transparent_v; +using ::entt::is_equality_comparable; +using ::entt::is_equality_comparable_v; +using ::entt::constness_as; +using ::entt::constness_as_t; +using ::entt::member_class; +using ::entt::member_class_t; +using ::entt::nth_argument; +using ::entt::nth_argument_t; +} // namespace entt diff --git a/src/entt/core/utility.inc b/src/entt/core/utility.inc new file mode 100644 index 0000000000..9684153246 --- /dev/null +++ b/src/entt/core/utility.inc @@ -0,0 +1,6 @@ +export namespace entt { +using ::entt::identity; +using ::entt::overload; +using ::entt::overloaded; +using ::entt::y_combinator; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/component.inc b/src/entt/entity/component.inc new file mode 100644 index 0000000000..0d01f6a0b6 --- /dev/null +++ b/src/entt/entity/component.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::component_traits; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/entity.inc b/src/entt/entity/entity.inc new file mode 100644 index 0000000000..2ab85fbac8 --- /dev/null +++ b/src/entt/entity/entity.inc @@ -0,0 +1,14 @@ +export namespace entt { +using ::entt::basic_entt_traits; +using ::entt::to_entity; +using ::entt::to_integral; +using ::entt::to_version; + +using ::entt::null_t; +using ::entt::tombstone_t; + +using ::entt::null; +using ::entt::tombstone; + +using ::entt::operator==; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/fwd.inc b/src/entt/entity/fwd.inc new file mode 100644 index 0000000000..3a9178a6d5 --- /dev/null +++ b/src/entt/entity/fwd.inc @@ -0,0 +1,32 @@ +export namespace entt { +using ::entt::entity; +using ::entt::deletion_policy; + +using ::entt::sparse_set; +using ::entt::storage; +using ::entt::sigh_mixin; +using ::entt::reactive_mixin; +using ::entt::registry; +using ::entt::organizer; +using ::entt::handle; +using ::entt::const_handle; +using ::entt::handle_view; +using ::entt::const_handle_view; +using ::entt::snapshot; +using ::entt::snapshot_loader; +using ::entt::continuous_loader; +using ::entt::runtime_view; +using ::entt::const_runtime_view; +using ::entt::exclude_t; +using ::entt::exclude; +using ::entt::get_t; +using ::entt::owned_t; +using ::entt::type_list_transform; +using ::entt::storage_type; +using ::entt::reactive; +using ::entt::storage_type_t; +using ::entt::storage_for; +using ::entt::storage_for_t; +using ::entt::view; +using ::entt::group; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/group.inc b/src/entt/entity/group.inc new file mode 100644 index 0000000000..e819eeaef2 --- /dev/null +++ b/src/entt/entity/group.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_group; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/handle.inc b/src/entt/entity/handle.inc new file mode 100644 index 0000000000..7e35f9bcec --- /dev/null +++ b/src/entt/entity/handle.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_handle; +} // namespace entt diff --git a/src/entt/entity/helper.inc b/src/entt/entity/helper.inc new file mode 100644 index 0000000000..4cf6bc4291 --- /dev/null +++ b/src/entt/entity/helper.inc @@ -0,0 +1,7 @@ +export namespace entt { +using ::entt::as_view; +using ::entt::as_group; +using ::entt::invoke; +using ::entt::to_entity; +using ::entt::sigh_helper; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/mixin.inc b/src/entt/entity/mixin.inc new file mode 100644 index 0000000000..83411bcd98 --- /dev/null +++ b/src/entt/entity/mixin.inc @@ -0,0 +1,4 @@ +export namespace entt { +using ::entt::basic_sigh_mixin; +using ::entt::basic_reactive_mixin; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/organizer.inc b/src/entt/entity/organizer.inc new file mode 100644 index 0000000000..65873de6da --- /dev/null +++ b/src/entt/entity/organizer.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_organizer; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/ranges.inc b/src/entt/entity/ranges.inc new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/entt/entity/registry.inc b/src/entt/entity/registry.inc new file mode 100644 index 0000000000..24c7907a24 --- /dev/null +++ b/src/entt/entity/registry.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_registry; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/runtime_view.inc b/src/entt/entity/runtime_view.inc new file mode 100644 index 0000000000..9e457a257a --- /dev/null +++ b/src/entt/entity/runtime_view.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_runtime_view; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/snapshot.inc b/src/entt/entity/snapshot.inc new file mode 100644 index 0000000000..db010dd9c8 --- /dev/null +++ b/src/entt/entity/snapshot.inc @@ -0,0 +1,5 @@ +export namespace entt { +using ::entt::basic_snapshot; +using ::entt::basic_snapshot_loader; +using ::entt::basic_continuous_loader; +} // namespace entt diff --git a/src/entt/entity/sparse_set.inc b/src/entt/entity/sparse_set.inc new file mode 100644 index 0000000000..87b7df998a --- /dev/null +++ b/src/entt/entity/sparse_set.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_sparse_set; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/storage.inc b/src/entt/entity/storage.inc new file mode 100644 index 0000000000..372b3cb7c1 --- /dev/null +++ b/src/entt/entity/storage.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_storage; +} // namespace entt \ No newline at end of file diff --git a/src/entt/entity/view.inc b/src/entt/entity/view.inc new file mode 100644 index 0000000000..204b621ce8 --- /dev/null +++ b/src/entt/entity/view.inc @@ -0,0 +1,5 @@ +export namespace entt { +using ::entt::basic_common_view; +using ::entt::basic_view; +using ::entt::basic_storage_view; +} // namespace entt \ No newline at end of file diff --git a/src/entt/graph/adjacency_matrix.inc b/src/entt/graph/adjacency_matrix.inc new file mode 100644 index 0000000000..3db22b1071 --- /dev/null +++ b/src/entt/graph/adjacency_matrix.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::adjacency_matrix; +} // namespace entt \ No newline at end of file diff --git a/src/entt/graph/dot.inc b/src/entt/graph/dot.inc new file mode 100644 index 0000000000..15c6b63c0e --- /dev/null +++ b/src/entt/graph/dot.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::dot; +} // namespace entt \ No newline at end of file diff --git a/src/entt/graph/flow.inc b/src/entt/graph/flow.inc new file mode 100644 index 0000000000..17436f63e8 --- /dev/null +++ b/src/entt/graph/flow.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_flow; +} // namespace entt \ No newline at end of file diff --git a/src/entt/graph/fwd.inc b/src/entt/graph/fwd.inc new file mode 100644 index 0000000000..44e9b52247 --- /dev/null +++ b/src/entt/graph/fwd.inc @@ -0,0 +1,5 @@ +export namespace entt { +using ::entt::directed_tag; +using ::entt::undirected_tag; +using ::entt::flow; +} // namespace entt \ No newline at end of file diff --git a/src/entt/locator/locator.inc b/src/entt/locator/locator.inc new file mode 100644 index 0000000000..41d15a9cfa --- /dev/null +++ b/src/entt/locator/locator.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::locator; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/adl_pointer.inc b/src/entt/meta/adl_pointer.inc new file mode 100644 index 0000000000..06b23fbd5f --- /dev/null +++ b/src/entt/meta/adl_pointer.inc @@ -0,0 +1,4 @@ +export namespace entt { +using ::entt::dereference_meta_pointer_like; +using ::entt::adl_meta_pointer_like; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/container.inc b/src/entt/meta/container.inc new file mode 100644 index 0000000000..96949f1171 --- /dev/null +++ b/src/entt/meta/container.inc @@ -0,0 +1,6 @@ +export namespace entt { +using ::entt::basic_meta_sequence_container_traits; +using ::entt::basic_meta_associative_container_traits; +using ::entt::meta_sequence_container_traits; +using ::entt::meta_associative_container_traits; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/context.inc b/src/entt/meta/context.inc new file mode 100644 index 0000000000..ea8531a4c0 --- /dev/null +++ b/src/entt/meta/context.inc @@ -0,0 +1,5 @@ +export namespace entt { +using ::entt::meta_ctx; +using ::entt::meta_ctx_arg_t; +using ::entt::meta_ctx_arg; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/factory.inc b/src/entt/meta/factory.inc new file mode 100644 index 0000000000..926f8824c6 --- /dev/null +++ b/src/entt/meta/factory.inc @@ -0,0 +1,5 @@ +export namespace entt { +using ::entt::meta_factory; +using ::entt::meta; +using ::entt::meta_reset; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/fwd.inc b/src/entt/meta/fwd.inc new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/entt/meta/meta.inc b/src/entt/meta/meta.inc new file mode 100644 index 0000000000..043a8449d2 --- /dev/null +++ b/src/entt/meta/meta.inc @@ -0,0 +1,13 @@ +export namespace entt { +using ::entt::meta_any; +using ::entt::meta_type; +using ::entt::meta_sequence_container; +using ::entt::meta_associative_container; +using ::entt::meta_any_policy; +using ::entt::forward_as_meta; +using ::entt::meta_handle; +using ::entt::meta_custom; +using ::entt::meta_data; +using ::entt::meta_func; +using ::entt::meta_type; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/node.inc b/src/entt/meta/node.inc new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/entt/meta/pointer.inc b/src/entt/meta/pointer.inc new file mode 100644 index 0000000000..d9be4df773 --- /dev/null +++ b/src/entt/meta/pointer.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::is_meta_pointer_like; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/policy.inc b/src/entt/meta/policy.inc new file mode 100644 index 0000000000..23160e8777 --- /dev/null +++ b/src/entt/meta/policy.inc @@ -0,0 +1,8 @@ +export namespace entt { +using ::entt::as_ref_t; +using ::entt::as_cref_t; +using ::entt::as_is_t; +using ::entt::as_void_t; +using ::entt::is_meta_policy; +using ::entt::is_meta_policy_v; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/range.inc b/src/entt/meta/range.inc new file mode 100644 index 0000000000..ce9a57f5a3 --- /dev/null +++ b/src/entt/meta/range.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::meta_range; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/resolve.inc b/src/entt/meta/resolve.inc new file mode 100644 index 0000000000..203ee2d104 --- /dev/null +++ b/src/entt/meta/resolve.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::resolve; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/template.inc b/src/entt/meta/template.inc new file mode 100644 index 0000000000..b877da3fc8 --- /dev/null +++ b/src/entt/meta/template.inc @@ -0,0 +1,4 @@ +export namespace entt { +using ::entt::meta_class_template_tag; +using ::entt::meta_template_traits; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/type_traits.inc b/src/entt/meta/type_traits.inc new file mode 100644 index 0000000000..9aed315767 --- /dev/null +++ b/src/entt/meta/type_traits.inc @@ -0,0 +1,6 @@ +export namespace entt { +using ::entt::meta_template_traits; +using ::entt::meta_sequence_container_traits; +using ::entt::meta_associative_container_traits; +using ::entt::is_meta_pointer_like; +} // namespace entt \ No newline at end of file diff --git a/src/entt/meta/utility.inc b/src/entt/meta/utility.inc new file mode 100644 index 0000000000..ccef36039b --- /dev/null +++ b/src/entt/meta/utility.inc @@ -0,0 +1,15 @@ +export namespace entt { +using ::entt::meta_function_descriptor_traits; +using ::entt::meta_function_descriptor; +using ::entt::meta_function_helper; +using ::entt::meta_function_helper_t; +using ::entt::meta_dispatch; + +// TODO: I cannot export ::entt::meta_args because the function is declared as static. Is this a problem? +// error: using declaration referring to 'meta_arg' with internal linkage cannot be exported +// using ::entt::meta_arg; +using ::entt::meta_setter; +using ::entt::meta_getter; +using ::entt::meta_invoke; +using ::entt::meta_construct; +} // namespace entt \ No newline at end of file diff --git a/src/entt/operators.inc b/src/entt/operators.inc new file mode 100644 index 0000000000..ae09c74f5b --- /dev/null +++ b/src/entt/operators.inc @@ -0,0 +1,23 @@ +export namespace entt { +using ::entt::operator==; +using ::entt::operator!=; +using ::entt::operator<; +using ::entt::operator<=; +using ::entt::operator>; +using ::entt::operator>=; + +using ::entt::operator+; +} // namespace entt + +// global operators +export { + // from entt/core/enum.h + using ::operator|; + using ::operator&; + using ::operator^; + using ::operator~; + using ::operator!; + using ::operator|=; + using ::operator&=; + using ::operator^=; +} diff --git a/src/entt/poly/fwd.inc b/src/entt/poly/fwd.inc new file mode 100644 index 0000000000..b65dedc76d --- /dev/null +++ b/src/entt/poly/fwd.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::poly; +} // namespace entt \ No newline at end of file diff --git a/src/entt/poly/poly.inc b/src/entt/poly/poly.inc new file mode 100644 index 0000000000..d9fdbbabf0 --- /dev/null +++ b/src/entt/poly/poly.inc @@ -0,0 +1,7 @@ +export namespace entt { +using ::entt::poly_inspector; +using ::entt::poly_vtable; +using ::entt::poly_base; +using ::entt::poly_call; +using ::entt::basic_poly; +} // namespace entt \ No newline at end of file diff --git a/src/entt/process/fwd.inc b/src/entt/process/fwd.inc new file mode 100644 index 0000000000..549b567573 --- /dev/null +++ b/src/entt/process/fwd.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::scheduler; +} // namespace entt \ No newline at end of file diff --git a/src/entt/process/process.inc b/src/entt/process/process.inc new file mode 100644 index 0000000000..87d24521bb --- /dev/null +++ b/src/entt/process/process.inc @@ -0,0 +1,4 @@ +export namespace entt { +using ::entt::process; +using ::entt::process_adaptor; +} \ No newline at end of file diff --git a/src/entt/process/scheduler.inc b/src/entt/process/scheduler.inc new file mode 100644 index 0000000000..9ab0347c96 --- /dev/null +++ b/src/entt/process/scheduler.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_scheduler; +} \ No newline at end of file diff --git a/src/entt/resource/cache.inc b/src/entt/resource/cache.inc new file mode 100644 index 0000000000..aa428d205c --- /dev/null +++ b/src/entt/resource/cache.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::resource_cache; +} // namespace entt \ No newline at end of file diff --git a/src/entt/resource/fwd.inc b/src/entt/resource/fwd.inc new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/entt/resource/loader.inc b/src/entt/resource/loader.inc new file mode 100644 index 0000000000..1dbae60140 --- /dev/null +++ b/src/entt/resource/loader.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::resource_loader; +} // namespace entt \ No newline at end of file diff --git a/src/entt/resource/resource.inc b/src/entt/resource/resource.inc new file mode 100644 index 0000000000..f455f58a6c --- /dev/null +++ b/src/entt/resource/resource.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::resource; +} // namespace entt \ No newline at end of file diff --git a/src/entt/signal/delegate.inc b/src/entt/signal/delegate.inc new file mode 100644 index 0000000000..773bf32f6d --- /dev/null +++ b/src/entt/signal/delegate.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::delegate; +} // namespace entt \ No newline at end of file diff --git a/src/entt/signal/dispatcher.inc b/src/entt/signal/dispatcher.inc new file mode 100644 index 0000000000..dfc8d78f37 --- /dev/null +++ b/src/entt/signal/dispatcher.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::basic_dispatcher; +} // namespace entt \ No newline at end of file diff --git a/src/entt/signal/emitter.inc b/src/entt/signal/emitter.inc new file mode 100644 index 0000000000..ec3030ae3f --- /dev/null +++ b/src/entt/signal/emitter.inc @@ -0,0 +1,3 @@ +export namespace entt { +using ::entt::emitter; +} // namespace entt \ No newline at end of file diff --git a/src/entt/signal/fwd.inc b/src/entt/signal/fwd.inc new file mode 100644 index 0000000000..d96f5bc39c --- /dev/null +++ b/src/entt/signal/fwd.inc @@ -0,0 +1,5 @@ +export namespace entt { +using ::entt::dispatcher; +using ::entt::connect_arg_t; +using ::entt::connect_arg; +} // namespace entt \ No newline at end of file diff --git a/src/entt/signal/sigh.inc b/src/entt/signal/sigh.inc new file mode 100644 index 0000000000..1abd7bc22a --- /dev/null +++ b/src/entt/signal/sigh.inc @@ -0,0 +1,6 @@ +export namespace entt { +using ::entt::sink; +using ::entt::sigh; +using ::entt::connection; +using ::entt::scoped_connection; +} // namespace entt \ No newline at end of file diff --git a/src/entt/std.inc b/src/entt/std.inc new file mode 100644 index 0000000000..87fa3d59c3 --- /dev/null +++ b/src/entt/std.inc @@ -0,0 +1,12 @@ +// TODO: to export or not to export, if it was c++23 that would be easier to say +export namespace std { +using std::tuple_element; +using std::tuple_size; +using std::uses_allocator; + +namespace ranges { +using std::ranges::enable_borrowed_range; +using std::ranges::enable_view; +} // namespace ranges + +} // namespace std \ No newline at end of file