Skip to content

Commit 5ada2ae

Browse files
committed
Resolved warning C4127: conditional expression is constant
1 parent 028bffa commit 5ada2ae

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

include/fmt/ranges.h

+2-1
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,8 @@ struct formatter<
528528

529529
public:
530530
FMT_CONSTEXPR formatter() {
531-
if (range_format_kind<R, Char>::value != range_format::set) return;
531+
if (const_check(range_format_kind<R, Char>::value != range_format::set))
532+
return;
532533
range_formatter_.set_brackets(detail::string_literal<Char, '{'>{},
533534
detail::string_literal<Char, '}'>{});
534535
}

0 commit comments

Comments
 (0)