summaryrefslogtreecommitdiff
path: root/src/third_party/s2
diff options
context:
space:
mode:
authorMathias Stearn <mathias@10gen.com>2017-06-30 14:09:35 -0400
committerMathias Stearn <mathias@10gen.com>2017-07-13 16:53:12 -0400
commit8204c7dacf17851057dda165e6d1638cbff70cbf (patch)
tree3fbdbb27d02f37c3cc2ad994cc9ea6ce87aab407 /src/third_party/s2
parent26ff40f21fabb2ac28405f6ebbca5c45f19bc760 (diff)
downloadmongo-8204c7dacf17851057dda165e6d1638cbff70cbf.tar.gz
SERVER-29887 address clang-4.0 warnings in geo code
Diffstat (limited to 'src/third_party/s2')
-rwxr-xr-xsrc/third_party/s2/util/math/mathutil.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/third_party/s2/util/math/mathutil.cc b/src/third_party/s2/util/math/mathutil.cc
index 7ca3b890f8a..8a4c2e23cbc 100755
--- a/src/third_party/s2/util/math/mathutil.cc
+++ b/src/third_party/s2/util/math/mathutil.cc
@@ -27,7 +27,13 @@ using std::vector;
return static_cast<IntOut>(x < 0 ? (x - 0.5) : (x + 0.5));
}
+// MONGODB suppress clang-4.0 warning by disabling the following line, but leave it in for MSVC
+// since removing it results in a linker error there.
+// error: explicit instantiation of 'Round<int, double>' that occurs after an explicit
+// specialization has no effect [-Werror,-Winstantiation-after-specialization]
+#ifdef _MSC_VER
template int MathUtil::Round<int,double>(double x);
+#endif
MathUtil::QuadraticRootType MathUtil::RealRootsForQuadratic(long double a,
long double b,