in reply to Re: Re: Bug with substring return value?
in thread Bug with substring return value?
The other ways of writing it, $x = $y = 42; and your example are just shorthand ways.$y = 42; $x = $y; substr( $string, 2, 6 ) = ''; $result = substr( $string, 2, 6 );
And perldoc specifically mentions the way when you use a fourth argument instead as an alternative where you can get the replaced values back, unlike the assignment way.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
RE:(4): Bug with substring return value?
by shotgunefx (Parson) on Apr 13, 2002 at 14:15 UTC |