[Po4a-commits] "po4a/lib/Locale/Po4a Man.pm,1.147,1.148"
Nicolas FRANCOIS
nekral-guest at alioth.debian.org
Sun Jun 4 12:21:34 UTC 2006
Update of /cvsroot/po4a/po4a/lib/Locale/Po4a
In directory haydn:/tmp/cvs-serv12201/lib/Locale/Po4a
Modified Files:
Man.pm
Log Message:
Other cases were \c can be allowed.
Index: Man.pm
===================================================================
RCS file: /cvsroot/po4a/po4a/lib/Locale/Po4a/Man.pm,v
retrieving revision 1.147
retrieving revision 1.148
diff -u -d -r1.147 -r1.148
--- Man.pm 4 Jun 2006 00:45:01 -0000 1.147
+++ Man.pm 4 Jun 2006 12:21:32 -0000 1.148
@@ -692,7 +692,7 @@
my $begin = $1;
my ($l2,$r2)=$self->SUPER::shiftline();
- if ($l2 =~ /^[.' ]/) {
+ if ($l2 =~ /^[.']/) {
$self->SUPER::unshiftline($l2,$r2);
} else {
$l2 =~ s/\s*$//s;
@@ -791,11 +791,10 @@
# Note: if you want to implement \c support, the gdb man page is your playground
if ( not defined $self->{type}) {
- $str =~ s/^((?:.*)\n|) #
- ([ \t]*[^.'][^\n]*(?<!\\)(?:\\\\)*) # a new line
- \\c[ \t]*\n # ending by \c and followed by a line
- ([ \t]*[^.'] # which doesn't start by . or '
- (?:.*))$/$1$2$3/sgx;
+ $str =~ s/(\G|^(?:.*?)\n|^) # Last position, or begin of a line
+ ([ \t]*[^.'][^\n]*(?<!\\)(?:\\\\)*) # the new line, which
+ \\c[ \t]*\n # ends by \c and followed by a line
+ (?![ \t]*[.'])/$1$2/sgx;# not followed by a command (.')
}
die wrap_ref_mod($ref, "po4a::man", dgettext("po4a","Escape sequence \\c encountered. This is not completely handled yet."))
if ($str =~ /\\c/);
More information about the Po4a-commits
mailing list