Use Find on Tuple instead Find on TypeList in components.hpp

This commit is contained in:
sha512sum 2024-03-24 21:12:03 +00:00
parent d972d5e4e1
commit 67e17431c8

View file

@ -262,7 +262,7 @@ struct ServiceContextBuilder {
static consteval auto FindComponent() { static consteval auto FindComponent() {
return []<typename... TTs, utempl::ConstexprString... names, Options... Options> return []<typename... TTs, utempl::ConstexprString... names, Options... Options>
(const ServiceContextBuilder<config, ComponentConfig<names, TTs, Options>...>&) (const ServiceContextBuilder<config, ComponentConfig<names, TTs, Options>...>&)
-> decltype(utempl::Get<Find<utempl::Wrapper<name>>(utempl::TypeList<utempl::Wrapper<names>...>{})>(utempl::TypeList<TTs...>{})) { -> decltype(utempl::Get<Find(utempl::Tuple{names...}, name)>(utempl::TypeList<TTs...>{})) {
std::unreachable(); std::unreachable();
}(ServiceContextBuilder<config, ComponentConfigs...>{}); }(ServiceContextBuilder<config, ComponentConfigs...>{});
}; };