From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30844 invoked by alias); 15 Nov 2009 17:26:26 -0000 Received: (qmail 30636 invoked by uid 22791); 15 Nov 2009 17:26:23 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 15 Nov 2009 17:25:19 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 9A25510E9F; Sun, 15 Nov 2009 17:25:14 +0000 (GMT) Received: from caradoc.them.org (209.195.188.212.nauticom.net [209.195.188.212]) by nan.false.org (Postfix) with ESMTP id 3C03D1086E; Sun, 15 Nov 2009 17:25:14 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.69) (envelope-from ) id 1N9iqc-0006VF-UP; Sun, 15 Nov 2009 12:25:10 -0500 Date: Sun, 15 Nov 2009 17:26:00 -0000 From: Daniel Jacobowitz To: Paul Pluzhnikov Cc: Andreas Schwab , gdb-patches@sourceware.org Subject: Re: [patch] Allow "disassemble 'Foo::bar(char *)'" Message-ID: <20091115172510.GA23483@caradoc.them.org> Mail-Followup-To: Paul Pluzhnikov , Andreas Schwab , gdb-patches@sourceware.org References: <20091114001022.A0A0776CDD@ppluzhnikov.mtv.corp.google.com> <8ac60eac0911150916k70ac0f62hf349b0bc21aa58b7@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8ac60eac0911150916k70ac0f62hf349b0bc21aa58b7@mail.gmail.com> User-Agent: Mutt/1.5.20 (2009-06-14) 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: 2009-11/txt/msg00333.txt.bz2 On Sun, Nov 15, 2009 at 09:16:06AM -0800, Paul Pluzhnikov wrote: > The only way I can see to allow general expressions here is to require > a separator which can't happen in any expression in any language > (semicolon probably comes close), or for parse_expression() to consume > as much as it can and set a "end_of_parse" indicator. > > But perhaps splitting on comma (after skipping any quoted expression > -- Foo::bar could have multiple parameters) is "good enough"? That > would allow 'disas &main + 1, &main + 5' to work. See parse_to_comma_and_eval (which I always forget about in this situation...). It's not perfect, but it does handle parenthesis nesting. -- Daniel Jacobowitz CodeSourcery