basix_doc 0.1
iterator_test.cpp
/******************************************************************************
* MODULE     : iterator_test.cc
* DESCRIPTION: Test iterators
* COPYRIGHT  : (C) 2003  Joris van der Hoeven
*******************************************************************************
* This software falls under the GNU general public license and comes WITHOUT
* ANY WARRANTY WHATSOEVER. See the file $TEXMACS_PATH/LICENSE for more details.
* If you don't have this file, write to the Free Software Foundation, Inc.,
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
******************************************************************************/

#include <basix/vector.hpp>
using namespace mmx;

int
main () {
  iterator<int> it1;
  mmout << "it1\t= " << it1 << "\n";
  iterator<int> it2= seq (1, 2, 3);
  mmout << "it2\t= " << it2 << "\n";
  iterator<int> it3= seq (3, 7) * seq (2, 3, 4) * seq (3);
  iterator<int> it4= it3;
  mmout << "it3\t= " << it3 << "\n";
  mmout << "it4\t= " << it4 << "\n";
  --it4; --it4; --it4;
  mmout << "it4'\t= " << it4 << "\n";
  iterator<int> it5= range_iterator<int> (0, 100);
  mmout << "it5\t= " << it5 << "\n";
  iterator<double> it6= as<iterator<double> > (range_iterator<int> (0, 10));
  mmout << * ++it6 << "\n";
  return 0;
}
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines