svn rev #19169: trunk/src/ include/ lib/crypto/crc32/ lib/gssapi/krb5/ lib/gssapi/mechglue/ ...

Ken Raeburn raeburn at MIT.EDU
Mon Feb 19 15:59:13 EST 2007

On Feb 19, 2007, at 11:42, Chaskiel M Grundman wrote:
> It isn't an error to use a non-const object in a const parameter,  
> and the
> compiler would be wrong to treat it as such. What is an error is  
> for the
> definition of a function to be different from any of it's  
> declarations (or
> prototypes). That seems to be what this patch is changing.

No, I believe that's okay as well.  I can't find my copy of C89 at  
the moment, and C89 is *mostly* what we require, but the C99 spec  
says of multiple declarations of a function that corresponding  
parameters are required to have compatible types, BUT:

"In the determination of type
compatibility and of a composite type, each parameter declared with  
function or array
type is taken as having the adjusted type and each parameter declared  
with qualified type
is taken as having the unqualified version of its declared type."

I think C89 said something similar, but I may be mistaken.


More information about the krbdev mailing list