This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


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

Re: Built-in bzero in GCC 3.0.2


> Date: Sun, 04 Nov 2001 21:13:55 -0800
> From: Mark Mitchell <mark@codesourcery.com>
> >
> > Could someone please tell what prototype of bzero does GCC expect?
> > More generally, how can one know what prototypes does GCC expect from
> > functions it treats as built-in?
> 
> Unfortunately, you have to look at the source.  (It would be nice
> if the error message told you what it expected.)

Yes, it would be very nice if GCC would tell, like it does with other
cases of conflicting declarations.  Is it possible to add this in
some future release?

> The 4th parameter is the interesting one; it says that the function
> is expected to take a "traditional pointer" (i.e., `char *' in
> traditional mode and `void *' normally) and a length (i.e., size_t)
> and return `void'.  Your declaration returns `void *' which is probably
> the problem.

Yes, the return type seems to be the problem.  Thanks.


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