MCPcopy Create free account
hub / github.com/Neargye/magic_enum / enum_values

Function enum_values

include/magic_enum/magic_enum.hpp:1246–1251  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1244// Returns std::array with enum values, sorted by enum value.
1245template <typename E, detail::enum_subtype S = detail::subtype_v<E>>
1246[[nodiscard]] constexpr auto enum_values() noexcept -> detail::enable_if_t<E, detail::values_t<E, S>> {
1247 using D = std::decay_t<E>;
1248 static_assert(detail::is_reflected_v<D, S>, "magic_enum requires enum implementation and valid max and min.");
1249
1250 return detail::values_v<D, S>;
1251}
1252
1253// Returns integer value from enum value.
1254template <typename E>

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected