in reply to Re^2: Use of uninitialized value in concatenation
in thread Use of uninitialized value in concatenation
For $foo it prints dollar and not dollarfoo. But still gets a warning message#!/usr/bin/perl -w use strict; my %words = map { $_ => 1 } qw($Word $name); my $line = '$Word $ $foo'; $line =~ s/(\$\w*)/exists $words{$1} ? $1 : qq{ dollar }/eg; print $line;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Use of uninitialized value in concatenation
by AnomalousMonk (Archbishop) on Jun 11, 2009 at 15:20 UTC | |
by Anonymous Monk on Jun 12, 2009 at 04:08 UTC | |
by AnomalousMonk (Archbishop) on Jun 12, 2009 at 15:48 UTC |