chiark / gitweb /
i18n: i18n-diff-auditor: fix here doc regexp
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Mon, 1 Oct 2018 01:44:00 +0000 (02:44 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Mon, 1 Oct 2018 01:44:40 +0000 (02:44 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
i18n-diff-auditor

index beb3a9a..116b0f8 100755 (executable)
@@ -138,9 +138,9 @@ sub semiparse ($) {
            push @o, { T => 'heredoc', Q => $q, Delim => $d,
                       E => $&, P => "<<$q$d$q" };
            s{^
-                (             .* \n    )
-                ( (?: (?! $d) .* \n )* )
-                          $d     \n
+                (                 .* \n     )
+                ( (?: (?! $d \n ) .* \n )*? )
+                          $d         \n
               }{ $1 }xe or die "missing end of here doc $d\n";
            $o[$#o]{V} = $2;
        } elsif (s{^ (["'])( (?: [^\\'"]