check -> const_check to avoid a conflict with AssertMacros.h (#350)

(cherry picked from commit 8631694021)
This commit is contained in:
Victor Zverovich authored and Jonathan Müller committed 2016-10-23 11:52:49 +02:00
1 parent 27f604a153
commit 3f778b2099
3 files changed
+16 -15

No files matched your search

+2 -2
View File
@@ -933,7 +933,7 @@ TEST(FormatterTest, RuntimeWidth) {
FormatError, "number is too big");
EXPECT_THROW_MSG(format("{0:{1}}", 0, -1l),
FormatError, "negative width");
if (fmt::internal::check(sizeof(long) > sizeof(int))) {
if (fmt::internal::const_check(sizeof(long) > sizeof(int))) {
long value = INT_MAX;
EXPECT_THROW_MSG(format("{0:{1}}", 0, (value + 1)),
FormatError, "number is too big");
@@ -1052,7 +1052,7 @@ TEST(FormatterTest, RuntimePrecision) {
FormatError, "number is too big");
EXPECT_THROW_MSG(format("{0:.{1}}", 0, -1l),
FormatError, "negative precision");
if (fmt::internal::check(sizeof(long) > sizeof(int))) {
if (fmt::internal::const_check(sizeof(long) > sizeof(int))) {
long value = INT_MAX;
EXPECT_THROW_MSG(format("{0:.{1}}", 0, (value + 1)),
FormatError, "number is too big");