Boost logo

Boost :

From: Yitzhak Sapir (yitzhaks_at_[hidden])
Date: 2002-07-17 09:02:15

> From: Beman Dawes [mailto:bdawes_at_[hidden]]
> At 08:44 AM 7/16/2002, Peter Dimov wrote:
> >FWIW, I always prefix my win32 calls with :: as a matter of style.
> I'm neutral. If others think it is a good idea, I'd have no problem
> changing.
> The "::" seems to say, in effect, "yes, I've considered
> namespaces, and
> definitely want the global (vendor supplied) version of this
> function."
> Are there other considerations?

Besides the other points people mentioned, in MFC classes, a lot of functions have names exactly the same as the APIs. So if you'd want to differentiate for any reason (not sure you'd have any, but it's always nice to be able to access the original function rather than a wrapper method) between an API and an MFC class function in a CWindow member function, for example, it is necessary to use the :: to denote global scope and just Functionname for local scope. This point doesn't apply to file systems, but it might be a reason to use :: for APIs as a matter of style in general.

Boost list run by bdawes at, gregod at, cpdaniel at, john at