diff --git a/src/osp/core/copymove_macros.h b/src/osp/core/copymove_macros.h index 488256ef..16b18abd 100644 --- a/src/osp/core/copymove_macros.h +++ b/src/osp/core/copymove_macros.h @@ -24,14 +24,6 @@ */ #pragma once -//#define OSP_AUX_MOVECOPY_CTOR(type, copy_is, move_is, move_constexpr, copy_constexpr, opt_noexcept) \ -// copy_constexpr type(type const& copy) opt_noexcept = copy_is; \ -// move_constexpr type(type&& move) opt_noexcept = move_is; - -//#define OSP_AUX_MOVECOPY_ASGN(type, copy_is, move_is, move_constexpr, copy_constexpr, opt_noexcept) \ -// copy_constexpr type& operator=(type const& copy) opt_noexcept = copy_is; \ -// move_constexpr type& operator=(type&& move) opt_noexcept = move_is; - #define OSP_MOVE_COPY_CTOR_ASSIGN(type) \ Type (Type const& copy) = default; \ Type (Type&& move) = default; \ diff --git a/src/osp/core/strong_id.h b/src/osp/core/strong_id.h index b3eaca13..954ee4a1 100644 --- a/src/osp/core/strong_id.h +++ b/src/osp/core/strong_id.h @@ -48,12 +48,13 @@ struct StrongId using entity_type = INT_T; // Name used for entt compatibility constexpr StrongId() noexcept = default; + constexpr StrongId(StrongId const& copy) noexcept + : m_value{copy.m_value} + { }; constexpr explicit StrongId(INT_T const value) noexcept : m_value{value} { }; - OSP_MOVE_COPY_CTOR_ASSIGN_CONSTEXPR_NOEXCEPT(StrongId); - constexpr explicit operator std::size_t() const noexcept { return m_value; diff --git a/src/osp/drawing/draw_ent.h b/src/osp/drawing/draw_ent.h index 6ddfa9ca..1b9e8b01 100644 --- a/src/osp/drawing/draw_ent.h +++ b/src/osp/drawing/draw_ent.h @@ -31,4 +31,6 @@ namespace osp::draw using DrawEnt = StrongId; +using MaterialId = StrongId; + } // namespace osp::draw diff --git a/src/osp/drawing/drawing.h b/src/osp/drawing/drawing.h index edda56b5..bc70702b 100644 --- a/src/osp/drawing/drawing.h +++ b/src/osp/drawing/drawing.h @@ -48,8 +48,6 @@ namespace osp::draw using DrawEntVec_t = std::vector; using DrawEntSet_t = BitVector_t; -enum class MaterialId : uint32_t { }; - struct Material { DrawEntSet_t m_ents; diff --git a/src/testapp/sessions/misc.cpp b/src/testapp/sessions/misc.cpp index 834d0781..2de5aeb9 100644 --- a/src/testapp/sessions/misc.cpp +++ b/src/testapp/sessions/misc.cpp @@ -57,7 +57,6 @@ void create_materials( for (int i = 0; i < count; ++i) { [[maybe_unused]] MaterialId const mat = rScnRender.m_materialIds.create(); - LGRN_ASSERT(int(mat) == i); } rScnRender.m_materials.resize(count);