Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Is there a SET LOCAL VARS ON
Message
De
29/08/2006 09:45:18
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01149279
Message ID:
01149329
Vues:
9
>Hi all
>
>Other than defining variables LOCAL is it possible to have local variables by default rather than PRIVATE?

Some languages have the option, not to make the variable local (or the equivalent in the corresponding language) by default, but to give a compiler error if the variable is not properly declared. I have seen something like this in Visual Basic, I think it was a command like "option explicit". (Note: My familiarity with VB is very superficial.)

I would expect Visual FoxPro to behave similarly, with some option to give an error, or perhaps a warning, for non-declared variables - but I suspect it hasn't been implemented yet, even in the newest versions. Nor do I know if it would be easy to implement.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform