Perl replace "<IP_WAN>" by "10.20.20.1/24->addr()" and not "10.20.20.1". It seems perl ignore arrow operator "->" I tried with simple quote ' ' or double quote " " No success :(my $ip_wan = new NetAddr::IP("10.20.20.1/24"); for (@line) { s/<IP_WAN>/$ip_wan->addr()/; }
In reply to Perl ignore arrow object operator in search/replace by fouinix
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |