test: add default constructor for a const value
This fixed a compilation error of the OS X 10.11.6 C++ compiler: ./fmt/test/format-test.cc:1861:16: error: default initialization of an object of const type 'const Answer' without a user-provided default constructor const Answer const_answer; ^ {}
This commit is contained in:
parent
5420bcce2d
commit
78842ce0d6
@ -1917,7 +1917,7 @@ TEST(FormatTest, CustomFormatCompileTimeString) {
|
||||
EXPECT_EQ("42", fmt::format(FMT_STRING("{}"), Answer()));
|
||||
Answer answer;
|
||||
EXPECT_EQ("42", fmt::format(FMT_STRING("{}"), answer));
|
||||
const Answer const_answer;
|
||||
const Answer const_answer = Answer();
|
||||
EXPECT_EQ("42", fmt::format(FMT_STRING("{}"), const_answer));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user