[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: problems/risks due to programming language, stories requested
From article <1004@micropen>, by dave@micropen (David F. Carlson):
> [... explicit breaks in the C switch construct ...]
> Dijkstra notes that no programming language can prevent a poor programmer from
> creating bad programs.
He also notes that the choice of programming language can have a strong
effect on the quality of the resulting code. (His indictment of PL/I
as being similar to flying a widebodied jet with all the windows taped
over and no labels on the thousands of controls was quite apropos.)
This effect of the language choice is mainly psychological - and it
CAN be overcome (which is the main thrust of many of Dijkstra's works).
But, be honest, how many programmers do you know who _really_ construct
their programs abstractly _before_ even selecting their implementation
language? This is the proper way (a' la Dijkstra) to make sure the
you aren't negatively impacted by the language - you select the proper
language for the job at hand - you don't mangle the job to fit the
Dijkstra's statement, while true, should not be used to excuse poorly
designed language features (as you are trying to do). A better design
for C would have been _not_ to require breaks after each case and to
provide some other syntax for the representation of multiple choices
on the same case. It's easy to see these kinds of design errors
in retrospect (C _is_ nearly 20 years old you know).