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 c++/51951] Template function dependent name resolution fails


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

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID

--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-01-22 23:48:56 UTC ---
14.6.4 Dependent name resolution [temp.dep.res]
-1- In resolving dependent names, names from the following sources are
considered:
â Declarations that are visible at the point of deïnition of the template.
â Declarations from namespaces associated with the types of the function
arguments both from the instantiation context (14.6.4.1) and from the deïnition
context.

readFromStream is a dependent name, no declaration is visible at the point of
definition of readSingle, bool has no associated namespaces so no declarations
from associated namespaces are considered, so the name is not found.  The code
is invalid.


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