From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10766 invoked by alias); 13 Dec 2011 03:41:33 -0000 Received: (qmail 10724 invoked by uid 22791); 13 Dec 2011 03:41:32 -0000 X-SWARE-Spam-Status: No, hits=-2.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW X-Spam-Check-By: sourceware.org Received: from mail-iy0-f169.google.com (HELO mail-iy0-f169.google.com) (209.85.210.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 13 Dec 2011 03:41:19 +0000 Received: by mail-iy0-f169.google.com with SMTP id k25so11422603iah.0 for ; Mon, 12 Dec 2011 19:41:18 -0800 (PST) Received: by 10.50.85.197 with SMTP id j5mr8422724igz.32.1323747678717; Mon, 12 Dec 2011 19:41:18 -0800 (PST) Received: from localhost.localdomain (c-24-18-115-186.hsd1.wa.comcast.net. [24.18.115.186]) by mx.google.com with ESMTPS id e2sm81168651ibe.0.2011.12.12.19.41.17 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 12 Dec 2011 19:41:18 -0800 (PST) From: Andrey Smirnov To: gdb-patches@sourceware.org Cc: Andrey Smirnov Subject: [PATCH 049/238] [index] completer.c: -Wshadow fix Date: Tue, 13 Dec 2011 03:41:00 -0000 Message-Id: <1323747545-29987-15-git-send-email-andrew.smirnov@gmail.com> In-Reply-To: <1323747545-29987-1-git-send-email-andrew.smirnov@gmail.com> References: <1323747545-29987-1-git-send-email-andrew.smirnov@gmail.com> X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2011-12/txt/msg00374.txt.bz2 To ChangeLog: * completer.c (line_completion_function): Rename `index' to `idx'(-Wshadow). --- gdb/completer.c | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/gdb/completer.c b/gdb/completer.c index 606f78b..55a4b7a 100644 --- a/gdb/completer.c +++ b/gdb/completer.c @@ -863,7 +863,7 @@ line_completion_function (const char *text, int matches, char *line_buffer, int point) { static char **list = (char **) NULL; /* Cache of completions. */ - static int index; /* Next cached completion. */ + static int idx; /* Next cached completion. */ char *output = NULL; if (matches == 0) @@ -881,7 +881,7 @@ line_completion_function (const char *text, int matches, xfree (list); list = NULL; } - index = 0; + idx = 0; list = complete_line (text, line_buffer, point); } @@ -893,10 +893,10 @@ line_completion_function (const char *text, int matches, if (list) { - output = list[index]; + output = list[idx]; if (output) { - index++; + idx++; } } -- 1.7.5.4