Skip Menu |

This queue is for tickets about the VCS-Lite CPAN distribution.

Report information
The Basics
Id: 20738
Status: open
Priority: 0/
Queue: VCS-Lite

People
Owner: ivorw-cpan [...] xemaps.com
Requestors: asw [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.08
Fixed in: (no value)



Subject: VCS::Lite::Delta construction separator bug
Attached is a test script that demonstrates the problem. The output from test_vcs_delta.pl is Diff1: 1c1 < Foobar (?m-xis:^)--- Show quoted text
> Foobar 2
(?m-xis:^) Note the "(?m-xis:^)" part which is coming from somewhere strange. construction of Diff2 doesn't work at all, but based on what the documentation says I expected it to work. The "(?m-xis:^)" problem appeared in VCS::Lite::Delta v0.08
Subject: test_vcs_delta.pl
#!/usr/local/bin/perl use VCS::Lite::Delta; my $delta_text =<<\EOM; 1c1 < Foobar --- > Foobar 2 EOM my $delta; # this used to work in VCS::Lite::Delta v0.07 $delta = new VCS::Lite::Delta(\$delta_text, qr/^/m); print "diff1:\n", $delta->diff, "\n"; # this doesn't work in v0.07 or 0.08, but according to the docs it should work # (I think) $delta = new VCS::Lite::Delta(\$delta_text); print "diff2:\n", $delta->diff, "\n";
Just to let you know that this is definitely in progress. Release 0.08 of VCS::Lite contained major changes to the handling of separators, including the new "chomp" mode. Most of these were not propagated into VCS::Lite::Delta, and as you have correctly pointed out, this does not meet the spec that is in the documentation. I'm working on implementing chomp mode in construction of the delta objects. You can look at the changes in svn; note that this is WIP, and I have included your (currently failing) tests as TODO in t/01_deltasep.t http://www.ivorw.com/svn/cpan/VCS-Lite/trunk/