[mapbox-geometry] 01/05: New upstream version 0.9.2

Bas Couwenberg sebastic at debian.org
Thu Jul 6 15:18:26 UTC 2017


This is an automated email from the git hooks/post-receive script.

sebastic pushed a commit to branch master
in repository mapbox-geometry.

commit 33e017224b2c9a1789c0e083564a60ff1a7e4521
Author: Bas Couwenberg <sebastic at xs4all.nl>
Date:   Thu Jul 6 17:13:40 2017 +0200

    New upstream version 0.9.2
---
 .travis.yml                                  |  6 ++++++
 include/mapbox/geometry/feature.hpp          |  9 ++++++++
 include/mapbox/geometry/point_arithmetic.hpp | 32 ++++++++++++++--------------
 3 files changed, 31 insertions(+), 16 deletions(-)

diff --git a/.travis.yml b/.travis.yml
index 537c0d8..a567bdc 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -4,6 +4,12 @@ sudo: false
 matrix:
   include:
     - os: linux
+      env: CXX=g++-4.9
+      addons:
+        apt:
+          sources: [ 'ubuntu-toolchain-r-test' ]
+          packages: [ 'g++-4.9' ]
+    - os: linux
       env: CXX=g++-5
       addons:
         apt:
diff --git a/include/mapbox/geometry/feature.hpp b/include/mapbox/geometry/feature.hpp
index 81ce65e..20d2ddf 100644
--- a/include/mapbox/geometry/feature.hpp
+++ b/include/mapbox/geometry/feature.hpp
@@ -55,6 +55,15 @@ struct feature
     geometry_type geometry;
     property_map properties {};
     std::experimental::optional<identifier> id {};
+
+    // GCC 4.9 does not support C++14 aggregates with non-static data member
+    // initializers.
+    feature(geometry_type geometry_,
+            property_map properties_ = property_map {},
+            std::experimental::optional<identifier> id_ = std::experimental::optional<identifier> {})
+        : geometry(std::move(geometry_)),
+          properties(std::move(properties_)),
+          id(std::move(id_)) {}
 };
 
 template <class T>
diff --git a/include/mapbox/geometry/point_arithmetic.hpp b/include/mapbox/geometry/point_arithmetic.hpp
index 3940e5b..0c4c632 100644
--- a/include/mapbox/geometry/point_arithmetic.hpp
+++ b/include/mapbox/geometry/point_arithmetic.hpp
@@ -4,55 +4,55 @@ namespace mapbox {
 namespace geometry {
 
 template <typename T>
-constexpr point<T> operator+(point<T> const& lhs, point<T> const& rhs)
+point<T> operator+(point<T> const& lhs, point<T> const& rhs)
 {
     return point<T>(lhs.x + rhs.x, lhs.y + rhs.y);
 }
 
 template <typename T>
-constexpr point<T> operator+(point<T> const& lhs, T const& rhs)
+point<T> operator+(point<T> const& lhs, T const& rhs)
 {
     return point<T>(lhs.x + rhs, lhs.y + rhs);
 }
 
 template <typename T>
-constexpr point<T> operator-(point<T> const& lhs, point<T> const& rhs)
+point<T> operator-(point<T> const& lhs, point<T> const& rhs)
 {
     return point<T>(lhs.x - rhs.x, lhs.y - rhs.y);
 }
 
 template <typename T>
-constexpr point<T> operator-(point<T> const& lhs, T const& rhs)
+point<T> operator-(point<T> const& lhs, T const& rhs)
 {
     return point<T>(lhs.x - rhs, lhs.y - rhs);
 }
 
 template <typename T>
-constexpr point<T> operator*(point<T> const& lhs, point<T> const& rhs)
+point<T> operator*(point<T> const& lhs, point<T> const& rhs)
 {
     return point<T>(lhs.x * rhs.x, lhs.y * rhs.y);
 }
 
 template <typename T>
-constexpr point<T> operator*(point<T> const& lhs, T const& rhs)
+point<T> operator*(point<T> const& lhs, T const& rhs)
 {
     return point<T>(lhs.x * rhs, lhs.y * rhs);
 }
 
 template <typename T>
-constexpr point<T> operator/(point<T> const& lhs, point<T> const& rhs)
+point<T> operator/(point<T> const& lhs, point<T> const& rhs)
 {
     return point<T>(lhs.x / rhs.x, lhs.y / rhs.y);
 }
 
 template <typename T>
-constexpr point<T> operator/(point<T> const& lhs, T const& rhs)
+point<T> operator/(point<T> const& lhs, T const& rhs)
 {
     return point<T>(lhs.x / rhs, lhs.y / rhs);
 }
 
 template <typename T>
-constexpr point<T>& operator+=(point<T>& lhs, point<T> const& rhs)
+point<T>& operator+=(point<T>& lhs, point<T> const& rhs)
 {
     lhs.x += rhs.x;
     lhs.y += rhs.y;
@@ -60,7 +60,7 @@ constexpr point<T>& operator+=(point<T>& lhs, point<T> const& rhs)
 }
 
 template <typename T>
-constexpr point<T>& operator+=(point<T>& lhs, T const& rhs)
+point<T>& operator+=(point<T>& lhs, T const& rhs)
 {
     lhs.x += rhs;
     lhs.y += rhs;
@@ -68,7 +68,7 @@ constexpr point<T>& operator+=(point<T>& lhs, T const& rhs)
 }
 
 template <typename T>
-constexpr point<T>& operator-=(point<T>& lhs, point<T> const& rhs)
+point<T>& operator-=(point<T>& lhs, point<T> const& rhs)
 {
     lhs.x -= rhs.x;
     lhs.y -= rhs.y;
@@ -76,7 +76,7 @@ constexpr point<T>& operator-=(point<T>& lhs, point<T> const& rhs)
 }
 
 template <typename T>
-constexpr point<T>& operator-=(point<T>& lhs, T const& rhs)
+point<T>& operator-=(point<T>& lhs, T const& rhs)
 {
     lhs.x -= rhs;
     lhs.y -= rhs;
@@ -84,7 +84,7 @@ constexpr point<T>& operator-=(point<T>& lhs, T const& rhs)
 }
 
 template <typename T>
-constexpr point<T>& operator*=(point<T>& lhs, point<T> const& rhs)
+point<T>& operator*=(point<T>& lhs, point<T> const& rhs)
 {
     lhs.x *= rhs.x;
     lhs.y *= rhs.y;
@@ -92,7 +92,7 @@ constexpr point<T>& operator*=(point<T>& lhs, point<T> const& rhs)
 }
 
 template <typename T>
-constexpr point<T>& operator*=(point<T>& lhs, T const& rhs)
+point<T>& operator*=(point<T>& lhs, T const& rhs)
 {
     lhs.x *= rhs;
     lhs.y *= rhs;
@@ -100,7 +100,7 @@ constexpr point<T>& operator*=(point<T>& lhs, T const& rhs)
 }
 
 template <typename T>
-constexpr point<T>& operator/=(point<T>& lhs, point<T> const& rhs)
+point<T>& operator/=(point<T>& lhs, point<T> const& rhs)
 {
     lhs.x /= rhs.x;
     lhs.y /= rhs.y;
@@ -108,7 +108,7 @@ constexpr point<T>& operator/=(point<T>& lhs, point<T> const& rhs)
 }
 
 template <typename T>
-constexpr point<T>& operator/=(point<T>& lhs, T const& rhs)
+point<T>& operator/=(point<T>& lhs, T const& rhs)
 {
     lhs.x /= rhs;
     lhs.y /= rhs;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/mapbox-geometry.git



More information about the Pkg-grass-devel mailing list