Skip to content

Commit 919866d

Browse files
author
Victor Hugo Vianna Silva
committed
cpp23: Mute float_denorm_style deprecation warning
It's deprecated in C++23 and causes -Wdeprecated-declarations. https://en.cppreference.com/w/cpp/types/numeric_limits/float_denorm_style.html Bug: crbug.com/388070065
1 parent c082f2b commit 919866d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

framework/common/tcuFloatFormat.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,11 +272,14 @@ static FloatFormat nativeFormat(void)
272272
return FloatFormat(Limits::min_exponent - 1, // These have a built-in offset of one
273273
Limits::max_exponent - 1,
274274
Limits::digits - 1, // don't count the hidden bit
275+
#pragma clang diagnostic push
276+
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
275277
Limits::has_denorm != std::denorm_absent, Limits::has_infinity ? YES : NO,
276278
Limits::has_quiet_NaN ? YES : NO,
277279
((Limits::has_denorm == std::denorm_present) ? YES :
278280
(Limits::has_denorm == std::denorm_absent) ? NO :
279281
MAYBE));
282+
#pragma clang diagnostic pop
280283
}
281284

282285
FloatFormat FloatFormat::nativeFloat(void)

0 commit comments

Comments
 (0)