He's not shown that yet. What about prototype declarations of external
functions? Yes, using the C meaning you don't need a prototype -- you
just write empty brackets -- but using his apparent meaning, prototypes
are still needed in this case.
There are cases where it is more advantageous to have prototype declarations,
such as these examples you state. If I am compiling something that will be
linked in later, then it may not be desirable to parse the entire source file
to obtain the function declarations as prototypes themselves. As such, the
need for those prototype declarations are desirable.
Still, there should be no reason any human being has to write them in any
case. The compiler can parse the function declarations and create the
prototype file as a mechanical operation of the compiler, rather than of
the developer. Compilers won't make mistakes once they're coded and
debugged. People will.
And for systems which are integrated using the tools available today as
they relate to hardware, there is no longer any reason whatsoever for
any human being to maintain any aspect of mechanical conveyance of
something internal to an application. The computer's entire existence
is to help man increase productivity. I am not well served by doing
lots of mechanical typing when the computer itself can, through multiple
threads on multiple cores with gigabytes of memory, re-parse the entire
source code file of the Linux kernel, for example, in near real-time.
The fact is C looks backwards, to a time when machines were limited.
There are MANY facets of C that should be revisited, and the cojoined
nature of the advanced edit-and-continue C compiler and IDE should be
acknowledged as the future.
My opinion. C needs to change. I will actually introduce a C compiler
at some point into my RDC toolchain. This will allow existing code to
be compiled properly, along with the extensions I'll add. As such, I
hope to bring this forward to people as well. The only reason I'll be
doing it is because I recognize the code base that's out there and that
there are needs to not lose those man-hours when the machine can fill
in the gap between where things are and where they should be.
Best regards,
Rick C. Hodgin