From patchwork Tue Jan 3 05:28:57 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexandre Oliva X-Patchwork-Id: 710375 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3tt2bL54Gsz9svs for ; Tue, 3 Jan 2017 16:30:38 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="M8JxDSak"; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:mime-version:content-type; q=dns; s= default; b=O2dDFaAOu7NW/huI/99V+cTqkI/bpAuE8P37bc/CvgLNS9V+lIZ4P xAXkavMhU0giQ0+MmUl3SIwVPOwtMUvRxpY2BzYzRlBUdbAsr1BZnlZzd+LsKNHn jaOWeJD7MY+g/T29r9EIdnpjM2hRHw8t+YhiBsMdl9dayz5gpCsW4g= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:mime-version:content-type; s= default; bh=WOKpiIb5cJmqp/3Z0cB9bOE/kvI=; b=M8JxDSak6odRFME0Ftag Nl5E4n9AzlwTKxsS6ysdRxd1zDLLeFyBuKx/mdlCNzebSC+u4fdERS8wFf1FQccT U2WUIW7h1o5DbApxMSm0yO2TMYfO489aVl1xxFI4qcBUWa1nkLT34vcdbAOTCidP HBPmSnknoP4J034xgOCpQCU= Received: (qmail 15426 invoked by alias); 3 Jan 2017 05:29:23 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 15314 invoked by uid 89); 3 Jan 2017 05:29:22 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-5.1 required=5.0 tests=BAYES_00, RP_MATCHES_RCVD, SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=inputc, UD:input.c, input.c, america X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 03 Jan 2017 05:29:12 +0000 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 173607F7A5 for ; Tue, 3 Jan 2017 05:29:12 +0000 (UTC) Received: from freie.home (ovpn04.gateway.prod.ext.phx2.redhat.com [10.5.9.4]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id v035TArm019443 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Tue, 3 Jan 2017 00:29:11 -0500 Received: from livre (livre.home [172.31.160.2]) by freie.home (8.15.2/8.15.2) with ESMTP id v035SvuA011481; Tue, 3 Jan 2017 03:28:57 -0200 From: Alexandre Oliva To: gcc-patches@gcc.gnu.org Subject: [bootstrap-O3] add a default initializer to avoid a warning at -O3 Date: Tue, 03 Jan 2017 03:28:57 -0200 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) MIME-Version: 1.0 Building with the bootstrap-O3 configuration option fails to compile input.c due to an AFAICT false-positive warning about an uninitialized use of a variable. This patch adds a default initializer to silence it. Regstrapped on x86_64-linux-gnu and i686-linux-gnu. OK to install? for gcc/ChangeLog * input.c (assert_char_at_range): Default-initialize actual_range. --- gcc/input.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/input.c b/gcc/input.c index dcb5101..a478873 100644 --- a/gcc/input.c +++ b/gcc/input.c @@ -2168,7 +2168,7 @@ assert_char_at_range (const location &loc, cpp_reader *pfile = test.m_parser; string_concat_db *concats = &test.m_concats; - source_range actual_range; + source_range actual_range = source_range(); const char *err = get_source_range_for_char (pfile, concats, strloc, type, idx, &actual_range);