
https://svn.lrde.epita.fr/svn/oln/trunk/milena Index: ChangeLog from Thierry Geraud <thierry.geraud@lrde.epita.fr> Add hint to tests. * tests/README: Add hint. * mln/util/pix.hh (operator rvalue): New. mln/util/pix.hh | 7 +++++++ tests/README | 11 +++++++++++ 2 files changed, 18 insertions(+) Index: tests/README --- tests/README (revision 1088) +++ tests/README (working copy) @@ -1,6 +1,17 @@ -*- outline -*- +* tests + +run, e.g.: + +cd tests/ +for i in *cc +do +echo $i +g++-4.1 -ansi -pedantic -W -Wall -Wextra -Wconversion -I.. $i +done + * compilation Index: mln/util/pix.hh --- mln/util/pix.hh (revision 1088) +++ mln/util/pix.hh (working copy) @@ -49,6 +49,7 @@ pix_(const Image<I>& ima, const mln_point(I)& p); const I& ima() const; const mln_point(I)& p() const; + operator mln_rvalue(I)() const; private: const I& ima_; const mln_point(I)& p_; @@ -86,6 +87,12 @@ return p_; } + template <typename I> + pix_<I>::operator mln_rvalue(I)() const + { + return ima_(p_); + } + // pix template <typename I>