[Bug c++/28317] template function returning nested class fails to compile when defined outside of its class

rguenth at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Sat Jul 8 18:20:00 GMT 2006



------- Comment #1 from rguenth at gcc dot gnu dot org  2006-07-08 18:20 -------
You are missing a 'typename'.  Inner is a dependent type, so it needs to read

    template <typename T>
    typename Outer<T>::Inner
    Outer<T>::get() const
    {
        return Inner();
    }


-- 

rguenth at gcc dot gnu dot org changed:

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


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



More information about the Gcc-bugs mailing list