M
Morris Dovey
jacob said:Richard Heathfield wrote:
This is not possible for each allocation at each step without
introducing too many bugs, as the proponents of the other side
have repeatedly pointed out.
This is purely a statement of opinion. I've worked with large
real-time systems where allocation error detection and
transparent error recovery has been an absolute requirement. A
statement that it isn't possible is no more than a declaration
that the programmer is either unwilling to put forth the effort
to meet requirements, or a declaration of personal/team
incompetence.
When an allocation fails it is better to code an exception
that jumps to a recovery point. This simplifies the code
and makes for LESS bugs. Obviously this solution is not
meant for geniuses like you and the other people here
that boast of their infallible powers when programming.
I would suggest that you discover the genius of 10 - 12 ordinary
(but competent) programmers providing peer review - and eagerly
looking for any weakness in your code. It is very much _not_ a
matter of individual genius or infallible powers!
You never (of course) make any mistake when writing the
hundreds of lines of recovery code. My solution is meant for
people that do make mistakes (like me).
I understand that you are attempting to provide a means by which
semi- or incompetent programmers can avoid both the effort
required to learn and the effort required to produce high quality
code.
This is not rocket science. Those who struggle with if() will
This is just rubbish. Nobody "struggles with if". But it is
a proved fact that the more lines of code you have to write
the more the possibility of making mistakes.
*This* is correct. You have just made the best of cases for peer
review, the exercise of diligence, and the need for test
strategies that detect and diagnose errors so that they can be
corrected before release to the first user.