Boost C++ Libraries: Ticket #7526: zip_iterator does not support std::tuple and std::pair https://svn.boost.org/trac10/ticket/7526 <p> The boost zip_iterator is not compatible with std::tuple and std::pair </p> <p> The proposed patch solves this problem. </p> <p> Note that I copied some more general tuple algorithms I created for another project. These are all included in the newly introduced namespace helper. Maybe they can be rewritten using boost::mpl, but since I am not familiar with it I used the existing code. </p> <p> Furthermore I encountered the problem, that a specialisation of the template functions in namespace tuple_impl_specific does not work, if this is done outside zip_iterator.hpp. The reason appears to be, that the user overloads are not known to the compiler, when the functions are called. This may be a problem, if users want to specialise for their own tuple class. To overcome this difficulty, I replaced the template functions by template classes, which seem to work even if specialisations are made outside zip_iterator.hpp </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/7526 Trac 1.4.3 claas.koehler@… Thu, 18 Oct 2012 10:06:54 GMT attachment set https://svn.boost.org/trac10/ticket/7526 https://svn.boost.org/trac10/ticket/7526 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">zip_iterator_diff.txt</span> </li> </ul> <p> diff of the patched zip_iterator file compared to the 1.50.0 version </p> Ticket claas.koehler@… Thu, 18 Oct 2012 11:44:39 GMT attachment set https://svn.boost.org/trac10/ticket/7526 https://svn.boost.org/trac10/ticket/7526 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">zip_iterator_diff.2.txt</span> </li> </ul> <p> diff of the patched zip_iterator file compared to the 1.50.0 version </p> Ticket Kohei Takahashi <flast@…> Thu, 18 Oct 2012 12:06:44 GMT cc set https://svn.boost.org/trac10/ticket/7526#comment:1 https://svn.boost.org/trac10/ticket/7526#comment:1 <ul> <li><strong>cc</strong> <span class="trac-author">flast@…</span> added </li> </ul> <p> How about use Boost.Fusion instead of Boost.Tuple? I'll attach 5 patches. </p> <p> First, bug7513.patch fixes <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/7513" title="#7513: Bugs: fusion::convert() tries to call convert_impl::call but there isn't (closed: fixed)">#7513</a>.<br /> boost_tuple-convert.patch adapts Boost.Tuple to Boost.MPL algorithms via Boost.Fusion.<br /> std_tuple-convert.patch similar to above one, but for std::tuple.<br /> zip_iterator.patch is main patch of this changes: rebase impl of zip_iterator to Boost.Fusion.<br /> Finally, std_pair-specialization.patch is specialization for std::pair. </p> <p> This changes have backward compatibility: iterator/zip_iterator.hpp includes fusion/adapted/boost_tuple.hpp implicitly. </p> Ticket Kohei Takahashi <flast@…> Thu, 18 Oct 2012 12:07:15 GMT attachment set https://svn.boost.org/trac10/ticket/7526 https://svn.boost.org/trac10/ticket/7526 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">bug7513.patch</span> </li> </ul> Ticket Kohei Takahashi <flast@…> Thu, 18 Oct 2012 12:07:32 GMT attachment set https://svn.boost.org/trac10/ticket/7526 https://svn.boost.org/trac10/ticket/7526 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">boost_tuple-convert.patch</span> </li> </ul> Ticket Kohei Takahashi <flast@…> Thu, 18 Oct 2012 12:07:48 GMT attachment set https://svn.boost.org/trac10/ticket/7526 https://svn.boost.org/trac10/ticket/7526 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">std_tuple-convert.patch</span> </li> </ul> Ticket Kohei Takahashi <flast@…> Thu, 18 Oct 2012 12:08:08 GMT attachment set https://svn.boost.org/trac10/ticket/7526 https://svn.boost.org/trac10/ticket/7526 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">zip_iterator.patch</span> </li> </ul> Ticket Kohei Takahashi <flast@…> Thu, 18 Oct 2012 12:08:20 GMT attachment set https://svn.boost.org/trac10/ticket/7526 https://svn.boost.org/trac10/ticket/7526 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">std_pair-specialization.patch</span> </li> </ul> Ticket Dave Abrahams Thu, 18 Oct 2012 14:33:42 GMT <link>https://svn.boost.org/trac10/ticket/7526#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:2</guid> <description> <p> FYI, there's a branch or tag somewhere way back in SVN history that does (mostly) the same thing. At the time, I think there were reasons not to apply it, and by now it's probably out-of-sync with Fusion in some subtle way, but it was well-organized at least, so it might be worth a look if you can find it. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>jeffrey.hellrung</dc:creator> <pubDate>Fri, 19 Oct 2012 02:31:35 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:3</guid> <description> <p> Re Fusion, I was thinking the same thing. Will have to take a closer look at the patches in the future to see if they align with what I'm thinking. And thanks for the FYI, Dave. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Dave Abrahams</dc:creator> <pubDate>Wed, 21 Nov 2012 22:40:28 GMT</pubDate> <title>owner changed https://svn.boost.org/trac10/ticket/7526#comment:4 https://svn.boost.org/trac10/ticket/7526#comment:4 <ul> <li><strong>owner</strong> changed from <span class="trac-author">Dave Abrahams</span> to <span class="trac-author">jeffrey.hellrung</span> </li> </ul> Ticket Aditya Ramesh <_@…> Sun, 04 May 2014 15:30:48 GMT <link>https://svn.boost.org/trac10/ticket/7526#comment:5 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:5</guid> <description> <p> Is there a target version for which these patches will be applied? Compatibility with std::tuple would be a very important feature to have, especially since compiler support for C++11 is now more widespread. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Sun, 25 May 2014 19:36:22 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:6</guid> <description> <p> Is there an ETA for when this gets applied? </p> </description> <category>Ticket</category> </item> <item> <author>Kohei Takahashi <flast@…></author> <pubDate>Tue, 27 May 2014 03:43:33 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:7 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:7</guid> <description> <p> Which do you think is better, <em>claas.koehler's</em> patch or Re Fusion? </p> </description> <category>Ticket</category> </item> <item> <author>claas.koehler@…</author> <pubDate>Tue, 27 May 2014 07:24:19 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:8 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:8</guid> <description> <p> I think the general agreement was, that the Fusion Patch is preferable, since my patch constitutes a quick and dirty solution only. That's why I never took any further attempts in submitting tests. </p> <p> However, since the Fusion patch has not been released, I have been using my version privately for quite a while now and patched every version of my local boost, because I require the functionality in several projects. I would prefer to stop doing this as soon as possible, of course. </p> <p> Maybe it would be good to poll in boost devel mailing list, why the patch has not been applied so far and then take the necessary steps to finally get it into production. </p> <p> My personal preference would be to apply Kohei Takashi's patch with the necessary testing, if it is working, regardless of any other old versions (see Jeffrey's comment 20 months ago). A good solution today is definitely better than a perfect one in another 20 months from my point of view. </p> <p> Regards Claas </p> </description> <category>Ticket</category> </item> <item> <author>Kohei Takahashi <flast@…></author> <pubDate>Thu, 29 May 2014 03:12:06 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:9 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:9</guid> <description> <p> OK. Now, I'm working for reimplementing zip_iterator as fusion based one in following branches. </p> <p> ttps://github.com/Flast/fusion/tree/pr/adapt/tuple <br /> ttps://github.com/Flast/iterator/tree/pr/zip_iterator/fusionize </p> <p> However, I have no idea for fusion::convert for non variadic template based std::tuple (i.e. msvc 11.0 or earlier). So, I will spent a little time to send PR. </p> </description> <category>Ticket</category> </item> <item> <author>Kohei Takahashi <flast@…></author> <pubDate>Sat, 14 Jun 2014 07:17:43 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:10 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:10</guid> <description> <p> I've submitted about Fusion based zip_iterator. Please review it. </p> <p> <a class="ext-link" href="https://github.com/boostorg/iterator/pull/2"><span class="icon">​</span>https://github.com/boostorg/iterator/pull/2</a> </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Edward Diener</dc:creator> <pubDate>Sun, 23 Aug 2015 12:56:18 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:11 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:11</guid> <description> <p> I have looked at the PR but found a problem when using the fusion container deque. Please take a look at my comments in the PR. I would like to move ahead with the PR, as I think it is valuable to allow this change, but I need a clarification of why it is failing with the fusion deque. </p> </description> <category>Ticket</category> </item> <item> <author>edaskel@…</author> <pubDate>Sun, 12 Mar 2017 23:21:41 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:12 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:12</guid> <description> <p> Looks like this has been fixed :) Close? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Edward Diener</dc:creator> <pubDate>Thu, 23 Mar 2017 09:40:24 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:13 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:13</guid> <description> <p> Yes, this has been fixed and should appear in upcoming release. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Fri, 16 Mar 2018 12:12:51 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:14 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:14</guid> <description> <p> up </p> </description> <category>Ticket</category> </item> <item> <author>edaskel@…</author> <pubDate>Fri, 16 Mar 2018 18:40:55 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7526#comment:15 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7526#comment:15</guid> <description> <p> Let's close this "fixed" :) </p> </description> <category>Ticket</category> </item> </channel> </rss>