Boost C++ Libraries: Ticket #9114: Documentation examples not working https://svn.boost.org/trac10/ticket/9114 <p> Example of <em>qi::phrase_parse</em> (from this <a href="http://www.boost.org/doc/libs/1_54_0/libs/spirit/doc/html/spirit/abstracts/attributes/compound_attributes.html">page</a>): </p> <pre class="wiki">// the following parses "1.0 2.0" into a pair of double std::string input("1.0 2.0"); std::string::iterator strbegin = input.begin(); std::pair&lt;double, double&gt; p; qi::phrase_parse(strbegin, input.end(), qi::double_ &gt;&gt; qi::double_, // parser grammar qi::space, // delimiter grammar p); </pre><p> and example of <em>qi::parse</em> (from this <a href="http://www.boost.org/doc/libs/1_54_0/libs/spirit/doc/html/spirit/abstracts/attributes/more_compound_attributes.html">page</a>): </p> <pre class="wiki">// the following parses "(1.0, 2.0)" into a pair of double std::string input("(1.0, 2.0)"); std::string::iterator strbegin = input.begin(); std::pair&lt;double, double&gt; p; qi::parse(strbegin, input.end(), '(' &gt;&gt; qi::double_ &gt;&gt; ", " &gt;&gt; qi::double_ &gt;&gt; ')', // parser grammar p); </pre><p> both produce compile error: </p> <pre class="wiki">no matching function for call to 'std::pair&lt;double, double&gt;::pair(const double&amp;)' </pre><p> Compiled with gcc 4.7.3 </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/9114 Trac 1.4.3 ruslan_baratov@… Sun, 15 Sep 2013 16:14:13 GMT <link>https://svn.boost.org/trac10/ticket/9114#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/9114#comment:1</guid> <description> <p> I've found some misprints in documentation, you can get patch from github: </p> <pre class="wiki">github.com/ruslo/spirit/commit/2a993fe17ec8e12d75036f0c42805b943d665c1f </pre> </description> <category>Ticket</category> </item> </channel> </rss>