in reply to Calling a function from within a HERE doc?
my $x = <<__H__; A test @{[ &test ]}! __H__ sub test { 'function' } print $x; [download]