Handle empty arrayrefs gracefully.