Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: src/sys/sys



On Sun, Jan 04, 2004 at 01:45:33PM +0100, Matthias Scheler wrote:
> On Sun, Jan 04, 2004 at 01:34:22PM +0100, Klaus Klein wrote:
> > Those are strong words being used in a weak argument.  There are
> > several instances of such headers available in NetBSD;
> 
> In that case all these are broken. I've already fixed such brokeness in the
> past and nobody ever complained.

They are only "broken" because you declare them "broken" for no technical
reason.

Maybe your other "fixes" have escaped me in the past.  Or maybe I didn't
have time to complain.  Could be either.  I don't check every commit for
reasonable ness.

However, your change is not in line with project policy with regard to
header files.  If you want to change the policy, the CVS repository is
not the right place to do it.

> It is bad enough that C's primitive and lousy scheme to provide external
> declarations and functions doesn't handle such things automatically
> like e.g. Modula II's module concept. But declaring this brokeness
> a feature is just sheer madness.

Unfortunately, Modula-2 suffers from exactly the same problem.  Only
the identifiers from the definitions, and *not* the imported identifiers,
are exported from a DEFINITION module.  That has been that way when I was
working on Modula-2 compilers 18 years ago and it hasn't changed since.
The ISO standard ist explicit about that.

Also the interface isn't broken "by design" as you claim.  The design is
as simple as they get.  In order to use the interface you have to follow
two trivial, linear steps which are clearly explained in the documentation:
1) you #include <sys/param.h>
2) you #include <sys/sysctl.h>
There is no ambiguity and if you follow the steps you get repeatable,
deterministic behaviour.

OTOH, only following half the recipe and relying on sheer luck to get
the program to even compile, is obviously broken.


Shall I revert the change or are you doing it?

--chris



Home | Main Index | Thread Index | Old Index