From 4bbb6a4c463bbf1cd151291c57b6009c760e8026 Mon Sep 17 00:00:00 2001 From: Axel Huebl Date: Wed, 15 Feb 2017 23:56:24 +0100 Subject: [PATCH] JSON Parser: Missing Bind Placeholders Fixes missing placeholder includes to `boost::bind`. ``` boost/property_tree/json_parser/detail/parser.hpp(217): error: identifier "_1" is undefined boost/property_tree/json_parser/detail/parser.hpp(520): error: identifier "_1" is undefined ``` Reported in https://svn.boost.org/trac/boost/ticket/12841 --- include/boost/property_tree/json_parser/detail/parser.hpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/include/boost/property_tree/json_parser/detail/parser.hpp b/include/boost/property_tree/json_parser/detail/parser.hpp index 5554990fb..9ad5c0068 100644 --- a/include/boost/property_tree/json_parser/detail/parser.hpp +++ b/include/boost/property_tree/json_parser/detail/parser.hpp @@ -5,6 +5,7 @@ #include #include +#include #include #include @@ -214,7 +215,8 @@ namespace boost { namespace property_tree { void process_codepoint(Sentinel end, EncodingErrorFn error_fn) { encoding.transcode_codepoint(cur, end, boost::bind(&Callbacks::on_code_unit, - boost::ref(callbacks), _1), + boost::ref(callbacks), + boost::placeholders::_1), error_fn); } @@ -517,7 +519,8 @@ namespace boost { namespace property_tree { void feed(unsigned codepoint) { encoding.feed_codepoint(codepoint, boost::bind(&Callbacks::on_code_unit, - boost::ref(callbacks), _1)); + boost::ref(callbacks), + boost::placeholders::_1)); } Callbacks& callbacks;