Boost logo

Boost Users :

From: Ed Johnson (ed_at_[hidden])
Date: 2006-06-01 16:09:52


Alexander Bell wrote:
> Ed Johnson <ed_at_[hidden]> writes:
>
>> I tried the code and got these compilation errors.
>
> sorry... iterator2 has to be initialised from "standard" begin() and end() of
> iterator1:
>
> typedef matrix<double> MatType;
> MatType m(3,3);
>
> for(MatType::iterator1 i1 = m.begin1(); i1!=m.end1(); ++i1)
> for(MatType::iterator2 i2 = i1.begin(); i2!=i1.end(); ++i2)
> *i2 = 2;
>
> this time I tested the code (g++ v. 4.02, boost 1.33.1).
>
> Hope that helps,
>
> Alexander.

Thanks. Unfortunately, it doesn't compile for me on Visual Studio.
(VS 7.1, boost 1.33.1)

c:\workspace\hivm\trunk\src\test\PreProcessorTest.cpp(516): error C2039:
'begin' : is not a member of 'boost::numeric::ublas::matrix<T>::iterator1'
        with
        [
            T=double
        ]

c:\workspace\hivm\trunk\src\test\PreProcessorTest.cpp(516): error C2039:
'end' : is not a member of 'boost::numeric::ublas::matrix<T>::iterator1'
        with
        [
            T=double
        ]


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net