On Mon Apr 12 13:05:11 2010, IRONCAMEL wrote:
Show quoted text> Escaping comment character '#' seems to be broken. Consider the
> following code snippet:
>
> ---
> use Config::General qw/ParseConfig/;
> use Data::Dumper;
> my %config = ParseConfig(\*DATA);
> print Dumper \%config;
>
> __DATA__
> bgcolor = \#ffffcc
>
> ---
>
> The output from above is:
>
> $VAR1 = {
> 'bgcolor' => '\\#ffffcc'
> };
>
> The extra '\' characters should not be there. I believe this bug may
be
Show quoted text> happening because this block of code is commented:
>
> # remove the \ from all characters if BackslashEscape is turned on
> # FIXME (rt.cpan.org#33218
> #if ($this->{BackslashEscape}) {
> # s/\\(.)/$1/g;
> #}
> #else {
> # # remove the \ char in front of masked "#", if any
> # s/\\#/#/g;
> #}
>
> I think the else clause of that code needs to still be run.
Here's some more data and a testcase I used for bisecting this. The
first broken version is 2.45:
bc255d2b7a36ddef552afb4ea87181b663374ba5 is the first bad commit
commit bc255d2b7a36ddef552afb4ea87181b663374ba5
Author: t0m <t0m@be1acefe-a474-0410-9a34-9b3221f2030f>
Date: Thu Apr 8 15:47:22 2010 +0000
Splat with 2.45
git-svn-id:
http://dev.catalyst.perl.org/repos/Config-
General/trunk@74 be1acefe-a474-0410-9a34-9b3221f2030f
:100644 100644 4562f217d8d2606c6c2921094dff8cbedfb31f23
a16e3ee8d9bec19f71ab2b2ba7f19ecf2bece303 M Changelog
:100644 100644 b4db197513a4ad81ac3278f59f5aae95eb18596e
77f3fd148f9e81d97469de1443c4372a9d71c2d9 M General.pm
:040000 040000 704d2698ae03cc1408a389a7eea58292cf26946a
c8c60e197e11da1a978f3971bf1741cfbcf3306d M General
:100644 100644 c540efdd2fad64be779baa6ddc57fbca01df9ccc
c7009fd56858d58414544c5cc6a3d82cccb886b3 M MANIFEST
:100644 100644 3e0995a32020ac447c124d156de70cc6df17b903
a4a4e74acee5b27add4be914a7b86d9d907b6a6d M META.yml
:100644 100644 fac15c41bcaa93bffe9f71ec5c1866de3cf1bdcc
291077bb57f3a2939c79121b5b517e20a82451d9 M README
:040000 040000 239ad18c75fd9eca3aa1d53be000ae352d959a8e
5e0fdade43bbc0c2334e4704ac26aaeab073114a M t
bisect run success