workaround of an bug of gcc-7

This commit is contained in:
Michele Caini
2020-01-11 21:56:08 +01:00
parent 7ba14f5a57
commit 2fc6fe442d

View File

@@ -746,7 +746,7 @@ public:
template<typename... Component>
void remove_if_exists(const entity_type entity) {
ENTT_ASSERT(valid(entity));
([this, entity]() { if(auto &cpool = assure<Component>(); cpool.has(entity)) { cpool.remove(*this, entity); } }(), ...);
([this, entity](auto &&cpool) { if(cpool.has(entity)) { cpool.remove(*this, entity); } }(assure<Component>()), ...);
}
/**