On 07/11/2016 16:52, Richard Gaskin wrote:
But more seriously, the meat here is this:

  doSomething item viUserID of tRec, item viUserName of tRec

...vs:

  doSomething aData["User ID"], aData["User Name"]

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


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*.

Ben

_______________________________________________
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