This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/15910] can't compile self defined void distance(std::vector<T>, std::vector<T>)


------- Additional Comments From adah at netstd dot com  2005-08-04 05:27 -------
As the reporter of Bug 23213, I want to add my 2 cents (my opinions):

1) This bug is not in libstdc++, but in the C++ compiler.

2) The std::distance (as found by Koenig lookup) does not hide the global one 
the user defines, but the failure to complete the return type aborts the 
candidate building procedure (if we fake the type definitions required, the 
user-defined version will be correctly selected).  And SFINAE does not kick 
in.  I really cannot see why this is not a bug (providing something unrelated 
to user code will make the user code work!).

3) To complicate the matter, all "good" compilers I know fail in this case.  
However, I still believe it is the problem of the compilers.

Yongwei


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15910


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]