--- Comment #7 from rguenth at gcc dot gnu dot org 2009-04-17 20:49 ---
g++-4.3 -S t.C
t.C:21: error: could not convert template argument MatrixBase::M to unsigned
int
t.C:21: error: could not convert template argument MatrixBase::N to unsigned
int
t.C: In member function const
--- Comment #6 from stephanemarcotte at 3d-p dot com 2009-04-17 15:45
---
the template also declares the methods M() and N(), when M, N are also template
parameters. (The code snippet is obviously buggy.)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39797
--- Comment #5 from stephanemarcotte at 3d-p dot com 2009-04-17 15:41
---
Also, if I remove the derivation from the MatrixBase abstract base class, the
error disappears.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39797
--- Comment #4 from paolo dot carlini at oracle dot com 2009-04-17 15:40
---
I can reproduce only with 4_2-branch (no longer maintained) and 4_3-branch. I
can't with 4_4-branch and mainline.
--
paolo dot carlini at oracle dot com changed:
What|Removed
--- Comment #3 from stephanemarcotte at 3d-p dot com 2009-04-17 15:38
---
Isolate to the method:
Matrix::Matrix & operator*=( double f ) ...
The template takes 2 args, but the above makes g++ crash. If I take out one
parameter (e.g., Matrix), then I get a compiler error as expected.
--- Comment #2 from stephanemarcotte at 3d-p dot com 2009-04-17 15:27
---
Created an attachment (id=17652)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17652&action=view)
the .ii file
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39797
--- Comment #1 from stephanemarcotte at 3d-p dot com 2009-04-17 15:27
---
Created an attachment (id=17651)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17651&action=view)
Source file
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39797