From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28162 invoked by alias); 8 Jul 2013 05:38:46 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 25951 invoked by uid 48); 8 Jul 2013 05:38:42 -0000 From: "glisse at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug driver/57784] GCC inadvertedly truncates source text Date: Mon, 08 Jul 2013 05:38:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: driver X-Bugzilla-Version: 4.7.2 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: glisse at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_severity Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-07/txt/msg00412.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57784 Marc Glisse changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|major |normal --- Comment #2 from Marc Glisse --- (In reply to Andrew Pinski from comment #1) > This is hard to fix and will not be fixed as gcc does not know it is writing > to a source file or a file you just happen to name to end with .cc . Uh, what's wrong about using a heuristic and refusing to compile when the name of the output file ends in .c, .C, .cc, .f90, etc (possibly unless some -fweird-output-name is also passed) and the file already exists?