fixed compilation in MSVC
mordante: cmath apparently doesn't contain round() here, and round() also seems not guaranteed to yield consistent results on different platforms (as opposed to round_portable according to what its comment says) (bug #18165)
This commit is contained in:
parent
2192aac30d
commit
69c0e582d7
1 changed files with 2 additions and 1 deletions
|
@ -24,6 +24,7 @@
|
|||
#include "formatter.hpp"
|
||||
#include "formula_callable.hpp"
|
||||
#include "formula_function.hpp"
|
||||
#include "util.hpp"
|
||||
|
||||
namespace {
|
||||
std::string variant_type_to_string(variant::TYPE type) {
|
||||
|
@ -684,7 +685,7 @@ variant variant::operator^(const variant& v) const
|
|||
}
|
||||
|
||||
return variant(static_cast<int>(
|
||||
round(pow(static_cast<double>(as_int()), v.as_int()))));
|
||||
round_portable(pow(static_cast<double>(as_int()), v.as_int()))));
|
||||
}
|
||||
|
||||
variant variant::operator-() const
|
||||
|
|
Loading…
Add table
Reference in a new issue