Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Side by side comparison (strings & local data)
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Visual FoxPro et .NET
Divers
Thread ID:
00861648
Message ID:
00862191
Vues:
25
>>Actually, there is some optimization going on in that case. Unfortunately, it can cause the
>>code to break in recursive cases. To avoid the optimization _IF_ you are hitting this
>>problem, change it to read:
lcXML = "" + lcXML + someaddition
>Garrett, can you expand on this a bit more please? Why is this faster?

As I said above, this _isn't_ faster: it disables the optimization, and I expect that Fabio correctly explaned the mechanism. If you check out my code linked from http://www.capescience.com/webservices/globalweather/index.shtml, you'll see that I used this technique in the middle of a recursive loop. Change
lcRetVal = "" + lcRetVal + ;
            CHR(13) + CHR(10) + ;
            tcTab + loChild.baseName + " -- " + ParseNode(loChild, tcTab + CHR(9))
to
lcRetVal = lcRetVal + ;
            CHR(13) + CHR(10) + ;
            tcTab + loChild.baseName + " -- " + ParseNode(loChild, tcTab + CHR(9))
and you will see that despite the LOCAL declaration of lcRetVal, it unrolls improperly as the recursion works its way back up the tree.
My blog
My consulting page
My home page

Member of the Trim Your Auto-Quote Campaign!
What's another word for thesaurus?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform