From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19051 invoked by alias); 26 Sep 2002 20:57:03 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 19044 invoked from network); 26 Sep 2002 20:57:03 -0000 Received: from unknown (HELO crack.them.org) (65.125.64.184) by sources.redhat.com with SMTP; 26 Sep 2002 20:57:03 -0000 Received: from nevyn.them.org ([66.93.61.169] ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 17ugcx-00076i-00; Thu, 26 Sep 2002 16:56:55 -0500 Received: from drow by nevyn.them.org with local (Exim 3.35 #1 (Debian)) id 17ufhE-00013y-00; Thu, 26 Sep 2002 16:57:16 -0400 Date: Thu, 26 Sep 2002 13:57:00 -0000 From: Daniel Jacobowitz To: Andrew Cagney Cc: gdb@sources.redhat.com Subject: Re: RFC: Additional testsuite alternative Message-ID: <20020926205716.GA3911@nevyn.them.org> Mail-Followup-To: Andrew Cagney , gdb@sources.redhat.com References: <20020916192546.GA6174@nevyn.them.org> <3D937279.7060304@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3D937279.7060304@redhat.com> User-Agent: Mutt/1.5.1i X-SW-Source: 2002-09/txt/msg00453.txt.bz2 On Thu, Sep 26, 2002 at 04:47:53PM -0400, Andrew Cagney wrote: > > >Source file two.cc: > >=== > >struct OneStruct { > > int simple; > >}; > >struct OneStruct StrOne; > >const struct OneStruct *ConstStrOnePtr; > > > >int FunctionWithPtrs (const struct OneStruct *one, const int *two) > >{ > > return 0; > >} > > > >int > >main () > >{ > > return 0; > >} > > The nice thing about GCC's framework is that it is a single C file. Is > the same possible here? Comments would indicate where to set > breakpoints and what values to print. > > The test then involves running the program, and for each breakpoint, > printing and checking the output. I thought about it and decided it wasn't worthwhile. That works on GCC: You run GCC, you get output based on particular lines. GDB has a source and then a session. So I have two files; one is source, the other is the session. > (How would this .x file handle regular expressions? That is the one > thing I never figured out with the GCC framework.) It just works :) It's a little awkward for complex expressions but works just fine for the simple cases I needed it for. The response to a #test directive is a regex. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer