[PATCH] For SGI stl_algo.h extensions (was: Re: [RFC] Moving apart SGI extensions)
Gabriel Dos Reis
gdr@codesourcery.com
Fri Dec 28 02:41:00 GMT 2001
Paolo Carlini <pcarlini@unitus.it> writes:
[...]
| > +namespace __gnu_cxx
| > > +{
| > [...]
| > > + typename std::iterator_traits<_InputIter>::value_type >)
| >
| > Here's a question from a discussion we're having where I am: should
| > this be ::std::iterator_traits instead, or is the code legit as stands?
| > (I know it passes the testsuite and all, but a few people here feel that's
| > a compiler problem.)
| >
| > That wasn't a very clear question, but I'm having a hard time explaining
| > the problem. :-)
|
| I don't know sufficiently well this technical detail to meaningfully comment on
| this. Again, the patch I'm about to submit will have simply std::, not ::std:: My
| feeling, however is that you are right, in that, conceptually, in order to get to
| stuff inside std:: from __gnu_cxx first you have to exit from __gnu_cxx, then
| enter inside std::
| Right?
Both __gnu_cxx:: and std:: are members of the global scope, and names
from global scope are visible in both std:: or __gnu_cxx::. In order
words, the code is good as is and no need for "::" prefix.
-- Gaby
CodeSourcery, LLC http://www.codesourcery.com
More information about the Libstdc++
mailing list