Discussion:
[boost] Dependency report
Peter Dimov via Boost
2017-07-17 12:04:47 UTC
Permalink
I haven't run one of these in a while, so here it is.

http://pdimov.com/tmp/report-develop-6db78a0a6/module-overview.html
http://pdimov.com/tmp/report-develop-6db78a0a6/module-levels.html
http://pdimov.com/tmp/report-develop-6db78a0a6/module-weights.html

We have one "supermodule" at level 5 and another at level 13.

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Peter Dimov via Boost
2017-07-17 13:29:01 UTC
Permalink
Post by Peter Dimov via Boost
http://pdimov.com/tmp/report-develop-6db78a0a6/module-levels.html
One obvious low-hanging fruit here is moving <boost/next_prior.hpp> from
utility to iterator, breaking the utility -> iterator edge; I think this was
discussed recently?


_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Andrey Semashev via Boost
2017-07-17 17:46:25 UTC
Permalink
Post by Peter Dimov via Boost
Post by Peter Dimov via Boost
http://pdimov.com/tmp/report-develop-6db78a0a6/module-levels.html
One obvious low-hanging fruit here is moving <boost/next_prior.hpp> from
utility to iterator, breaking the utility -> iterator edge; I think this
was discussed recently?
I don't think it was (or may be I missed it).

Strictly speaking, boost::next/prior is not tied to iterators; it is
compatible with any type that has the necessary operators (e.g.
integers). Although the use case with iterators is probably the most
frequent.

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Michel Morin via Boost
2017-07-18 00:44:51 UTC
Permalink
Post by Andrey Semashev via Boost
Strictly speaking, boost::next/prior is not tied to iterators; it is
compatible with any type that has the necessary operators (e.g. integers).
Is it possible to deprecate the use of boost::next/prior for non-iterator types?
For non-iterator types, boost::next requires op+ or op+= (and similarly
boost::prior requires op- or op-=).
I think we can just use op+, unless the type has op+= but not op+.

Regards,
Michel

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Andrey Semashev via Boost
2017-07-18 08:33:54 UTC
Permalink
Post by Michel Morin via Boost
Post by Andrey Semashev via Boost
Strictly speaking, boost::next/prior is not tied to iterators; it is
compatible with any type that has the necessary operators (e.g. integers).
Is it possible to deprecate the use of boost::next/prior for non-iterator types?
It is possible, but I'm not sure why we would do that. What is the
problem that we're trying to solve?

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Michel Morin via Boost
2017-07-18 11:39:25 UTC
Permalink
Post by Michel Morin via Boost
Is it possible to deprecate the use of boost::next/prior for non-iterator types?
It is possible, but I'm not sure why we would do that. What is the problem
that we're trying to solve?
If Utility's dependency on Iterator is a problem,
the deprecation can help to move boost::next/prior to Iterator.
But the dependency is not a problem for me...

Regards,
Michel

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Peter Dimov via Boost
2017-07-24 17:15:22 UTC
Permalink
Post by Andrey Semashev via Boost
Post by Michel Morin via Boost
Is it possible to deprecate the use of boost::next/prior for non-iterator types?
It is possible, but I'm not sure why we would do that. What is the
problem that we're trying to solve?
If Utility's dependency on Iterator is a problem, the deprecation can help
to move boost::next/prior to Iterator.
Yes please, let's move next_prior.hpp to Iterator while we're on this topic.
This dependency is not the end of the world by any means, but it would still
be a small step in the right direction.

It's true that next/prior are not limited to iterators, and that's fine,
there's no need to deprecate their use for non-iterators.


_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Michel Morin via Boost
2017-07-17 22:11:49 UTC
Permalink
Post by Peter Dimov via Boost
One obvious low-hanging fruit here is moving <boost/next_prior.hpp> from
utility to iterator, breaking the utility -> iterator edge; I think this was
discussed recently?
I posted a related thread last month during the discussion on
IteratorTraversalCategory-aware boost::advance (at that time,
I didn't know that boost::next/prior is not only for iterators),
but I got no response:

[boost] [iterator][utility] Move utility/next_prior.hpp to Iterator module?
https://lists.boost.org/Archives/boost/2017/06/236656.php

Regards,
Michel

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Edward Diener via Boost
2017-07-17 22:37:43 UTC
Permalink
Post by Michel Morin via Boost
Post by Peter Dimov via Boost
One obvious low-hanging fruit here is moving <boost/next_prior.hpp> from
utility to iterator, breaking the utility -> iterator edge; I think this was
discussed recently?
I posted a related thread last month during the discussion on
IteratorTraversalCategory-aware boost::advance (at that time,
I didn't know that boost::next/prior is not only for iterators),
[boost] [iterator][utility] Move utility/next_prior.hpp to Iterator module?
https://lists.boost.org/Archives/boost/2017/06/236656.php
The change pushed by Andrey was to have iterator not use boost::prior
rather than to move boost/next_prior.hpp to iterator.
Post by Michel Morin via Boost
Regards,
Michel
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Michel Morin via Boost
2017-07-18 00:45:49 UTC
Permalink
The change pushed by Andrey was to have iterator not use boost::prior rather
than to move boost/next_prior.hpp to iterator.
Right, that change is to cut the cyclic dependency between boost/next_prior.hpp
and boost/iterator/reverse_iterator.hpp.

Andrey also pushed the change where boost/next_prior.hpp started to use
boost/iterator/advance.hpp.

Regards,
Michel

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
Loading...