From c03cb2d434bc1fd04f39b041c7b657a770e49925 Mon Sep 17 00:00:00 2001 From: artemp Date: Thu, 15 Sep 2016 15:40:38 +0200 Subject: [PATCH] consistently return x3 grammars by const& --- include/mapnik/css_color_grammar_x3.hpp | 2 +- include/mapnik/css_color_grammar_x3_def.hpp | 2 +- include/mapnik/expression_grammar_x3.hpp | 2 +- include/mapnik/expression_grammar_x3_def.hpp | 2 +- include/mapnik/image_filter_grammar_x3.hpp | 2 +- include/mapnik/image_filter_grammar_x3_def.hpp | 2 +- include/mapnik/transform_expression_grammar_x3.hpp | 2 +- include/mapnik/transform_expression_grammar_x3_def.hpp | 2 +- include/mapnik/wkt/wkt_grammar_x3.hpp | 2 +- include/mapnik/wkt/wkt_grammar_x3_def.hpp | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) diff --git a/include/mapnik/css_color_grammar_x3.hpp b/include/mapnik/css_color_grammar_x3.hpp index 0719e44ec..54e022528 100644 --- a/include/mapnik/css_color_grammar_x3.hpp +++ b/include/mapnik/css_color_grammar_x3.hpp @@ -48,7 +48,7 @@ BOOST_SPIRIT_DECLARE(css_color_grammar_type); namespace mapnik { -css_color_grammar::css_color_grammar_type color_grammar(); +css_color_grammar::css_color_grammar_type const& color_grammar(); } diff --git a/include/mapnik/css_color_grammar_x3_def.hpp b/include/mapnik/css_color_grammar_x3_def.hpp index 2ad3cfa34..457f0d999 100644 --- a/include/mapnik/css_color_grammar_x3_def.hpp +++ b/include/mapnik/css_color_grammar_x3_def.hpp @@ -444,7 +444,7 @@ BOOST_SPIRIT_DEFINE( } // ns -css_color_grammar::css_color_grammar_type color_grammar() +css_color_grammar::css_color_grammar_type const& color_grammar() { return css_color_grammar::css_color; } diff --git a/include/mapnik/expression_grammar_x3.hpp b/include/mapnik/expression_grammar_x3.hpp index 889211939..46bdb2a84 100644 --- a/include/mapnik/expression_grammar_x3.hpp +++ b/include/mapnik/expression_grammar_x3.hpp @@ -44,7 +44,7 @@ BOOST_SPIRIT_DECLARE(expression_grammar_type); namespace mapnik { -grammar::expression_grammar_type expression_grammar(); +grammar::expression_grammar_type const& expression_grammar(); } diff --git a/include/mapnik/expression_grammar_x3_def.hpp b/include/mapnik/expression_grammar_x3_def.hpp index 0ef8fe960..d8ab45ade 100644 --- a/include/mapnik/expression_grammar_x3_def.hpp +++ b/include/mapnik/expression_grammar_x3_def.hpp @@ -424,7 +424,7 @@ namespace mapnik { namespace grammar { namespace mapnik { -grammar::expression_grammar_type expression_grammar() +grammar::expression_grammar_type const& expression_grammar() { return grammar::expression; } diff --git a/include/mapnik/image_filter_grammar_x3.hpp b/include/mapnik/image_filter_grammar_x3.hpp index ca452009e..8632c9122 100644 --- a/include/mapnik/image_filter_grammar_x3.hpp +++ b/include/mapnik/image_filter_grammar_x3.hpp @@ -49,7 +49,7 @@ BOOST_SPIRIT_DECLARE(image_filter_grammar_type); namespace mapnik { -image_filter::image_filter_grammar_type image_filter_grammar(); +image_filter::image_filter_grammar_type const& image_filter_grammar(); } diff --git a/include/mapnik/image_filter_grammar_x3_def.hpp b/include/mapnik/image_filter_grammar_x3_def.hpp index 2d680bea1..b40bfc8f9 100644 --- a/include/mapnik/image_filter_grammar_x3_def.hpp +++ b/include/mapnik/image_filter_grammar_x3_def.hpp @@ -251,7 +251,7 @@ BOOST_SPIRIT_DEFINE( } // image_filter -image_filter::image_filter_grammar_type image_filter_grammar() +image_filter::image_filter_grammar_type const& image_filter_grammar() { return image_filter::start; } diff --git a/include/mapnik/transform_expression_grammar_x3.hpp b/include/mapnik/transform_expression_grammar_x3.hpp index ccf480c22..77ff330d9 100644 --- a/include/mapnik/transform_expression_grammar_x3.hpp +++ b/include/mapnik/transform_expression_grammar_x3.hpp @@ -45,7 +45,7 @@ BOOST_SPIRIT_DECLARE(transform_expression_grammar_type); namespace mapnik { -grammar::transform_expression_grammar_type transform_expression_grammar(); +grammar::transform_expression_grammar_type const& transform_expression_grammar(); } #endif diff --git a/include/mapnik/transform_expression_grammar_x3_def.hpp b/include/mapnik/transform_expression_grammar_x3_def.hpp index 602f30aee..4af1e9481 100644 --- a/include/mapnik/transform_expression_grammar_x3_def.hpp +++ b/include/mapnik/transform_expression_grammar_x3_def.hpp @@ -175,7 +175,7 @@ namespace mapnik { namespace grammar { namespace mapnik { -grammar::transform_expression_grammar_type transform_expression_grammar() +grammar::transform_expression_grammar_type const& transform_expression_grammar() { return grammar::transform; } diff --git a/include/mapnik/wkt/wkt_grammar_x3.hpp b/include/mapnik/wkt/wkt_grammar_x3.hpp index 3fd969848..a0b6be0f0 100644 --- a/include/mapnik/wkt/wkt_grammar_x3.hpp +++ b/include/mapnik/wkt/wkt_grammar_x3.hpp @@ -42,7 +42,7 @@ BOOST_SPIRIT_DECLARE(wkt_grammar_type); namespace mapnik { -grammar::wkt_grammar_type wkt_grammar(); +grammar::wkt_grammar_type const& wkt_grammar(); } diff --git a/include/mapnik/wkt/wkt_grammar_x3_def.hpp b/include/mapnik/wkt/wkt_grammar_x3_def.hpp index 62fdb1ac0..b4bff5e38 100644 --- a/include/mapnik/wkt/wkt_grammar_x3_def.hpp +++ b/include/mapnik/wkt/wkt_grammar_x3_def.hpp @@ -121,7 +121,7 @@ BOOST_SPIRIT_DEFINE( namespace mapnik { -grammar::wkt_grammar_type wkt_grammar() +grammar::wkt_grammar_type const& wkt_grammar() { return grammar::wkt; }