This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/37047] New: Missing warning for deprecated use of static
- From: "gcc-bugzilla at contacts dot eelis dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Aug 2008 12:39:58 -0000
- Subject: [Bug c++/37047] New: Missing warning for deprecated use of static
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
In 7.3.1.1p2, the standard states "The use of the static keyword is deprecated
when declaring objects in a namespace scope", yet g++ does not warn about such
uses. Compiling the following snippet:
static int i;
int g() { return i; }
results in no diagnostics of any kind, not even with -std=c++98 -Wall -Wextra
-pedantic.
--
Summary: Missing warning for deprecated use of static
Product: gcc
Version: 4.4.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: gcc-bugzilla at contacts dot eelis dot net
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37047