|
Boost : |
From: Peter Dimov (pdimov_at_[hidden])
Date: 2004-02-17 07:01:53
Gabriel Dos Reis wrote:
> David Abrahams <dave_at_[hidden]> writes:
>
>
>> Shall we outlaw:
>>
>> struct Base { static int x; };
>>
>> struct Derived : Base {
>> void f(int x) {} // Horrors! we're masking a base class
>> member!
>
> If you happen to pause a second and have look at the issue at hand,
> I'm confident that you'll see the difference between the case we're
> discussing and your example.
>
>> };
I think that you win the consistency argument.
struct X
{
typedef void Y;
typedef void Z;
};
struct Y
{
};
template<class Z> struct V: public Y, public X
{
Y y; // X::Y
Z z; // X::Z
};
Very counter-intuitive since C++ code usually respects locality of
reference, but consistent.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk