Removed C++14 only feature from variant

This commit is contained in:
John Wellbelove 2023-06-14 08:19:08 +01:00
parent 308eb5590e
commit 81cd2df218

View File

@ -1126,7 +1126,7 @@ namespace etl
// Workaround for MSVC (2023/05/13)
// It doesn't compile 'visitor.visit(etl::get<Index>(*this))' correctly for C++17 & C++20.
// Changed all of the instances for consistancy.
decltype(auto) v = etl::get<Index>(*this);
auto& v = etl::get<Index>(*this);
visitor.visit(v);
return true;
}
@ -1147,7 +1147,7 @@ namespace etl
// Workaround for MSVC (2023/05/13)
// It doesn't compile 'visitor.visit(etl::get<Index>(*this))' correctly for C++17 & C++20.
// Changed all of the instances for consistancy.
decltype(auto) v = etl::get<Index>(*this);
//decltype(auto) v = etl::get<Index>(*this);
visitor.visit(v);
return true;
}
@ -1313,7 +1313,7 @@ namespace etl
{
if (Index == index())
{
decltype(auto) v = etl::get<Index>(*this);
auto& v = etl::get<Index>(*this);
visitor(v);
return true;
}
@ -1331,7 +1331,7 @@ namespace etl
{
if (Index == index())
{
decltype(auto) v = etl::get<Index>(*this);
auto& v = etl::get<Index>(*this);
visitor(v);
return true;
}