diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2015-12-01 17:45:21 +0100 |
---|---|---|
committer | Konstantin Käfer <mail@kkaefer.com> | 2015-12-03 15:38:36 +0100 |
commit | 478472e501a6aa579174f547277176c19104deb1 (patch) | |
tree | 12f9852c9c64725f8bbded04ee916c720fdf9dd8 /src/mbgl/style | |
parent | d5fb535058d4d97567b08064e0203f45c2c8370f (diff) | |
download | qtlocation-mapboxgl-478472e501a6aa579174f547277176c19104deb1.tar.gz |
[core] add std::move to constructors
Diffstat (limited to 'src/mbgl/style')
-rw-r--r-- | src/mbgl/style/layout_property.hpp | 3 | ||||
-rw-r--r-- | src/mbgl/style/paint_property.hpp | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/mbgl/style/layout_property.hpp b/src/mbgl/style/layout_property.hpp index 7feb931204..db2b2d3aba 100644 --- a/src/mbgl/style/layout_property.hpp +++ b/src/mbgl/style/layout_property.hpp @@ -3,6 +3,7 @@ #include <mbgl/style/property_parsing.hpp> #include <mbgl/style/function.hpp> +#include <utility> #include <rapidjson/document.h> @@ -13,7 +14,7 @@ using JSVal = rapidjson::Value; template <typename T> class LayoutProperty { public: - LayoutProperty(T v) : value(v) {} + LayoutProperty(T v) : value(std::move(v)) {} void parse(const char * name, const JSVal& layout) { if (layout.HasMember(name)) { diff --git a/src/mbgl/style/paint_property.hpp b/src/mbgl/style/paint_property.hpp index 88feb1307b..710ce34a4f 100644 --- a/src/mbgl/style/paint_property.hpp +++ b/src/mbgl/style/paint_property.hpp @@ -12,6 +12,7 @@ #include <rapidjson/document.h> #include <map> +#include <utility> namespace mbgl { @@ -117,7 +118,7 @@ public: : prior(std::move(prior_)), begin(begin_), end(end_), - value(value_) { + value(std::move(value_)) { } Result calculate(const StyleCalculationParameters& parameters) { |