From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21417 invoked by alias); 19 May 2003 22:10:34 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 21397 invoked by uid 48); 19 May 2003 22:10:33 -0000 Date: Mon, 19 May 2003 22:10:00 -0000 Message-ID: <20030519221033.21396.qmail@sources.redhat.com> To: gcc-bugs@gcc.gnu.org, gcc-prs@gcc.gnu.org, jmortensen@cfl.rr.com, nobody@gcc.gnu.org From: bangerth@dealii.org Reply-To: bangerth@dealii.org, gcc-bugs@gcc.gnu.org, gcc-prs@gcc.gnu.org, jmortensen@cfl.rr.com, nobody@gcc.gnu.org, gcc-gnats@gcc.gnu.org Subject: Re: c/10875: There is no multiple symbol definition error or warning for global symbols X-SW-Source: 2003-05/txt/msg02122.txt.bz2 List-Id: Synopsis: There is no multiple symbol definition error or warning for global symbols State-Changed-From-To: open->closed State-Changed-By: bangerth State-Changed-When: Mon May 19 22:10:33 2003 State-Changed-Why: The code is not legal, but the standard says that no diagnostic is required. If you want to complain anywhere, do so with the binutils guys. They maintain the linker. Most frequently, though, the answer will probably be "Don't do it". The reason being that the linker will usually warn you if a symbol has different size, but "int" and "int*" often have the same size, and then the linker can't really do anything about it. W. http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=10875