| 40 | /// Print bound of a set view or variable |
| 41 | template<class Char, class Traits, class I> |
| 42 | void |
| 43 | printBound(std::basic_ostream<Char,Traits>& s, I& r) { |
| 44 | s << '{'; |
| 45 | while (r()) { |
| 46 | if (r.min() == r.max()) { |
| 47 | s << r.min(); |
| 48 | } else if (r.min()+1 == r.max()) { |
| 49 | s << r.min() << "," << r.max(); |
| 50 | } else { |
| 51 | s << r.min() << ".." << r.max(); |
| 52 | } |
| 53 | ++r; |
| 54 | if (!r()) break; |
| 55 | s << ','; |
| 56 | } |
| 57 | s << '}'; |
| 58 | } |
| 59 | |
| 60 | /// Print set view |
| 61 | template<class Char, class Traits, class IL, class IU> |