From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28190 invoked by alias); 30 May 2005 15:48:28 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 15744 invoked by uid 22791); 30 May 2005 15:33:45 -0000 Received: from cpe-144-131-104-16.nsw.bigpond.net.au (HELO takamaka.act-europe.fr) (144.131.104.16) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Mon, 30 May 2005 15:33:45 +0000 Received: by takamaka.act-europe.fr (Postfix, from userid 507) id 801C547959; Mon, 30 May 2005 14:52:27 +1000 (EST) Date: Mon, 30 May 2005 16:01:00 -0000 From: Joel Brobecker To: gdb-patches@sources.redhat.com Subject: [RFA] Add missing include dependency in exceptions.h Message-ID: <20050530045227.GB18760@adacore.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="/9DWx/yDrRhgMJTb" Content-Disposition: inline User-Agent: Mutt/1.4i X-SW-Source: 2005-05/txt/msg00634.txt.bz2 --/9DWx/yDrRhgMJTb Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-length: 822 Hello, See http://sources.redhat.com/ml/gdb-patches/2005-05/msg00601.html. The TRY_CATCH macro has a dependency on "uiout", which is declared in ui-out.h. Because this header is not included in exceptions.h, any file that uses this macro needs to include "ui-out.h". I think we should include "ui-out.h" in "exceptions.h" instead. This is what this patch does. Note that another alternative would be to add something like: extern struct ui_out *uiout; to exceptions.h. I personnaly think it would be ugly to sprinkle such extern declarations everywhere... 2005-05-30 Joel Brobecker * exceptions.h: Include ui-out.h. (ui_out): Remove declaration. * Makefile.in (exceptions_h): Add dependency on ui-out.h. Tested on x86-linux. OK to apply? Thanks, -- Joel --/9DWx/yDrRhgMJTb Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="uiout.diff" Content-length: 1055 Index: exceptions.h =================================================================== RCS file: /cvs/src/src/gdb/exceptions.h,v retrieving revision 1.14 diff -u -p -r1.14 exceptions.h --- exceptions.h 26 Apr 2005 05:03:36 -0000 1.14 +++ exceptions.h 30 May 2005 01:47:56 -0000 @@ -24,8 +24,7 @@ #ifndef EXCEPTIONS_H #define EXCEPTIONS_H -struct ui_out; - +#include "ui-out.h" #include /* Reasons for calling throw_exceptions(). NOTE: all reason values Index: Makefile.in =================================================================== RCS file: /cvs/src/src/gdb/Makefile.in,v retrieving revision 1.734 diff -u -p -r1.734 Makefile.in --- Makefile.in 29 May 2005 03:13:17 -0000 1.734 +++ Makefile.in 30 May 2005 01:48:06 -0000 @@ -672,7 +672,7 @@ dwarf2loc_h = dwarf2loc.h environ_h = environ.h event_loop_h = event-loop.h event_top_h = event-top.h -exceptions_h = exceptions.h +exceptions_h = exceptions.h $(ui_out_h) exec_h = exec.h $(target_h) expression_h = expression.h $(symtab_h) $(doublest_h) fbsd_nat_h = fbsd-nat.h --/9DWx/yDrRhgMJTb--