From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19180 invoked by alias); 15 Apr 2011 03:44:31 -0000 Received: (qmail 19171 invoked by uid 22791); 15 Apr 2011 03:44:31 -0000 X-SWARE-Spam-Status: No, hits=-2.6 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RFC_ABUSE_POST X-Spam-Check-By: sourceware.org Received: from mail-gw0-f41.google.com (HELO mail-gw0-f41.google.com) (74.125.83.41) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 15 Apr 2011 03:44:26 +0000 Received: by gwaa12 with SMTP id a12so1302335gwa.0 for ; Thu, 14 Apr 2011 20:44:26 -0700 (PDT) Received: by 10.91.67.7 with SMTP id u7mr2220578agk.103.1302839066112; Thu, 14 Apr 2011 20:44:26 -0700 (PDT) MIME-Version: 1.0 Received: by 10.90.183.15 with HTTP; Thu, 14 Apr 2011 20:44:06 -0700 (PDT) In-Reply-To: References: <1302219156-9055-1-git-send-email-vapier@gentoo.org> From: Mike Frysinger Date: Fri, 15 Apr 2011 03:44:00 -0000 Message-ID: Subject: Re: [toolchain-devel] [PATCH] gdb: sim: add command line completion To: Tom Tromey Cc: toolchain-devel@blackfin.uclinux.org, gdb-patches@sourceware.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 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-04/txt/msg00217.txt.bz2 On Thu, Apr 14, 2011 at 16:01, Tom Tromey wrote: > Mike Frysinger writes: >> +char **sim_command_completer (struct cmd_list_element *ignore, >> + =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 char *text, char *word) > > I think this could be static. > And, newline after the initial "char **". np, updated patch should fix that and one or two other style things. ive committed that. > I don't really know anything about sim, but I didn't see anything > obviously bad in there. =C2=A0So, ok with the above change. well, it works for me :) side note that i meant to ask about earlier, i noticed that i cant complete things that have a dash in its name. seems because of readline having this marked as a word break char (which is understandable as it is usually used in math expressions). any way around this ? e.g. if i do: (gdb) sim h i get back: help hw-board-file hw-device hw-file hw-info hw-list hw-trace and so if i do: (gdb) sim hw it goes to "hw-", but now if i hit , i get nothing back. in the completer, the word is set to "" and the text is "hw-" ... -mike