use warnings; use Inline C => <<'EOC'; void foo() { printf("HELLO"); } EOC for(1..3) { foo(); print "\n"; }