At 08:11 PM 11/28/2002, David Abrahams wrote:
>> AFAIK, Metrowerks is correct, and the other compilers intend to detect
>these errors in the future.
>>
>> The fix is usually to add qualification. For example,
>foo::out_of_range_bit.
>
>The fix is usually to make sure that the appropriate declaration of a
>non-dependent name is visible before the name is used. Extra
>qualification doesn't usually help AFAICT.
>
>Oh, I guess that if the name is a member of a base class, then the fix
>is to write ``this->member_name'' or ``BaseClass::member_name''
>instead of just ``member_name''. That can be viewed as adding
>qualification.
Yes, that was the case that came up in other libraries.
> However, that doesn't _appear_ to be the problem in the
>case below, and in any case I recomment using ``this->'' when possible
>because it's more reliable.
Hum... I'll take your word for it, but to tell the truth I have trouble
understanding what either ``this->member_name'' or
`BaseClass::member_name'' adds. And the format library case wasn't a member
name at all, it was an enum name, IIRC.
I guess I need a C++ for dummies level description of why these names are
not visible, and why adding this-> or qualification makes the names
visible.
--Beman
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost
- [boost] Possible patch to format for Borland BCB5 Alisdair Meredith
- Re: [boost] Possible patch to format for Borland BC... Samuel Krempp
- [boost] Re: Possible patch to format for Borlan... Alisdair Meredith
- Re: [boost] Possible patch to format for Borlan... Beman Dawes
- Re: [boost] Possible patch to format for Bo... David Abrahams
- Re: [boost] Possible patch to format fo... Beman Dawes
- Re: [boost] Possible patch to form... David Abrahams
- Re: [boost] Possible patch to ... David Abrahams
- [boost] Re: Possible patch to format for Borlan... Alisdair Meredith
- RE: [boost] Possible patch to format for Borland BC... Aleksey Gurtovoy