This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils 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: arm-elf patch for 2.12


> On Thu, Mar 21, 2002 at 10:50:53AM +0000, Richard Earnshaw wrote:
> > > --target=arm-elf doesn't build without this patch. Just a typo.
> > > 
> > > 2002-03-20  Albert Chin-A-Young  <china@thewrittenword.com>
> > > 
> > > 	* gas/config/tc-arm.c: Fix typo (vfp_sp_reg_pos ->
> > > 	  vfp_dp_reg_pos) for vfp_dp_reg_required_here().
> > > 
> > 
> > I was at a loss to understand why this hadn't been caught before, until I 
> > noted that gcc fails to diagnose this problem.  I've filed a gcc bug 
> > report on it as well.
> 
> I'd lay money they'll tell you it's a feature.  If the function was
> actually prototyped, and the PARAMS (()) did not match the declaration,
> that would be reported; but for a non-prototyped function you have more
> leeway.

But the function is prototyped.  See gcc PR c/6024.

Basically, gcc accepts the following without either a warning or an error 
(unless you use -fshort-enums; even then it only complains if the sizes of 
the enums differ):

enum e1 {a, b=1001};
enum e2 {c, d};

void f(enum e1);

void f(x)
  enum e2 x;
{
  return;
}

R.


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