TestStand is Copying Arrays when Passing by Reference

Updated Oct 5, 2020

Reported In

Software

  • TestStand

Issue Details

I need to pass parts of an array, like rows or columns to another sequence. I pass the array part as reference. However, TestStand creates a copy of the array part anyway. Why is this happening and how can I avoid it?

Solution

TestStand provides basic array handling functionality. However, passing only parts of an array to another sequence is expected to create a copy even when passing it by reference. Therefore the original part in the array needs to be replace in the calling sequence.
If the data copy itself has to be avoided, you can also pass the whole array by reference to another sequence or use a code module for array-editing.