mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-26 09:28:21 +00:00
Fix MSVC build.
This commit is contained in:
parent
cbaddefddd
commit
fcf476bb02
@ -718,6 +718,10 @@ TEST(ActiveFormatterTest, ActionNotCalledOnError) {
|
|||||||
EXPECT_EQ(0, num_calls);
|
EXPECT_EQ(0, num_calls);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// The test doesn't compile on MSVC because the latter follows C++03 and
|
||||||
|
// requires an accessible copy ctor when binding a temporary to a const
|
||||||
|
// reference.
|
||||||
|
#ifndef _MSC_VER
|
||||||
TEST(ActiveFormatterTest, ArgLifetime) {
|
TEST(ActiveFormatterTest, ArgLifetime) {
|
||||||
// The following code is for testing purposes only. It is a definite abuse
|
// The following code is for testing purposes only. It is a definite abuse
|
||||||
// of the API and shouldn't be used in real applications.
|
// of the API and shouldn't be used in real applications.
|
||||||
@ -729,6 +733,7 @@ TEST(ActiveFormatterTest, ArgLifetime) {
|
|||||||
// calls Format.
|
// calls Format.
|
||||||
EXPECT_EQ("test", str(af));
|
EXPECT_EQ("test", str(af));
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
struct PrintError {
|
struct PrintError {
|
||||||
void operator()(const fmt::Formatter &f) const {
|
void operator()(const fmt::Formatter &f) const {
|
||||||
|
Loading…
Reference in New Issue
Block a user