summaryrefslogtreecommitdiff
path: root/src/mbgl/style/expression/compound_expression.cpp
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2018-01-08 13:18:40 -0800
committerJohn Firebaugh <john.firebaugh@gmail.com>2018-01-09 16:10:51 -0800
commita13027c1b6e2aa9a213628acf9124cd6c872f204 (patch)
treec0c86f052025c3637c9af0922551492f4398860b /src/mbgl/style/expression/compound_expression.cpp
parent43a9bd3fbab666f21583ff264d6b6ba1d7069374 (diff)
downloadqtlocation-mapboxgl-a13027c1b6e2aa9a213628acf9124cd6c872f204.tar.gz
[core] Improve typing for !=, == expressions
Diffstat (limited to 'src/mbgl/style/expression/compound_expression.cpp')
-rw-r--r--src/mbgl/style/expression/compound_expression.cpp16
1 files changed, 0 insertions, 16 deletions
diff --git a/src/mbgl/style/expression/compound_expression.cpp b/src/mbgl/style/expression/compound_expression.cpp
index 70bc6dfd95..ff21157faa 100644
--- a/src/mbgl/style/expression/compound_expression.cpp
+++ b/src/mbgl/style/expression/compound_expression.cpp
@@ -175,12 +175,6 @@ struct Signature<Lambda, std::enable_if_t<std::is_class<Lambda>::value>>
using Definition = CompoundExpressionRegistry::Definition;
-template <typename T>
-Result<bool> equal(const T& lhs, const T& rhs) { return lhs == rhs; }
-
-template <typename T>
-Result<bool> notEqual(const T& lhs, const T& rhs) { return lhs != rhs; }
-
template <typename Fn>
static std::unique_ptr<detail::SignatureBase> makeSignature(Fn evaluateFunction) {
return std::make_unique<detail::Signature<Fn>>(evaluateFunction);
@@ -376,16 +370,6 @@ std::unordered_map<std::string, CompoundExpressionRegistry::Definition> initiali
return result;
});
- define("==", equal<double>);
- define("==", equal<const std::string&>);
- define("==", equal<bool>);
- define("==", equal<NullValue>);
-
- define("!=", notEqual<double>);
- define("!=", notEqual<const std::string&>);
- define("!=", notEqual<bool>);
- define("!=", notEqual<NullValue>);
-
define(">", [](double lhs, double rhs) -> Result<bool> { return lhs > rhs; });
define(">", [](const std::string& lhs, const std::string& rhs) -> Result<bool> { return lhs > rhs; });
define(">=", [](double lhs, double rhs) -> Result<bool> { return lhs >= rhs; });