On Sat, 2007-04-28 at 11:00 -0400, Jerry Feldman wrote:
No. this->i_key is equivalent to i_key in a member function. The issue is with the dual template arguments. i_key is defined in the base class as: ThisType const & i_key;
But the inheriting class does not include the ThisType template parameter. The correct solution, as I found out yesterday afternoon is to refer to i_key as fully qualified: FuBar<ItemType, type_t>::i_key;
That should also work because it makes i_key nondependent and I'm not surprised you spotted that one so quickly. Was there something about the context of i_key that made this->i_key not work? I don't think I've encountered a context in which it would fail, but it wouldn't surprise me if there are some. My instinct says we've found alternative solutions to the same problem. Mine avoids some problems with virtual function calls, but I suspect there is going to be some occasion when it won't work. -- JDL --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-programming+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-programming+help@opensuse.org