Use constexpr in the conditions with template parameters and sizeofs to suppress C4127 warnings.

This commit is contained in:
bruvzg
2022-09-29 09:18:07 +03:00
parent f8745f2f71
commit ea1848ce0a
15 changed files with 76 additions and 76 deletions

View File

@ -548,7 +548,7 @@ void FileAccess::store_64(uint64_t p_dest) {
}
void FileAccess::store_real(real_t p_real) {
if (sizeof(real_t) == 4) {
if constexpr (sizeof(real_t) == 4) {
store_float(p_real);
} else {
store_double(p_real);