Eclipse (Luna, 4.4.2) tells me that I have a syntax error on the following line:
static_cast<Vec<int, DIM>>(a.mul(b)); I remembered that double closing angle brackets >> can lead to problems with some compilers, so I put a blank in between: > >. The syntax error disappears.
However, I have many >> in my program where no syntax error is detected, such as:
Node<Element<DIM>> * e= a.get(); Why do I get an error the above mentioned specific case? This is related to error: 'varName' was not declared in this scope, but I don't know why my compiler does accept a >> sometimes, but not always.
operator>>()for pre c++11 standard compilers.>>>doesn't fall into that parsing case, thus it works.>>>case which is misleading. But there are still several>>cases in my program which do not lead to a syntax error. Your post does not say anything whether>>does lead to problems in any or in specific cases, and that's what I'm wondering about.*could also make well a difference for the parser. Essentially it boils down to that mentioned ambiguity withoperator>>.>>, thus> >...