I
Ian Collins
English should be capitalised. The second "you" should also go.Mark said:You might want to work on your english - the above doesn't entirely make
sense. Remove the word "either" and it does.
So how do you test the device drivers in that code before you have thehuh? When you're developing road-safety harnesses for people carriers,
you don't test them out on APVs and Big Dippers.
hardware? How do you simulate the behaviour of the system without
trashing a large number of people carriers?
I said "We *also* compiled". Our reason was much the same as K&R's, ourSo just to be clear, you're stating that you *used* to have good reason
to compile C as C++, but not any more?
C compiler didn't check prototypes correctly. Running that dogs
breakfast of a code base through the C++ compiler flushed out a lot of
bugs. The same would not have been true for well written code!
The code in question had been written by a novice who had just
discovered enums. He used them as function parameters without checking
them for valid values. He then passed inappropriate integer values to
these functions. Even today's C compilers would pass this code, but C++
compilers will not. The c++ compiler made a good "enum lint".