Notwithstanding #17470 :

[EMAIL PROTECTED] ~]$ cat foo.cc
template<class T>
class A {
    void foo() {};
};
#pragma GCC visibility push(default)
template<> void A<int>::foo() {};
#pragma GCC visibility pop
[EMAIL PROTECTED] ~]$ g++ -fvisibility-inlines-hidden -c foo.cc
foo.cc:6: warning: 'void A<T>::foo() [with T = int]': visibility attribute
ignored because it
foo.cc:3: warning: conflicts with previous declaration here

-- 
           Summary: Class visibility of templated classes can't be
                    overridden for function specializations
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: nomis80 at nomis80 dot org
                CC: gcc-bugs at gcc dot gnu dot org,s_gccbugzilla at nedprod
                    dot com


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

Reply via email to