Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How much of your code do you test?
Message
From
21/11/2002 08:36:14
 
 
To
18/11/2002 13:30:21
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00721300
Message ID:
00725111
Views:
10
>>>Your point (b) I simply don't understand. Code that 'cannot be reached' CAN BE REMOVED without consequence.
>>
>>You sure about that? Are you 100% sure you've proven the negative statement that "the code cannot be reached"?
>
>First, I only used the phrase that you used. Secondly, if I couldn't prove that some code could not be reached, then it would have to stay in. I guess you mean to suggest that one cannot prove a negative. I don't think that's applicable in the case stated (I *can* prove that the earth is not square and I *can* prove that a person cannot walk around the earth on the equator line).

Jim - I think you're missing Mike's point. Good programming practice says that, for example, every CASE has an OTHERWISE, even if you believe you've enumerated all possibilities in the other cases. There's no way to test that OTHERWISE case, but it's better code to have it there than to remove it.

Tamar
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform