27 #ifndef MLN_ACCU_LABEL_USED_HH
28 # define MLN_ACCU_LABEL_USED_HH
34 # include <mln/accu/internal/base.hh>
35 # include <mln/core/concept/meta_accumulator.hh>
36 # include <mln/math/max.hh>
37 # include <mln/value/next.hh>
38 # include <mln/fun/i2v/array.hh>
98 # ifndef MLN_INCLUDE_ONLY
100 template <
typename L>
107 template <
typename L>
112 label_used_.resize(1,
true);
115 template <
typename L>
120 if (label_used_.size() <= l)
123 label_used_(l) =
true;
126 template <
typename L>
132 max_size =
mln::math::max(other.to_result().size(), label_used_.size());
134 label_used_.resize(max_size,
false);
135 for (
unsigned i = 1; i < label_used_.size(); ++i)
136 label_used_(i) = label_used_(i) || other.to_result()(i);
139 template <
typename L>
141 const fun::i2v::array<bool>&
147 template <
typename L>
155 # endif // ! MLN_INCLUDE_ONLY
162 #endif // ! MLN_ACCU_LABEL_USED_HH