This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
c++/2518: user-declared operator new hides standard one
- To: gcc-gnats at gcc dot gnu dot org
- Subject: c++/2518: user-declared operator new hides standard one
- From: igodard at rational dot com
- Date: 9 Apr 2001 16:00:20 -0000
- Cc: kcoleman at rational dot com
- Reply-To: igodard at rational dot com
>Number: 2518
>Category: c++
>Synopsis: user-declared operator new hides standard one
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: rejects-legal
>Submitter-Id: net
>Arrival-Date: Mon Apr 09 09:06:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator: Ivan Godard
>Release: 3.0 (Code Sorcery online; also 2.95)
>Organization:
>Environment:
>Description:
The declaration of a global 'operator new' causes the compiler to no longer recognize the standard 'new foo' syntax.
>How-To-Repeat:
int main() {
void* operator new(unsigned s, int* p);
int i;
int* e = new(&i) int;
int* f = new int;
return 0;
}
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted: