From: Joel Brobecker <brobecker@adacore.com>
To: Mark Kettenis <mark.kettenis@xs4all.nl>, gdb-patches@sourceware.org
Subject: Re: [commit] language.h minor cleanup
Date: Mon, 17 Dec 2007 14:22:00 -0000 [thread overview]
Message-ID: <20071217141045.GH9022@adacore.com> (raw)
In-Reply-To: <20071217132851.GA23128@caradoc.them.org>
[-- Attachment #1: Type: text/plain, Size: 845 bytes --]
> q.c:1: warning: ISO C forbids forward references to `enum' types
> If we use it elsewhere, we should stop.
Humpf, sorry about that. I have reverted this part of my patch
as follow:
2007-12-17 Joel Brobecker <brobecker@adacore.com>
* language.h (enum exp_opcode): Comment out this declaration,
undoing the previous change.
Re-tested on x86-linux with a full rebuild. The situation is not
completely fixed yet, but we can discuss our options.
In terms of other places where it is used, I thought there were
several but a quick grep revealed only two:
- language.h (our case, enum exp_opcode)
- symtab.h (enum language)
Unless my egrep command is wrong, I must have some delusional episodes:
% grep -E -e 'enum +[_0-9a-zA-Z]+;' **/*.h
I will send some patches ASAP.
--
Joel (UTC+4 for the next 5 weeks :-).
[-- Attachment #2: language.h.diff --]
[-- Type: text/plain, Size: 609 bytes --]
Index: language.h
===================================================================
RCS file: /cvs/src/src/gdb/language.h,v
retrieving revision 1.44
diff -u -p -r1.44 language.h
--- language.h 17 Dec 2007 07:00:49 -0000 1.44
+++ language.h 17 Dec 2007 14:04:59 -0000
@@ -30,7 +30,8 @@ struct objfile;
struct frame_info;
struct expression;
struct ui_file;
-enum exp_opcode;
+
+/* enum exp_opcode; ANSI's `wisdom' didn't include forward enum decls. */
/* This used to be included to configure GDB for one or more specific
languages. Now it is left out to configure for all of them. FIXME. */
prev parent reply other threads:[~2007-12-17 14:11 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-17 7:14 Joel Brobecker
2007-12-17 10:46 ` Mark Kettenis
2007-12-17 11:23 ` Joel Brobecker
2007-12-17 13:31 ` Daniel Jacobowitz
2007-12-17 14:22 ` Joel Brobecker [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20071217141045.GH9022@adacore.com \
--to=brobecker@adacore.com \
--cc=gdb-patches@sourceware.org \
--cc=mark.kettenis@xs4all.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox