#!/usr/bin/perl use warnings; use strict; use String::Interpolate; my @a; my $proto = 'String::Interpolate'->new({'a' => \@a}); @a = (1, 2); print $proto->('@a 3 4'); # 1 2 3 4