view: avoid unnecessary parameter pack

This commit is contained in:
Michele Caini
2022-04-04 12:27:28 +02:00
parent 976413173a
commit 88db623dc1
+2 -2
View File
@@ -577,9 +577,9 @@ public:
* @tparam Comp Type of component of which to return the storage.
* @return The storage for the given component type.
*/
template<typename... Comp>
template<typename Comp = Component>
[[nodiscard]] decltype(auto) storage() const ENTT_NOEXCEPT {
static_assert((std::is_same_v<Comp, Component> && ...), "Invalid component type");
static_assert(std::is_same_v<Comp, Component>, "Invalid component type");
return *std::get<0>(pools);
}