Skip to content

Commit

Permalink
MSVC doesn't like "or"
Browse files Browse the repository at this point in the history
  • Loading branch information
nsmith- committed Jun 18, 2024
1 parent 88a50b4 commit f9bb34f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/correction.cc
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ namespace {
return edge.GetDouble();
} else if ( edge.IsString() ) {
std::string_view str = edge.GetString();
if (str == "inf" or str == "+inf") return std::numeric_limits<double>::infinity();
if ((str == "inf") || (str == "+inf")) return std::numeric_limits<double>::infinity();
else if (str == "-inf") return -std::numeric_limits<double>::infinity();
}
throw std::runtime_error("Invalid edge type");
Expand Down

0 comments on commit f9bb34f

Please sign in to comment.