Bug 36307 - __attribute__((deprecated)) does not work for member templates
Summary: __attribute__((deprecated)) does not work for member templates
Status: RESOLVED DUPLICATE of bug 33911
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 4.3.1
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
Depends on:
Reported: 2008-05-23 07:23 UTC by Oliver Sander
Modified: 2008-12-28 03:17 UTC (History)
5 users (show)

See Also:
Known to work:
Known to fail:
Last reconfirmed:


Note You need to log in before you can comment on or make changes to this bug.
Description Oliver Sander 2008-05-23 07:23:03 UTC
The following could should produce a warning but it doesn't.

struct Foo
    template <class Bar>
    void foo() __attribute__((deprecated));

template <class Bar>
void Foo::foo() {}

int main ()
    Foo f;

My compiler is
g++-4.3 (Debian 4.3.0-3) 4.3.1 20080401 (prerelease)

This is a regression.  It works for

g++-3.3 (GCC) 3.3.6 (Debian 1:3.3.6-15)

It does not work for

g++-3.4 (GCC) 3.4.6 (Debian 3.4.6-6)
g++-4.1 (GCC) 4.1.3 20080114 (prerelease) (Debian 4.1.2-19)
g++-4.2 (GCC) 4.2.3 (Debian 4.2.3-5)
Comment 1 Andrew Pinski 2008-12-28 03:17:42 UTC

*** This bug has been marked as a duplicate of 33911 ***