Ticket #3645: minimal_boost.cc
| File minimal_boost.cc, 419 bytes (added by , 13 years ago) |
|---|
| Line | |
|---|---|
| 1 | # include <boost/iterator/iterator_facade.hpp> |
| 2 | |
| 3 | struct s {}; |
| 4 | |
| 5 | template <class T, class U> |
| 6 | void implicit_cast(U) {} |
| 7 | |
| 8 | struct iter : |
| 9 | public boost::iterator_facade< |
| 10 | iter |
| 11 | , s |
| 12 | , boost::forward_traversal_tag |
| 13 | > |
| 14 | { |
| 15 | void increment() {} |
| 16 | bool equal(iter const&) const { return true; } |
| 17 | s& dereference() const { return s_; } |
| 18 | mutable s s_; |
| 19 | }; |
| 20 | |
| 21 | int main() |
| 22 | { |
| 23 | iter i; |
| 24 | i.operator->(); |
| 25 | } |
