------- Comment #3 from rguenth at gcc dot gnu dot org  2007-09-30 11:37 -------
The usual error that happens with expression templates is that you return a
reference to a temporary object, using it after its lifetime ended.  What
you then can observe is that if you inline enough the error goes away.

But this is just a wild guess.  Instead you need to track this down further
to a smaller testcase (without the complete expression template machinery).

Oh, and the testcase crashes with -O2 for me; with gcc 4.0, 4.1, 4.2 and trunk.
It doesn't build with 3.4, so I didn't verify there.  It already crashes with

void matrixOps()
{
  EiMatrix<int, 2, 3> a, b;
  a = a + b;
}

my bet would be a bug in your code.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |WAITING


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33599

Reply via email to