Lines Matching +full:sub +full:- +full:spaces
2 # SPDX-License-Identifier: GPL-2.0
4 # Clean a patch file -- or directory of patch files -- of stealth whitespace.
15 # Clean up space-tab sequences, either by removing spaces or
17 sub clean_space_tabs($)
31 my $ntab = ($npos >> 3) - ($pos >> 3);
56 sub strwidth($) {
85 if ($a =~ /^-/) {
86 if ($a eq '-width' || $a eq '-w') {
89 print STDERR "Usage: $name [-width #] files...\n";
100 if (! -f $f) {
146 /^\@\@\s+\-([0-9]+),([0-9]+)\s+\+([0-9]+),([0-9]+)\s\@\@/) {
161 $plus_lines--;
164 $text =~ s/[ \t\r]*$//; # Remove trailing spaces
175 } elsif ($line =~ /^\-/) {
176 $minus_lines--;
179 $plus_lines--;
180 $minus_lines--;
200 for ($i = scalar(@hunk_lines)-1; $i > 0; $i--) {
217 ($l =~ /^\@\@\s+\-([0-9]+),([0-9]+)\s+\+([0-9]+),([0-9]+)\s\@\@(.*)$/);
224 $l = sprintf("@@ -%d,%d +%d,%d @@%s\n",
225 $mstart, $mlin, $pstart, $plin-$adj,