Merge pull request #4275 from mathisloge/remove_make_unique_cpp11
This commit is contained in:
commit
fb06428250
24 changed files with 1 additions and 65 deletions
|
@ -1,42 +0,0 @@
|
||||||
/*****************************************************************************
|
|
||||||
*
|
|
||||||
* This file is part of Mapnik (c++ mapping toolkit)
|
|
||||||
*
|
|
||||||
* Copyright (C) 2021 Artem Pavlenko
|
|
||||||
*
|
|
||||||
* This library is free software; you can redistribute it and/or
|
|
||||||
* modify it under the terms of the GNU Lesser General Public
|
|
||||||
* License as published by the Free Software Foundation; either
|
|
||||||
* version 2.1 of the License, or (at your option) any later version.
|
|
||||||
*
|
|
||||||
* This library is distributed in the hope that it will be useful,
|
|
||||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
* Lesser General Public License for more details.
|
|
||||||
*
|
|
||||||
* You should have received a copy of the GNU Lesser General Public
|
|
||||||
* License along with this library; if not, write to the Free Software
|
|
||||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
*
|
|
||||||
*****************************************************************************/
|
|
||||||
|
|
||||||
#ifndef MAPNIK_MAKE_UNIQUE_HPP
|
|
||||||
#define MAPNIK_MAKE_UNIQUE_HPP
|
|
||||||
|
|
||||||
// http://stackoverflow.com/questions/14131454/visual-studio-2012-cplusplus-and-c-11
|
|
||||||
#if defined(_MSC_VER) && _MSC_VER < 1800 || !defined(_MSC_VER) && __cplusplus <= 201103L
|
|
||||||
|
|
||||||
#include <memory>
|
|
||||||
|
|
||||||
namespace std {
|
|
||||||
|
|
||||||
// C++14 backfill from http://herbsutter.com/gotw/_102/
|
|
||||||
template<typename T, typename ...Args>
|
|
||||||
inline std::unique_ptr<T> make_unique(Args&& ...args) {
|
|
||||||
return std::unique_ptr<T>(new T(std::forward<Args>(args)...));
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#endif // MAPNIK_MAKE_UNIQUE_HPP
|
|
|
@ -26,7 +26,6 @@
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/geometry/box2d.hpp>
|
#include <mapnik/geometry/box2d.hpp>
|
||||||
#include <mapnik/util/noncopyable.hpp>
|
#include <mapnik/util/noncopyable.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
|
|
||||||
// stl
|
// stl
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
|
@ -24,7 +24,6 @@
|
||||||
#define MAPNIK_FILE_IO_HPP
|
#define MAPNIK_FILE_IO_HPP
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/util/noncopyable.hpp>
|
#include <mapnik/util/noncopyable.hpp>
|
||||||
#include <mapnik/util/utf_conv_win.hpp>
|
#include <mapnik/util/utf_conv_win.hpp>
|
||||||
|
|
||||||
|
|
|
@ -25,7 +25,6 @@
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/config.hpp>
|
#include <mapnik/config.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/wkb.hpp>
|
#include <mapnik/wkb.hpp>
|
||||||
#include <mapnik/geometry.hpp>
|
#include <mapnik/geometry.hpp>
|
||||||
#include <mapnik/geometry/geometry_type.hpp>
|
#include <mapnik/geometry/geometry_type.hpp>
|
||||||
|
|
|
@ -42,7 +42,6 @@
|
||||||
#include <mapnik/util/geometry_to_ds_type.hpp>
|
#include <mapnik/util/geometry_to_ds_type.hpp>
|
||||||
#include <mapnik/value/types.hpp>
|
#include <mapnik/value/types.hpp>
|
||||||
#include <mapnik/util/fs.hpp>
|
#include <mapnik/util/fs.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/util/spatial_index.hpp>
|
#include <mapnik/util/spatial_index.hpp>
|
||||||
#include <mapnik/geom_util.hpp>
|
#include <mapnik/geom_util.hpp>
|
||||||
#if defined(MAPNIK_MEMORY_MAPPED_FILE)
|
#if defined(MAPNIK_MEMORY_MAPPED_FILE)
|
||||||
|
|
|
@ -43,7 +43,6 @@
|
||||||
#include <mapnik/util/geometry_to_ds_type.hpp>
|
#include <mapnik/util/geometry_to_ds_type.hpp>
|
||||||
#include <mapnik/util/variant.hpp>
|
#include <mapnik/util/variant.hpp>
|
||||||
#include <mapnik/util/file_io.hpp>
|
#include <mapnik/util/file_io.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/geometry/boost_adapters.hpp>
|
#include <mapnik/geometry/boost_adapters.hpp>
|
||||||
|
|
||||||
using mapnik::datasource;
|
using mapnik::datasource;
|
||||||
|
|
|
@ -48,7 +48,6 @@ MAPNIK_DISABLE_WARNING_POP
|
||||||
#include <mapnik/util/variant.hpp>
|
#include <mapnik/util/variant.hpp>
|
||||||
#include <mapnik/util/file_io.hpp>
|
#include <mapnik/util/file_io.hpp>
|
||||||
#include <mapnik/util/geometry_to_ds_type.hpp>
|
#include <mapnik/util/geometry_to_ds_type.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/geometry/boost_adapters.hpp>
|
#include <mapnik/geometry/boost_adapters.hpp>
|
||||||
#include <mapnik/util/fs.hpp>
|
#include <mapnik/util/fs.hpp>
|
||||||
#include <mapnik/util/spatial_index.hpp>
|
#include <mapnik/util/spatial_index.hpp>
|
||||||
|
|
|
@ -33,7 +33,6 @@ MAPNIK_DISABLE_WARNING_POP
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/debug.hpp>
|
#include <mapnik/debug.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/util/fs.hpp>
|
#include <mapnik/util/fs.hpp>
|
||||||
#include <mapnik/global.hpp>
|
#include <mapnik/global.hpp>
|
||||||
#include <mapnik/util/utf_conv_win.hpp>
|
#include <mapnik/util/utf_conv_win.hpp>
|
||||||
|
|
|
@ -24,7 +24,6 @@
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/debug.hpp>
|
#include <mapnik/debug.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/datasource.hpp>
|
#include <mapnik/datasource.hpp>
|
||||||
#include <mapnik/util/is_clockwise.hpp>
|
#include <mapnik/util/is_clockwise.hpp>
|
||||||
#include <mapnik/geometry/correct.hpp>
|
#include <mapnik/geometry/correct.hpp>
|
||||||
|
|
|
@ -38,7 +38,6 @@
|
||||||
#include <mapnik/json/topojson_utils.hpp>
|
#include <mapnik/json/topojson_utils.hpp>
|
||||||
#include <mapnik/util/variant.hpp>
|
#include <mapnik/util/variant.hpp>
|
||||||
#include <mapnik/util/file_io.hpp>
|
#include <mapnik/util/file_io.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
|
|
||||||
using mapnik::datasource;
|
using mapnik::datasource;
|
||||||
using mapnik::parameters;
|
using mapnik::parameters;
|
||||||
|
|
|
@ -42,7 +42,6 @@
|
||||||
#include <mapnik/image_compositing.hpp>
|
#include <mapnik/image_compositing.hpp>
|
||||||
#include <mapnik/image_filter.hpp>
|
#include <mapnik/image_filter.hpp>
|
||||||
#include <mapnik/image_any.hpp>
|
#include <mapnik/image_any.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
|
|
||||||
#include <mapnik/warning.hpp>
|
#include <mapnik/warning.hpp>
|
||||||
MAPNIK_DISABLE_WARNING_PUSH
|
MAPNIK_DISABLE_WARNING_PUSH
|
||||||
|
|
|
@ -21,7 +21,6 @@
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/image_any.hpp>
|
#include <mapnik/image_any.hpp>
|
||||||
#include <mapnik/feature.hpp>
|
#include <mapnik/feature.hpp>
|
||||||
#include <mapnik/agg_renderer.hpp>
|
#include <mapnik/agg_renderer.hpp>
|
||||||
|
|
|
@ -23,7 +23,6 @@
|
||||||
#if defined(HAVE_CAIRO)
|
#if defined(HAVE_CAIRO)
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/feature.hpp>
|
#include <mapnik/feature.hpp>
|
||||||
#include <mapnik/symbolizer.hpp>
|
#include <mapnik/symbolizer.hpp>
|
||||||
#include <mapnik/proj_transform.hpp>
|
#include <mapnik/proj_transform.hpp>
|
||||||
|
|
|
@ -23,7 +23,6 @@
|
||||||
#if defined(HAVE_CAIRO)
|
#if defined(HAVE_CAIRO)
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/feature.hpp>
|
#include <mapnik/feature.hpp>
|
||||||
#include <mapnik/proj_transform.hpp>
|
#include <mapnik/proj_transform.hpp>
|
||||||
#include <mapnik/cairo/cairo_renderer.hpp>
|
#include <mapnik/cairo/cairo_renderer.hpp>
|
||||||
|
|
|
@ -23,7 +23,6 @@
|
||||||
#if defined(HAVE_CAIRO)
|
#if defined(HAVE_CAIRO)
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/feature.hpp>
|
#include <mapnik/feature.hpp>
|
||||||
#include <mapnik/symbolizer_enumerations.hpp>
|
#include <mapnik/symbolizer_enumerations.hpp>
|
||||||
#include <mapnik/proj_transform.hpp>
|
#include <mapnik/proj_transform.hpp>
|
||||||
|
|
|
@ -27,7 +27,6 @@
|
||||||
#include <mapnik/text/face.hpp>
|
#include <mapnik/text/face.hpp>
|
||||||
#include <mapnik/util/fs.hpp>
|
#include <mapnik/util/fs.hpp>
|
||||||
#include <mapnik/util/file_io.hpp>
|
#include <mapnik/util/file_io.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
|
|
||||||
#include <mapnik/warning.hpp>
|
#include <mapnik/warning.hpp>
|
||||||
MAPNIK_DISABLE_WARNING_PUSH
|
MAPNIK_DISABLE_WARNING_PUSH
|
||||||
|
|
|
@ -23,7 +23,6 @@
|
||||||
#if defined(GRID_RENDERER)
|
#if defined(GRID_RENDERER)
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/feature.hpp>
|
#include <mapnik/feature.hpp>
|
||||||
#include <mapnik/grid/grid_rasterizer.hpp>
|
#include <mapnik/grid/grid_rasterizer.hpp>
|
||||||
#include <mapnik/grid/grid_renderer.hpp>
|
#include <mapnik/grid/grid_renderer.hpp>
|
||||||
|
|
|
@ -22,7 +22,6 @@
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/label_collision_detector.hpp>
|
#include <mapnik/label_collision_detector.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/renderer_common/render_markers_symbolizer.hpp>
|
#include <mapnik/renderer_common/render_markers_symbolizer.hpp>
|
||||||
#include <mapnik/renderer_common/render_thunk_extractor.hpp>
|
#include <mapnik/renderer_common/render_thunk_extractor.hpp>
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,6 @@
|
||||||
#include <mapnik/symbolizer.hpp>
|
#include <mapnik/symbolizer.hpp>
|
||||||
#include <mapnik/text/harfbuzz_shaper.hpp>
|
#include <mapnik/text/harfbuzz_shaper.hpp>
|
||||||
#include <mapnik/util/math.hpp>
|
#include <mapnik/util/math.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
|
|
||||||
#include <mapnik/warning.hpp>
|
#include <mapnik/warning.hpp>
|
||||||
MAPNIK_DISABLE_WARNING_PUSH
|
MAPNIK_DISABLE_WARNING_PUSH
|
||||||
|
|
|
@ -33,7 +33,6 @@
|
||||||
#include <mapnik/config_error.hpp>
|
#include <mapnik/config_error.hpp>
|
||||||
#include <mapnik/text/properties_util.hpp>
|
#include <mapnik/text/properties_util.hpp>
|
||||||
#include <mapnik/boolean.hpp>
|
#include <mapnik/boolean.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
|
|
||||||
#include <mapnik/warning.hpp>
|
#include <mapnik/warning.hpp>
|
||||||
MAPNIK_DISABLE_WARNING_PUSH
|
MAPNIK_DISABLE_WARNING_PUSH
|
||||||
|
|
|
@ -23,7 +23,7 @@
|
||||||
#include <mapnik/util/math.hpp>
|
#include <mapnik/util/math.hpp>
|
||||||
#include <mapnik/vertex_cache.hpp>
|
#include <mapnik/vertex_cache.hpp>
|
||||||
#include <mapnik/offset_converter.hpp>
|
#include <mapnik/offset_converter.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
#include <memory>
|
||||||
|
|
||||||
namespace mapnik
|
namespace mapnik
|
||||||
{
|
{
|
||||||
|
|
|
@ -21,7 +21,6 @@
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/debug.hpp>
|
#include <mapnik/debug.hpp>
|
||||||
#include <mapnik/image_reader.hpp>
|
#include <mapnik/image_reader.hpp>
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,6 @@
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
|
|
||||||
// mapnik
|
// mapnik
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/debug.hpp>
|
#include <mapnik/debug.hpp>
|
||||||
#include <mapnik/global.hpp>
|
#include <mapnik/global.hpp>
|
||||||
#include <mapnik/wkb.hpp>
|
#include <mapnik/wkb.hpp>
|
||||||
|
|
|
@ -22,7 +22,6 @@
|
||||||
|
|
||||||
//mapnik
|
//mapnik
|
||||||
#include <mapnik/debug.hpp>
|
#include <mapnik/debug.hpp>
|
||||||
#include <mapnik/make_unique.hpp>
|
|
||||||
#include <mapnik/xml_tree.hpp>
|
#include <mapnik/xml_tree.hpp>
|
||||||
#include <mapnik/xml_attribute_cast.hpp>
|
#include <mapnik/xml_attribute_cast.hpp>
|
||||||
#include <mapnik/util/conversions.hpp>
|
#include <mapnik/util/conversions.hpp>
|
||||||
|
|
Loading…
Reference in a new issue