Ben Rubinstein wrote:

> On 07/11/2016 16:52, Richard Gaskin wrote:
>> On the one hand, each array access requires a small amount of
>> overhead to run the key through a hash to find the value's address.
>>  However, that overhead is pretty small...
>
> No, no - the meat here is this:
>
>>     do makeAccessVars("vi", line 1 of tTSVdata)
>>     ...
>>     repeat for each line tRec in tTSVdata
>
> vs
>
>>     repeat for each line tRec in tTSVdata
>>         put explodeRow(tRec, tColumnNames) into aData

Ah, thanks.

Without seeing the code for explodeRow it's not possible for me to have an informed assessment of its impact.


> I wouldn't care to hazard a guess as to the relative speed of
> "aData[x]"  versus "item x": but it's the overhead of the function
> which creates the array on that I don't want to pay *on every row*.

The function call itself has very small overheard. Whether the definition of that function takes more time than walking through the characters for the chunk expression can't be known without testing.

--
 Richard Gaskin
 Fourth World Systems
 Software Design and Development for the Desktop, Mobile, and the Web
 ____________________________________________________________________
 ambassa...@fourthworld.com                http://www.FourthWorld.com

_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to