Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP IDE stinks at finding bad variable names in my code
Message
From
14/05/2009 15:33:54
 
 
To
14/05/2009 15:11:55
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01399931
Message ID:
01399945
Views:
150
>Just Dangit! I'm a fairly skilled programmer, but a apparently a terrible typist/speller. 9 times out of 10 when I my app bombs (while I am running it from the IDE during development), it is not becuase of bad logic, but simply becuase I have misspelled a variable name in a method. Good grief I am tottaly tired of that. I sure wish the thing would figure that when I close the code window, or even better, when I am typing.
>
>Things with intellisense support are fine, it's just stupid local vars defined right in the method that usually kill me.

I've gotten in the habit of copying/pasting variable names (especially if they're long and descriptive) to avoid this problem. Ironically, I started doing this when working in C#, where variable names are case-sensitive. Ironic, because VS catches these types of errors while compiling.

I'm trying to recall if there's ever been a static analysis tool for VFP that could point out variables that are never referenced, or that are referenced only once but I can't remember anything like that. If you could be sure you always (or should always) declare your variables before using them it would be possible to build such a tool, but with VFP that's not a legal requirement < g >
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform