Douglas said:
That's certainly not true. A large number of applications,
especially for embedded systems, are coded nearly entirely in C.
Why would you not maintain your programming support library
for reuse across multiple projects? Unless, perhaps, you
don't know how to design it well enough for reuse.
Because in customer xyz the list library used is such and such
that conflicts with mine in *some* areas but not in others. Then
I have to use the customer's library until I discover that it
has a bug in a few not well tested routines. Then I debug them,
but I can't test all of them. With the next project is the same,
they *have* too several routines for list handling, each
serious C project has, and all of them not well tested and full
of problems!
What you do not want to understand is that EACH project has its
list library and ALL of them will not be well tested ones, with
more or less problems. Why do we have to REPEAT this work at
each project?
If we follow your reasoning we would all have a strcmp routine
because we would not have a standard LIBRARY!
Why calculating the gamma function is deemed worth of
standardization and not a common place routine like the handling of
a single linked list?
How many MILLIONS of lines of C code have followed your reasoning
above and ended with not well tested libraries that produce always
problems?
The task of a standard is to avoid needless repetition of effort
by providing a common interface for this library routines. Then,
vendors would all be compatible with libraries of different quality
and different prices and each one stressing different parts of
the implementation.
Look at Mr Plaugher for instance, and his high quality C library.
A user of my compiler system can throw away my library and buy
Mr Plaugher's without rewriting a single line of his code
because the interface is fixed you understand?
You say:
"... unless, perhaps, you don't know how to design it well enough
for reuse".
This attitude is unwarranted Mr Gwyn.