chore: Less verbose name for enum underlying type casts (#1494)

* Less verbose name for enum underlying type casts

* Remove redundant call
This commit is contained in:
jadebenn
2024-03-06 23:45:04 -06:00
committed by GitHub
parent fe4b29f643
commit 6e3b5acede
4 changed files with 7 additions and 7 deletions

View File

@@ -264,8 +264,8 @@ namespace GeneralUtils {
* @returns The enum entry's value in its underlying type
*/
template <Enum eType>
constexpr typename std::underlying_type_t<eType> CastUnderlyingType(const eType entry) noexcept {
return static_cast<typename std::underlying_type_t<eType>>(entry);
constexpr std::underlying_type_t<eType> ToUnderlying(const eType entry) noexcept {
return static_cast<std::underlying_type_t<eType>>(entry);
}
// on Windows we need to undef these or else they conflict with our numeric limits calls