Amaury Forgeot d'Arc added the comment:

Careful, Perl strings must be double-quoted for \n to be understood as
the newline character:

"""
use Data::Dumper;

$a = "a\nb\nc";
$a =~ s/$/#/;
print Dumper($a);

$a = "a\nb\n";
$a =~ s/$/#/;
print Dumper($a);
"""

And the output is:

$VAR1 = 'a
b
c#';
$VAR1 = 'a
b#
';

Which is definitely different from python output.

__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue1761>
__________________________________
_______________________________________________
Python-bugs-list mailing list 
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to