sub make_csv_format { my $me = shift; my $color = shift if @_; my $quote_item = sub { # ... # Remove ugly kludge with prefixed color information: $item =~ s/^#[\dA-F]{6}//i unless $color; # ... }; # <------ This is line with warning. my $quote_row = sub { my $items = shift; return join(",", map { $quote_item->($_) } @$items) . "\n"; }; # ... }