Browse Source
There is one subtlety: The old test case 'perl pattern gets full line of POD header' does not have its own new test case, but the feature is tested nevertheless by placing the RIGHT tag at the end of the expected hunk header in t4018/perl-skip-sub-in-pod. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>maint


6 changed files with 44 additions and 88 deletions
@ -0,0 +1,8 @@
@@ -0,0 +1,8 @@
|
||||
sub RIGHTwithheredocument { |
||||
print <<"EOF" |
||||
decoy here-doc |
||||
EOF |
||||
# some lines of context |
||||
# to pad it out |
||||
print "ChangeMe\n"; |
||||
} |
@ -0,0 +1,10 @@
@@ -0,0 +1,10 @@
|
||||
package RIGHT; |
||||
|
||||
use strict; |
||||
use warnings; |
||||
use parent qw(Exporter); |
||||
our @EXPORT_OK = qw(round finalround); |
||||
|
||||
sub other; # forward declaration |
||||
|
||||
# ChangeMe |
@ -0,0 +1,18 @@
@@ -0,0 +1,18 @@
|
||||
=head1 NAME |
||||
|
||||
Beer - subroutine to output fragment of a drinking song |
||||
|
||||
=head1 SYNOPSIS_RIGHT |
||||
|
||||
use Beer qw(round finalround); |
||||
|
||||
sub song { |
||||
for (my $i = 99; $i > 0; $i--) { |
||||
round $i; |
||||
} |
||||
finalround; |
||||
} |
||||
|
||||
ChangeMe; |
||||
|
||||
=cut |
@ -0,0 +1,4 @@
@@ -0,0 +1,4 @@
|
||||
sub RIGHT { |
||||
my ($n) = @_; |
||||
print "ChangeMe"; |
||||
} |
Loading…
Reference in new issue