This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: New ARI warning Sat Mar 12 01:53:29 UTC 2011


> From: "Pierre Muller" <pierre.muller@ics-cnrs.unistra.fr>
> Date: Sun, 13 Mar 2011 09:21:35 +0100
> 
>   This is the consequence of the two new ARI rules I added:
> http://sourceware.org/ml/gdb-patches/2011-03/msg00654.html
> 
>   As I just introduced these new rules,
> I felt that it would be cheating to
> use OBVIOUS rule as we normally do to fix 
> a ARI regression...
>   This is why I will submit shortly two patches
> to remove all those new warnings.

The rule to detect "()" without a "void" is fine, but why on Earth do
we need the other rule, about prototypes like this:

  int
  foo (bar);

This is a perfectly valid formatting.  In your patch, you modify long
prototypes like this as follows:

   extern struct hppa_objfile_private *
  -hppa_init_objfile_priv_data (struct objfile *objfile);
  +  hppa_init_objfile_priv_data (struct objfile *objfile);

But that is not a good idea, because if you type TAB in Emacs on the
line with the function name, Emacs will reindent the name to column
zero.  So I expect this rule to annoy us quite a bit, e.g. if someone
reindents a large region.

Can you tell why we need this?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]