My stupid mistake. The array was being returned to another sub within the module and that sub was referencing it as a scalar.
Because I didn't provide the complete modules, it would have been very difficult for anyone to have worked out the problem.
At least I learnt how to use the wantarray function during this exercise -
return wantarray ? @addresses : "Error: scalar context";