implicitVars [Was: Re: Best Practices in Rev development]

Francis Nugent Dixon effendi at wanadoo.fr
Sun Jul 1 13:11:20 EDT 2007


Hi from Paris,

Chipp,

I am sure that we ALL have our own "flawed" programming
practices. I have always been amazed by the different
opinions of everybody, on a subject where the "correct"
solution seems so obvious ............. to each of us ........... !

I came from 1401 Autocoder, through Fortran, through
Cobol, through years of 360 Assembler, through PL/1,
through Basic, ignored C (couldn't understand how you
use so many words to say so little !), through 12 years
of Hypercard, and finally to Rev (two years .. and counting !).

I define all my globals (GVxxx), and also define all my
locals (LVxxx) as globals during development of a stack,
and make them comments when the stack runs OK (but
switch them back to globals, if I run any major mods).

I never use the debug function. I go to bed with a problem
on my mind, and the next day, I code the solution straight
into the machine, and it works (it always amazes me !).

Now I know that Maslow said "If all you have in your hand
is a hammer, you tend to treat everything around you as a
nail", and I respect your point of view on variables, but
programming practices are in themselves "variable".

After 40 years of programming, I think I could write a book
called "Some programmers are from Mars, Others are from
Venus" (and I don't know what planet I came from ......!)

The same thing is true for "comments". Nobody (in his
right mind) will ever read my scripts in any of my Rev
stacks. In fact, nobody will ever see any of my Rev
stacks (with the exception of "FamilyTree"). Yet, I spend
many hours commenting my scripts, simply because I
grew up in a commercial environment, and learned to
hate the "fancy" programmers that never left a comment
for others, and gave impossible names to their variables.

I shudder when I remember a well-travelled student who
wrote his first program, couldn't think of any sensible names
for his variables, and so used the names of all the towns
and cities in China. We loved that guy to bits when we had
maintain his program for the following years .......!

I can come back to any of MY OWN Hypercard and Rev
stacks, years later, and within two minutes can master the
twisted mind of the guy who wrote those scripts years before.

Explicit Variables ...... Comments ........ I'm all for them !

-Francis





More information about the use-livecode mailing list