|
From: | Scott Haney |
Subject: | Re: [pooma-dev] goofy Domain constructors |
Date: | Mon, 2 Apr 2001 11:07:02 -0600 |
Julian> members from a templated base class. These members are
Julian> not visible under the C++ lookup rules, so you have to
Julian> qualify these with the "this" pointer (or with the base
Julian> class name for static members).
I don't understand this. The funny lookup rules only apply to types;
data members should work fine. For example, this is legal:
template <typename T>
struct A { int i; };
template <typename T>
struct B : public A<T> {
void f() { i = 3; }
};
However, your changes still aren't a bad idea; the standard says that
if there was a global `i', the code in B would use that *rather* than
the base class version.
[Prev in Thread] | Current Thread | [Next in Thread] |