Hello community, here is the log from the commit of package perl-Perl-Tidy for openSUSE:Factory checked in at 2013-08-13 10:18:59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/perl-Perl-Tidy (Old) and /work/SRC/openSUSE:Factory/.perl-Perl-Tidy.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "perl-Perl-Tidy" Changes: -------- --- /work/SRC/openSUSE:Factory/perl-Perl-Tidy/perl-Perl-Tidy.changes 2013-07-30 14:03:51.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.perl-Perl-Tidy.new/perl-Perl-Tidy.changes 2013-08-13 10:19:00.000000000 +0200 @@ -1,0 +2,11 @@ +Tue Aug 6 17:49:08 UTC 2013 - [email protected] + +- updated to 20130806 + - Fixed RT #87107, spelling + + - Fixed RT #87502, incorrect of parsing of smartmatch before hash brace + + - Added feature request RT #87330, trim whitespace after POD. + The flag -trp (--trim-pod) will trim trailing whitespace from lines of POD + +------------------------------------------------------------------- Old: ---- Perl-Tidy-20130717.tar.gz New: ---- Perl-Tidy-20130806.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ perl-Perl-Tidy.spec ++++++ --- /var/tmp/diff_new_pack.A9OmmD/_old 2013-08-13 10:19:01.000000000 +0200 +++ /var/tmp/diff_new_pack.A9OmmD/_new 2013-08-13 10:19:01.000000000 +0200 @@ -17,7 +17,7 @@ Name: perl-Perl-Tidy -Version: 20130717 +Version: 20130806 Release: 0 %define cpan_name Perl-Tidy Summary: Parses and beautifies perl source ++++++ Perl-Tidy-20130717.tar.gz -> Perl-Tidy-20130806.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/CHANGES new/Perl-Tidy-20130806/CHANGES --- old/Perl-Tidy-20130717/CHANGES 2013-07-17 00:51:17.000000000 +0200 +++ new/Perl-Tidy-20130806/CHANGES 2013-08-06 02:50:55.000000000 +0200 @@ -1,4 +1,13 @@ Perltidy Change Log + 2013 08 06 + - Fixed RT #87107, spelling + + 2013 08 05 + - Fixed RT #87502, incorrect of parsing of smartmatch before hash brace + + - Added feature request RT #87330, trim whitespace after POD. + The flag -trp (--trim-pod) will trim trailing whitespace from lines of POD + 2013 07 17 - Fixed RT #86929, #86930, missing lhs of assignment. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/META.yml new/Perl-Tidy-20130806/META.yml --- old/Perl-Tidy-20130717/META.yml 2013-07-17 00:51:19.000000000 +0200 +++ new/Perl-Tidy-20130806/META.yml 2013-08-06 02:50:57.000000000 +0200 @@ -1,6 +1,6 @@ --- #YAML:1.0 name: Perl-Tidy -version: 20130717 +version: 20130806 abstract: indent and reformat perl scripts author: - Steve Hancock <[email protected]> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/bin/perltidy new/Perl-Tidy-20130806/bin/perltidy --- old/Perl-Tidy-20130717/bin/perltidy 2013-07-17 00:51:15.000000000 +0200 +++ new/Perl-Tidy-20130806/bin/perltidy 2013-08-06 02:50:54.000000000 +0200 @@ -150,7 +150,7 @@ Most parameters which serve as on/off flags can be negated with a leading "n" (for the short name) or a leading "no" or "no-" (for the -long name). For example, the flag to outdent long quotes is is B<-olq> +long name). For example, the flag to outdent long quotes is B<-olq> or B<--outdent-long-quotes>. The flag to skip this is B<-nolq> or B<--nooutdent-long-quotes> or B<--no-outdent-long-quotes>. @@ -385,7 +385,7 @@ A problem arises using a fixed maximum line length with very deeply nested code and data structures because eventually the amount of leading whitespace used -for indicating indation takes up most or all of the available line width, +for indicating indentation takes up most or all of the available line width, leaving little or no space for the actual code or data. One solution is to use a vary long line length. Another solution is to use the B<-vmll> flag, which basically tells perltidy to ignore leading whitespace when measuring the line @@ -456,7 +456,7 @@ =item B<-dt=n>, B<--default-tabsize=n> -If the the first line of code passed to perltidy contains leading tabs but no +If the first line of code passed to perltidy contains leading tabs but no tab scheme is specified for the output stream then perltidy must guess how many spaces correspond to each leading tab. This number of spaces B<n> corresponding to each leading tab of the input stream may be specified with @@ -741,7 +741,7 @@ =item B<-okw>, B<--outdent-keywords> -The command B<-okw> will will cause certain leading control keywords to +The command B<-okw> will cause certain leading control keywords to be outdented by 2 spaces (or whatever B<-ci> has been set to), if possible. By default, these keywords are C<redo>, C<next>, C<last>, C<goto>, and C<return>. The intention is to make these control keywords @@ -1007,6 +1007,11 @@ normally be necessary, but was added for testing purposes, because in some versions of perl, trimming C<qw> quotes changes the syntax tree. +=item Trimming trailing whitespace from lines of POD + +B<-trp> or B<--trim-pod> will remove trailing whitespace from lines of POD. +The default is not to do this. + =back =head2 Comment Controls @@ -1058,7 +1063,7 @@ =item B<-fpsc=n>, B<--fixed-position-side-comment=n> This parameter tells perltidy to line up side comments in column number B<n> -whenever possible. The default, n=0, is not do do this. +whenever possible. The default, n=0, will not do this. =item B<-iscl>, B<--ignore-side-comment-lengths> @@ -1201,7 +1206,7 @@ perltidy -csc -ncscb } ## end foreach my $foo (sort { $b cmp $a ... -However this causes a problem with editors editors which cannot recognize +However this causes a problem with editors which cannot recognize comments or are not configured to do so because they cannot "bounce" around in the text correctly. The B<-cscb> flag has been added to help them by appending appropriate balancing structure: @@ -1391,7 +1396,7 @@ =item B<-osbc>, B<--outdent-static-block-comments> -The command B<-osbc> will will cause static block comments to be outdented by 2 +The command B<-osbc> will cause static block comments to be outdented by 2 spaces (or whatever B<-ci=n> has been set to), if possible. =back @@ -1407,7 +1412,7 @@ =item B<-ssc>, B<--static-side-comments> When B<-ssc> is used, a side comment with a static leading pattern, which is -C<##> by default, will be be spaced only a single space from previous +C<##> by default, will be spaced only a single space from previous character, and it will not be vertically aligned with other side comments. The default is B<-nssc>. @@ -1701,7 +1706,7 @@ =item * -Different controls may be applied to to different token types, +Different controls may be applied to different token types, and it is also possible to control block braces; see below. =item * @@ -1840,7 +1845,7 @@ C<perltidy -bli -bbvt=1 -bbvtl='if elsif else'>. There is no vertical tightness control for closing block braces; with -one exception they they will be placed on separate lines. +one exception they will be placed on separate lines. The exception is that a cascade of closing block braces may be stacked on a single line. See B<-scbb>. @@ -2229,7 +2234,7 @@ The statements are still subject to the specified value of B<maximum-line-length> and will be broken if this -maximum is exceeed. +maximum is exceeded. =back @@ -2260,7 +2265,7 @@ definition which does not follow a comment and which is more than one-line long. The default is <-blbs=1>. B<BEGIN> and B<END> blocks are included. -The requested number of blanks statement will be inserted regardless of of the +The requested number of blanks statement will be inserted regardless of the value of B<--maximum-consecutive-blank-lines=n> (B<-mbl=n>) with the exception that if B<-mbl=0> then no blanks will be output. @@ -2482,7 +2487,7 @@ in the INSTALL file distributed with perltidy. Under Windows, perltidy will also search for a configuration file named perltidy.ini since Windows does not allow files with a leading period (.). -Use C<perltidy -dpro> to see the possbile locations for your system. +Use C<perltidy -dpro> to see the possible locations for your system. An example might be F<C:\Documents and Settings\All Users\perltidy.ini>. Another option is the use of the PERLTIDY environment variable. @@ -2498,7 +2503,7 @@ full path of the configuration file in the value of the environment variable. Ex. PERLTIDY=C:\Documents and Settings\perltidy.ini -The configuation file is free format, and simply a list of parameters, just as +The configuration file is free format, and simply a list of parameters, just as they would be entered on a command line. Any number of lines may be used, with any number of parameters per line, although it may be easiest to read with one parameter per line. Comment text begins with a #, and there must @@ -3012,7 +3017,7 @@ D anl asc aws b bbb bbc bbs bl bli boc bok bol bot ce csc dac dbc dcsc ddf dln dnl dop dp dpro dsc dsm dsn dtt dwls dwrs dws f fll frm fs hsc html ibc icb icp iob isbc lal log - lp lsl ohbr okw ola oll opr opt osbr otr ple ple pod pvl q + lp lsl ohbr okw ola oll opr opt osbr otr ple pod pvl q sbc sbl schb scp scsb sct se sfp sfs skp sob sohb sop sosb sot ssc st sts syn t tac tbc toc tp tqw tsc w x bar kis @@ -3088,7 +3093,7 @@ =head1 VERSION -This man page documents perltidy version 20130717. +This man page documents perltidy version 20130806. =head1 CREDITS diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/debian/changelog new/Perl-Tidy-20130806/debian/changelog --- old/Perl-Tidy-20130717/debian/changelog 2013-07-16 16:15:40.000000000 +0200 +++ new/Perl-Tidy-20130806/debian/changelog 2013-08-06 01:33:28.000000000 +0200 @@ -1,4 +1,10 @@ -perltidy (20130717-1) unstable; urgency=low +perltidy (20130805-1) unstable; urgency=low + + * New upstream release + + -- Steve Hancock <[email protected]> Mon, 05 Aug 2013 06:59:59 -0700 + +perltidy (20121207-1) unstable; urgency=low * New upstream release diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/docs/perltidy.1 new/Perl-Tidy-20130806/docs/perltidy.1 --- old/Perl-Tidy-20130717/docs/perltidy.1 2013-07-17 00:51:16.000000000 +0200 +++ new/Perl-Tidy-20130806/docs/perltidy.1 2013-08-06 02:50:55.000000000 +0200 @@ -124,7 +124,7 @@ .\" ======================================================================== .\" .IX Title "PERLTIDY 1" -.TH PERLTIDY 1 "2013-07-16" "perl v5.14.2" "User Contributed Perl Documentation" +.TH PERLTIDY 1 "2013-08-05" "perl v5.14.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l @@ -287,7 +287,7 @@ .PP Most parameters which serve as on/off flags can be negated with a leading \*(L"n\*(R" (for the short name) or a leading \*(L"no\*(R" or \*(L"no\-\*(R" (for the -long name). For example, the flag to outdent long quotes is is \fB\-olq\fR +long name). For example, the flag to outdent long quotes is \fB\-olq\fR or \fB\-\-outdent\-long\-quotes\fR. The flag to skip this is \fB\-nolq\fR or \fB\-\-nooutdent\-long\-quotes\fR or \fB\-\-no\-outdent\-long\-quotes\fR. .PP @@ -505,7 +505,7 @@ .IX Item "-vmll, --variable-maximum-line-length" A problem arises using a fixed maximum line length with very deeply nested code and data structures because eventually the amount of leading whitespace used -for indicating indation takes up most or all of the available line width, +for indicating indentation takes up most or all of the available line width, leaving little or no space for the actual code or data. One solution is to use a vary long line length. Another solution is to use the \fB\-vmll\fR flag, which basically tells perltidy to ignore leading whitespace when measuring the line @@ -572,7 +572,7 @@ option. .IP "\fB\-dt=n\fR, \fB\-\-default\-tabsize=n\fR" 4 .IX Item "-dt=n, --default-tabsize=n" -If the the first line of code passed to perltidy contains leading tabs but no +If the first line of code passed to perltidy contains leading tabs but no tab scheme is specified for the output stream then perltidy must guess how many spaces correspond to each leading tab. This number of spaces \fBn\fR corresponding to each leading tab of the input stream may be specified with @@ -854,7 +854,7 @@ .IP "\fB\-okw\fR, \fB\-\-outdent\-keywords\fR" 4 .IX Item "-okw, --outdent-keywords" .PD -The command \fB\-okw\fR will will cause certain leading control keywords to +The command \fB\-okw\fR will cause certain leading control keywords to be outdented by 2 spaces (or whatever \fB\-ci\fR has been set to), if possible. By default, these keywords are \f(CW\*(C`redo\*(C'\fR, \f(CW\*(C`next\*(C'\fR, \f(CW\*(C`last\*(C'\fR, \&\f(CW\*(C`goto\*(C'\fR, and \f(CW\*(C`return\*(C'\fR. The intention is to make these control keywords @@ -1128,6 +1128,10 @@ multi-line \f(CW\*(C`qw\*(C'\fR quotes to be left unchanged. This option will not normally be necessary, but was added for testing purposes, because in some versions of perl, trimming \f(CW\*(C`qw\*(C'\fR quotes changes the syntax tree. +.IP "Trimming trailing whitespace from lines of \s-1POD\s0" 4 +.IX Item "Trimming trailing whitespace from lines of POD" +\&\fB\-trp\fR or \fB\-\-trim\-pod\fR will remove trailing whitespace from lines of \s-1POD\s0. +The default is not to do this. .SS "Comment Controls" .IX Subsection "Comment Controls" Perltidy has a number of ways to control the appearance of both block comments @@ -1174,7 +1178,7 @@ .IP "\fB\-fpsc=n\fR, \fB\-\-fixed\-position\-side\-comment=n\fR" 4 .IX Item "-fpsc=n, --fixed-position-side-comment=n" This parameter tells perltidy to line up side comments in column number \fBn\fR -whenever possible. The default, n=0, is not do do this. +whenever possible. The default, n=0, will not do this. .IP "\fB\-iscl\fR, \fB\-\-ignore\-side\-comment\-lengths\fR" 4 .IX Item "-iscl, --ignore-side-comment-lengths" This parameter causes perltidy to ignore the length of side comments when @@ -1323,7 +1327,7 @@ \& } ## end foreach my $foo (sort { $b cmp $a ... .Ve .Sp -However this causes a problem with editors editors which cannot recognize +However this causes a problem with editors which cannot recognize comments or are not configured to do so because they cannot \*(L"bounce\*(R" around in the text correctly. The \fB\-cscb\fR flag has been added to help them by appending appropriate balancing structure: @@ -1498,7 +1502,7 @@ single '#'. .IP "\fB\-osbc\fR, \fB\-\-outdent\-static\-block\-comments\fR" 4 .IX Item "-osbc, --outdent-static-block-comments" -The command \fB\-osbc\fR will will cause static block comments to be outdented by 2 +The command \fB\-osbc\fR will cause static block comments to be outdented by 2 spaces (or whatever \fB\-ci=n\fR has been set to), if possible. .RE .RS 4 @@ -1512,7 +1516,7 @@ .IP "\fB\-ssc\fR, \fB\-\-static\-side\-comments\fR" 4 .IX Item "-ssc, --static-side-comments" When \fB\-ssc\fR is used, a side comment with a static leading pattern, which is -\&\f(CW\*(C`##\*(C'\fR by default, will be be spaced only a single space from previous +\&\f(CW\*(C`##\*(C'\fR by default, will be spaced only a single space from previous character, and it will not be vertically aligned with other side comments. .Sp The default is \fB\-nssc\fR. @@ -1805,7 +1809,7 @@ The rules for \fB\-vtc=1\fR are designed to maintain a reasonable balance between tightness and readability in complex lists. .IP "\(bu" 4 -Different controls may be applied to to different token types, +Different controls may be applied to different token types, and it is also possible to control block braces; see below. .IP "\(bu" 4 Finally, please note that these vertical tightness flags are merely @@ -1952,7 +1956,7 @@ \&\f(CW\*(C`perltidy \-bli \-bbvt=1 \-bbvtl=\*(Aqif elsif else\*(Aq\*(C'\fR. .Sp There is no vertical tightness control for closing block braces; with -one exception they they will be placed on separate lines. +one exception they will be placed on separate lines. The exception is that a cascade of closing block braces may be stacked on a single line. See \fB\-scbb\fR. .IP "\fB\-sot\fR, \fB\-\-stack\-opening\-tokens\fR and related flags" 4 @@ -2359,7 +2363,7 @@ .Sp The statements are still subject to the specified value of \fBmaximum-line-length\fR and will be broken if this -maximum is exceeed. +maximum is exceeded. .SS "Blank Line Control" .IX Subsection "Blank Line Control" Blank lines can improve the readability of a script if they are carefully @@ -2382,7 +2386,7 @@ definition which does not follow a comment and which is more than one-line long. The default is <\-blbs=1>. \fB\s-1BEGIN\s0\fR and \fB\s-1END\s0\fR blocks are included. .Sp -The requested number of blanks statement will be inserted regardless of of the +The requested number of blanks statement will be inserted regardless of the value of \fB\-\-maximum\-consecutive\-blank\-lines=n\fR (\fB\-mbl=n\fR) with the exception that if \fB\-mbl=0\fR then no blanks will be output. .Sp @@ -2582,7 +2586,7 @@ in the \s-1INSTALL\s0 file distributed with perltidy. .Sp Under Windows, perltidy will also search for a configuration file named perltidy.ini since Windows does not allow files with a leading period (.). -Use \f(CW\*(C`perltidy \-dpro\*(C'\fR to see the possbile locations for your system. +Use \f(CW\*(C`perltidy \-dpro\*(C'\fR to see the possible locations for your system. An example might be \fIC:\eDocuments and Settings\eAll Users\eperltidy.ini\fR. .Sp Another option is the use of the \s-1PERLTIDY\s0 environment variable. @@ -2598,7 +2602,7 @@ full path of the configuration file in the value of the environment variable. Ex. PERLTIDY=C:\eDocuments and Settings\eperltidy.ini .Sp -The configuation file is free format, and simply a list of parameters, just as +The configuration file is free format, and simply a list of parameters, just as they would be entered on a command line. Any number of lines may be used, with any number of parameters per line, although it may be easiest to read with one parameter per line. Comment text begins with a #, and there must @@ -3118,7 +3122,7 @@ \& D anl asc aws b bbb bbc bbs bl bli boc bok bol bot ce \& csc dac dbc dcsc ddf dln dnl dop dp dpro dsc dsm dsn dtt dwls \& dwrs dws f fll frm fs hsc html ibc icb icp iob isbc lal log -\& lp lsl ohbr okw ola oll opr opt osbr otr ple ple pod pvl q +\& lp lsl ohbr okw ola oll opr opt osbr otr ple pod pvl q \& sbc sbl schb scp scsb sct se sfp sfs skp sob sohb sop sosb sot \& ssc st sts syn t tac tbc toc tp tqw tsc w x bar kis .Ve @@ -3179,7 +3183,7 @@ \&\fIperlstyle\fR\|(1), \fIPerl::Tidy\fR\|(3) .SH "VERSION" .IX Header "VERSION" -This man page documents perltidy version 20130717. +This man page documents perltidy version 20130806. .SH "CREDITS" .IX Header "CREDITS" Michael Cartmell supplied code for adaptation to \s-1VMS\s0 and helped with diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/docs/stylekey.pod new/Perl-Tidy-20130806/docs/stylekey.pod --- old/Perl-Tidy-20130717/docs/stylekey.pod 2007-04-22 16:17:32.000000000 +0200 +++ new/Perl-Tidy-20130806/docs/stylekey.pod 2013-08-06 02:33:45.000000000 +0200 @@ -505,7 +505,7 @@ } ); -If you prefer to avoid isolated opening opening tokens by +If you prefer to avoid isolated opening tokens by "stacking" them together with other opening tokens like this: $opt_c = Text::CSV_XS->new( { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/examples/break_long_quotes.pl new/Perl-Tidy-20130806/examples/break_long_quotes.pl --- old/Perl-Tidy-20130717/examples/break_long_quotes.pl 2012-07-14 15:15:30.000000000 +0200 +++ new/Perl-Tidy-20130806/examples/break_long_quotes.pl 2013-08-06 02:35:01.000000000 +0200 @@ -54,7 +54,7 @@ my $err=perltidy( 'formatter' => $formatter, # callback object 'source' => $fh, - 'argv' => "-npro -se", # dont need .perltidyrc + 'argv' => "-npro -se", # don't need .perltidyrc # errors to STDOUT ); if ($err){ @@ -91,11 +91,11 @@ my $line_of_tokens = shift; my $line_type = $line_of_tokens->{_line_type}; my $input_line_number = $line_of_tokens->{_line_number}; - my $input_line = $line_of_tokens->{_line_text}; # the orignal line - my $rtoken_type = $line_of_tokens->{_rtoken_type}; # type of tokens - my $rtokens = $line_of_tokens->{_rtokens}; # text of tokens + my $input_line = $line_of_tokens->{_line_text}; # the original line + my $rtoken_type = $line_of_tokens->{_rtoken_type}; # type of tokens + my $rtokens = $line_of_tokens->{_rtokens}; # text of tokens my $starting_in_quote = - $line_of_tokens->{_starting_in_quote}; # text of tokens + $line_of_tokens->{_starting_in_quote}; # text of tokens my $ending_in_quote = $line_of_tokens->{_ending_in_quote}; # text of tokens my $max_quote_length = $self->{_max_quote_length}; chomp $input_line; @@ -143,7 +143,7 @@ $new_line .= $token; } ## end for ( my $j = 0 ; $j <=... - # substitude the modified line for the original line + # substitute the modified line for the original line $input_line = $new_line; } ## end if ( $line_type eq 'CODE') diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/examples/find_naughty.pl new/Perl-Tidy-20130806/examples/find_naughty.pl --- old/Perl-Tidy-20130717/examples/find_naughty.pl 2012-07-14 15:19:21.000000000 +0200 +++ new/Perl-Tidy-20130806/examples/find_naughty.pl 2013-08-06 02:35:22.000000000 +0200 @@ -40,7 +40,7 @@ # The PerlTokenSearch package is an interface to perltidy which accepts a # source filehandle and looks for selected variables. # -# It works by making a a callback object with a write_line() method to +# It works by making a callback object with a write_line() method to # receive tokenized lines from perltidy. # # Usage: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/examples/perlcomment.pl new/Perl-Tidy-20130806/examples/perlcomment.pl --- old/Perl-Tidy-20130717/examples/perlcomment.pl 2012-07-14 15:21:30.000000000 +0200 +++ new/Perl-Tidy-20130806/examples/perlcomment.pl 2013-08-06 02:35:48.000000000 +0200 @@ -102,9 +102,9 @@ my $line_of_tokens = shift; my $line_type = $line_of_tokens->{_line_type}; ## my $input_line_number = $line_of_tokens->{_line_number}; - my $input_line = $line_of_tokens->{_line_text}; # the orignal line - my $rtoken_type = $line_of_tokens->{_rtoken_type}; # type of tokens - my $rtokens = $line_of_tokens->{_rtokens}; # text of tokens + my $input_line = $line_of_tokens->{_line_text}; # the original line + my $rtoken_type = $line_of_tokens->{_rtoken_type}; # type of tokens + my $rtokens = $line_of_tokens->{_rtokens}; # text of tokens # Just print non-code, non-comment lines if ( diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/examples/perlmask.pl new/Perl-Tidy-20130806/examples/perlmask.pl --- old/Perl-Tidy-20130717/examples/perlmask.pl 2012-07-14 15:22:14.000000000 +0200 +++ new/Perl-Tidy-20130806/examples/perlmask.pl 2013-08-06 02:35:59.000000000 +0200 @@ -80,7 +80,7 @@ # a string or array. It can also optionally return the original file # as a string or array. # -# It works by making a a callback object with a write_line() method to +# It works by making a callback object with a write_line() method to # receive tokenized lines from perltidy. This write_line method # selectively replaces tokens with either their original text or with a # benign masking character (such as '#' or 'Q'). diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/lib/Perl/Tidy.pm new/Perl-Tidy-20130806/lib/Perl/Tidy.pm --- old/Perl-Tidy-20130717/lib/Perl/Tidy.pm 2013-07-17 00:50:56.000000000 +0200 +++ new/Perl-Tidy-20130806/lib/Perl/Tidy.pm 2013-08-06 02:49:53.000000000 +0200 @@ -20,7 +20,7 @@ # with this program; if not, write to the Free Software Foundation, Inc., # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. # -# For brief instructions instructions, try 'perltidy -h'. +# For brief instructions, try 'perltidy -h'. # For more complete documentation, try 'man perltidy' # or visit http://perltidy.sourceforge.net # @@ -78,7 +78,7 @@ use File::Copy; BEGIN { - ( $VERSION = q($Id: Tidy.pm,v 1.74 2013/07/17 13:56:49 perltidy Exp $) ) =~ s/^.*\s+(\d+)\/(\d+)\/(\d+).*$/$1$2$3/; # all one line for MakeMaker + ( $VERSION = q($Id: Tidy.pm,v 1.74 2013/08/06 13:56:49 perltidy Exp $) ) =~ s/^.*\s+(\d+)\/(\d+)\/(\d+).*$/$1$2$3/; # all one line for MakeMaker } sub streamhandle { @@ -747,7 +747,7 @@ } # As a safety precaution, skip zero length files. - # If for example a source file got clobberred somehow, + # If for example a source file got clobbered somehow, # the old .tdy or .bak files might still exist so we # shouldn't overwrite them with zero length files. unless ( -s $input_file ) { @@ -1607,6 +1607,7 @@ $add_option->( 'square-bracket-vertical-tightness-closing', 'sbvtc', '=i' ); $add_option->( 'tight-secret-operators', 'tso', '!' ); $add_option->( 'trim-qw', 'tqw', '!' ); + $add_option->( 'trim-pod', 'trp', '!' ); $add_option->( 'want-left-space', 'wls', '=s' ); $add_option->( 'want-right-space', 'wrs', '=s' ); @@ -3005,7 +3006,7 @@ } else { - # This currently would only happen on a win32s computer. I dont have + # This currently would only happen on a win32s computer. I don't have # one to test, so I am unsure how to proceed. Suggestions welcome! $$rpending_complaint .= "I dont know a sensible place to look for config files on an $os system.\n"; @@ -3578,7 +3579,7 @@ if ( $flags !~ /(^-x|\s+-x)/ ) { $flags .= " -x" } } - # this shouldn't happen unless a termporary file couldn't be made + # this shouldn't happen unless a temporary file couldn't be made if ( $istream eq '-' ) { $logger_object->write_logfile_entry( "Cannot run perl -c on STDIN and STDOUT\n"); @@ -3762,7 +3763,7 @@ # a getline method which reads lines (mode='r'), or # a print method which reads lines (mode='w') # -# NOTE: this routine assumes that that there aren't any embedded +# NOTE: this routine assumes that there aren't any embedded # newlines within any of the array elements. There are no checks # for that. # @@ -4208,7 +4209,7 @@ sub write_logfile_entry { my $self = shift; - # add leading >>> to avoid confusing error mesages and code + # add leading >>> to avoid confusing error messages and code $self->logfile_output( ">>>", "@_" ); } @@ -6609,6 +6610,7 @@ # the user may be using this section for any purpose whatsoever if ( $rOpts->{'delete-pod'} ) { $skip_line = 1; } if ( $rOpts->{'tee-pod'} ) { $tee_line = 1; } + if ( $rOpts->{'trim-pod'} ) { $input_line =~ s/\s+$// } if ( !$skip_line && $line_type eq 'POD_START' && !$saw_END_or_DATA_ ) @@ -6844,7 +6846,7 @@ # if we are beyond the midpoint $gnu_position_predictor > $mll - $rOpts_maximum_line_length / 2 - # or we are beyont the 1/4 point and there was an old + # or we are beyond the 1/4 point and there was an old # break at the equals || ( $gnu_position_predictor > @@ -7267,7 +7269,7 @@ sub finish_lp_batch { - # This routine is called once after each each output stream batch is + # This routine is called once after each output stream batch is # finished to undo indentation for all incomplete -lp # indentation levels. It is too risky to leave a level open, # because then we can't backtrack in case of a long line to follow. @@ -7714,8 +7716,8 @@ push @_, ','; @is_anon_sub_brace_follower{@_} = (1) x scalar(@_); - # what can follow a one-line anonynomous sub closing curly: - # one-line anonumous subs also have ']' here... + # what can follow a one-line anonymous sub closing curly: + # one-line anonymous subs also have ']' here... # see tk3.t and PP.pm @_ = qw# ; : => or and && || ) ] ~~ !~~ #; push @_, ','; @@ -8162,7 +8164,7 @@ ( ( $tokenl =~ /([\'\w]|\:\:)$/ && $typel ne 'CORE::' ) && ( $tokenr =~ /^([\'\w]|\:\:)/ ) ) - # do not combine a number with a concatination dot + # do not combine a number with a concatenation dot # example: pom.caputo: # $vt100_compatible ? "\e[0;0H" : ('-' x 78 . "\n"); || ( ( $typel eq 'n' ) && ( $tokenr eq '.' ) ) @@ -8975,7 +8977,7 @@ # $type = type # $not_first_token = should be TRUE if this is not the first token of # the line. It might the index of this token in an array. It is - # used to test for a side comment vs a block commment. + # used to test for a side comment vs a block comment. # Note: Eventually this should be the only routine determining the # length of a token in this package. my ( $token, $type, $not_first_token ) = @_; @@ -9580,7 +9582,7 @@ $token =~ /^(s|tr|y|m|\/)/ && $last_nonblank_token =~ /^(=|==|!=)$/ - # precededed by simple scalar + # preceded by simple scalar && $last_last_nonblank_type eq 'i' && $last_last_nonblank_token =~ /^\$/ @@ -9588,7 +9590,7 @@ # (but give complaint if we can's see far enough ahead) && $next_nonblank_token =~ /^[; \)\}]$/ - # scalar is not decleared + # scalar is not declared && !( $types_to_go[0] eq 'k' && $tokens_to_go[0] =~ /^(my|our|local)$/ @@ -9777,7 +9779,7 @@ # patch until some block type issues are fixed: # Do not add semi-colon for block types '{', # '}', and ';' because we cannot be sure yet - # that this is a block and not an anonomyous + # that this is a block and not an anonymous # hash (blktype.t, blktype1.t) && ( $block_type !~ /^[\{\};]$/ ) @@ -10422,7 +10424,7 @@ } else { - # cannot use one-line blocks with cuddled else else/elsif lines + # cannot use one-line blocks with cuddled else/elsif lines if ( ( $tokens_to_go[0] eq '}' ) && $rOpts_cuddled_else ) { return 0; } @@ -10609,7 +10611,7 @@ sub undo_ci { # Undo continuation indentation in certain sequences - # For example, we can undo continuation indation in sort/map/grep chains + # For example, we can undo continuation indentation in sort/map/grep chains # my $dat1 = pack( "n*", # map { $_, $lookup->{$_} } # sort { $a <=> $b } @@ -10643,7 +10645,7 @@ { # chain continues... - # check for chain ending at end of a a statement + # check for chain ending at end of a statement if ( $line == $max_line ) { # see of this line ends a statement @@ -11851,7 +11853,7 @@ # output = ## end foreach my $foo ( sort { $b ...}) # NOTE: This routine does not currently filter out structures within - # quoted text because the bounce algorithims in text editors do not + # quoted text because the bounce algorithms in text editors do not # necessarily do this either (a version of vim was checked and # did not do this). @@ -12213,7 +12215,7 @@ && ( ( $terminal_type eq ';' && $level_end <= $lev ) || ( $terminal_type ne ':' && $level_end < $lev ) ) - # the termainal term must not contain any ternary terms, as in + # the terminal term must not contain any ternary terms, as in # my $ECHO = ( # $Is_MSWin32 ? ".\\echo$$" # : $Is_MacOS ? ":echo$$" @@ -12378,7 +12380,7 @@ # Make the container name even more unique if necessary. # If we are not vertically aligning this opening paren, # append a character count to avoid bad alignment because - # it usually looks bad to align commas within continers + # it usually looks bad to align commas within containers # for which the opening parens do not align. Here # is an example very BAD alignment of commas (because # the atan2 functions are not all aligned): @@ -12865,7 +12867,7 @@ # allow just one character before the comma && $i_terminal == $ibeg + 1 - # requre LIST environment; otherwise, we may outdent too much -- + # require LIST environment; otherwise, we may outdent too much - # this can happen in calls without parentheses (overload.t); && $container_environment_to_go[$i_terminal] eq 'LIST' ) @@ -13755,7 +13757,7 @@ } else { - # start at end and walk bakwards.. + # start at end and walk backwards.. for ( my $i = $iend ; $i >= $ibeg ; $i-- ) { # skip past any side comment and blanks @@ -13837,7 +13839,7 @@ # 5. Values below NOMINAL are considered ok break points. # 6. Values above NOMINAL are considered poor break points. # - # The bond strengths should roughly follow precenence order where + # The bond strengths should roughly follow precedence order where # possible. If you make changes, please check the results very # carefully on a variety of scripts. Testing with the -extrude # options is particularly helpful in exercising all of the rules. @@ -13982,7 +13984,7 @@ x= ); - # Default is is to break AFTER various assignment operators + # Default is to break AFTER various assignment operators @left_bond_strength{@_} = (STRONG) x scalar(@_); @right_bond_strength{@_} = ( 0.4 * WEAK + 0.6 * VERY_WEAK ) x scalar(@_); @@ -14468,7 +14470,7 @@ # (extrude.t) elsif ( $type eq 'Z' ) { - # dont break.. + # don't break.. if ( # if there is no blank and we do not want one. Examples: @@ -15611,7 +15613,7 @@ set_forced_breakpoint( $last_dot_index[$depth] ); } - # break before opening structure if preeced by another + # break before opening structure if preceded by another # closing structure and a comma. This is normally # done by the previous closing brace, but not # if it was a one-line block. @@ -16075,13 +16077,13 @@ } #my ( $a, $b, $c ) = caller(); -#print "LISTX: in set_list $a $c interupt=$interrupted count=$item_count +#print "LISTX: in set_list $a $c interrupt=$interrupted count=$item_count #i_first = $i_first_comma i_last=$i_last_comma max=$max_index_to_go\n"; #print "depth=$depth has_broken=$has_broken_sublist[$depth] is_multi=$is_multiline opening_paren=($i_opening_paren) \n"; #--------------------------------------------------------------- # Interrupted List Rule: - # A list is is forced to use old breakpoints if it was interrupted + # A list is forced to use old breakpoints if it was interrupted # by side comments or blank lines, or requested by user. #--------------------------------------------------------------- if ( $rOpts_break_at_old_comma_breakpoints @@ -16365,7 +16367,7 @@ # or if this is a sublist of a larger list || $in_hierarchical_list - # or if multiple commas and we dont have a long first or last + # or if multiple commas and we don't have a long first or last # term || ( $comma_count > 1 && !( $long_last_term || $long_first_term ) ) @@ -17392,7 +17394,7 @@ && ( $leading_amp_count == 0 || $type_ibeg_2 !~ /^(:|\&\&|\|\|)$/ ) - # but leading colons probably line up with with a + # but leading colons probably line up with a # previous colon or question (count could be wrong). && $type_ibeg_2 ne ':' @@ -17786,7 +17788,7 @@ ) # ... or this would strand a short quote , like this - # . "some long qoute" + # . "some long quote" # . "\n"; || ( $types_to_go[$i_next_nonblank] eq 'Q' @@ -18601,7 +18603,7 @@ # break It is only called if a breakpoint is required or # desired. This will probably need some adjustments # over time. A goal is to try to be sure that, if a new - # side comment is introduced into formated text, then + # side comment is introduced into formatted text, then # the same breakpoints will occur. scbreak.t last if ( @@ -20276,7 +20278,7 @@ my $case = 1; # See if case 2: both lines have leading '=' - # We'll require smiliar leading patterns in this case + # We'll require similar leading patterns in this case my $old_rtokens = $old_line->get_rtokens(); my $rtokens = $new_line->get_rtokens(); my $rpatterns = $new_line->get_rpatterns(); @@ -20667,7 +20669,7 @@ # TBD: add handling for 'case' return unless ( $rfields_old->[0] =~ /^(if|elsif|unless)\s*$/ ); - # look for the opening brace after the else, and extrace the depth + # look for the opening brace after the else, and extract the depth my $tok_brace = $rtokens->[0]; my $depth_brace; if ( $tok_brace =~ /^\{(\d+)/ ) { $depth_brace = $1; } @@ -20893,7 +20895,7 @@ # when the pattern's don't match, because it can be # worse to create an alignment where none is needed # than to omit one. Here's an example where the ','s - # are not in named continers. The first line below + # are not in named containers. The first line below # should not match the next two: # ( $a, $b ) = ( $b, $r ); # ( $x1, $x2 ) = ( $x2 - $q * $x1, $x1 ); @@ -21405,7 +21407,7 @@ $move = $min_move; } - # prevously, an upper bound was placed on $move here, + # previously, an upper bound was placed on $move here, # (maximum_space_to_comment), but it was not helpful # don't exceed the available space @@ -21600,7 +21602,7 @@ # list before it sees everything. When this happens, it sets # the indentation to the standard scheme, but notes how # many spaces it would have liked to use. We may be able - # to recover that space here in the event that that all of the + # to recover that space here in the event that all of the # lines of a list are back together again. #---------------------------------------------------------- @@ -22560,7 +22562,7 @@ use Carp; -# PACKAGE VARIABLES for for processing an entire FILE. +# PACKAGE VARIABLES for processing an entire FILE. use vars qw{ $tokenizer_self @@ -22929,7 +22931,7 @@ write_logfile_entry("Suggest including 'use strict;'\n"); } - # it is suggested that lables have at least one upper case character + # it is suggested that labels have at least one upper case character # for legibility and to avoid code breakage as new keywords are introduced if ( $tokenizer_self->{_rlower_case_labels_at} ) { my @lower_case_labels_at = @@ -23119,7 +23121,7 @@ } # must print line unchanged if we have seen a severe error (i.e., we - # are seeing illegal tokens and connot continue. Syntax errors do + # are seeing illegal tokens and cannot continue. Syntax errors do # not pass this route). Calling routine can decide what to do, but # the default can be to just pass all lines as if they were after __END__ elsif ( $tokenizer_self->{_in_error} ) { @@ -23997,7 +23999,7 @@ $tokenizer_self->{_saw_perl_dash_w} = 1; } - # Check for indentifier in indirect object slot + # Check for identifier in indirect object slot # (vorboard.pl, sort.t). Something like: # /^(print|printf|sort|exec|system)$/ if ( @@ -24205,7 +24207,7 @@ '/' => sub { my $is_pattern; - if ( $expecting == UNKNOWN ) { # indeterminte, must guess.. + if ( $expecting == UNKNOWN ) { # indeterminate, must guess.. my $msg; ( $is_pattern, $msg ) = guess_if_pattern_or_division( $i, $rtokens, $rtoken_map, @@ -24328,9 +24330,10 @@ $max_token_index ); # remember a preceding smartmatch operator - if ( $last_nonblank_type eq '~~' ) { - $block_type = $last_nonblank_type; - } + ## SMARTMATCH + ##if ( $last_nonblank_type eq '~~' ) { + ## $block_type = $last_nonblank_type; + ##} # patch to promote bareword type to function taking block if ( $block_type @@ -24379,7 +24382,9 @@ # propagate type information for 'do' and 'eval' blocks, and also # for smartmatch operator. This is necessary to enable us to know # if an operator or term is expected next. - if ( $is_block_operator{$block_type} || $block_type eq '~~' ) { + ## SMARTMATCH + ##if ( $is_block_operator{$block_type} || $block_type eq '~~' ) { + if ( $is_block_operator{$block_type} ) { $tok = $block_type; } @@ -24952,7 +24957,7 @@ if ( ( $untrimmed_input_line =~ /^=[A-Za-z_]/ ) ) { # must not be in multi-line quote - # and must not be in an eqn + # and must not be in an equation if ( !$in_quote and ( operator_expected( 'b', '=', 'b' ) == TERM ) ) { $tokenizer_self->{_in_pod} = 1; @@ -25853,7 +25858,7 @@ # running value of this variable is $level_in_tokenizer. # # The total continuation is much more difficult to compute, and requires -# several variables. These veriables are: +# several variables. These variables are: # # $ci_string_in_tokenizer = a string of 1's and 0's indicating, for # each indentation level, if there are intervening open secondary @@ -25865,7 +25870,7 @@ # indentation level, if the level is of type BLOCK or not. # $nesting_block_flag = the most recent 1 or 0 of $nesting_block_string # $nesting_list_string = a string of 1's and 0's indicating, for each -# indentation level, if it is is appropriate for list formatting. +# indentation level, if it is appropriate for list formatting. # If so, continuation indentation is used to indent long list items. # $nesting_list_flag = the most recent 1 or 0 of $nesting_list_string # @{$rslevel_stack} = a stack of total nesting depths at each @@ -26085,7 +26090,7 @@ $indented_if_level = $level_in_tokenizer; } - # do not change container environement here if we are not + # do not change container environment here if we are not # at a real list. Adding this check prevents "blinkers" # often near 'unless" clauses, such as in the following # code: @@ -26242,7 +26247,7 @@ } # If we are in a list, then - # we must set continuatoin indentation at the closing + # we must set continuation indentation at the closing # paren of something like this (paren after $check): # assert( # __LINE__, @@ -26348,10 +26353,10 @@ } } - # set secondary nesting levels based on all continment token types + # set secondary nesting levels based on all containment token types # Note: these are set so that the nesting depth is the depth # of the PREVIOUS TOKEN, which is convenient for setting - # the stength of token bonds + # the strength of token bonds my $slevel_i = $slevel_in_tokenizer; # /^[L\{\(\[]$/ @@ -26531,7 +26536,7 @@ } # something like $a = do { BLOCK } / 2; - # or this ? after a smartmatch anonynomous hash or array reference: + # or this ? after a smartmatch anonynmous hash or array reference: # qr/3/ ~~ ['1234'] ? 1 : 0; # ^ else { @@ -26860,7 +26865,7 @@ push @pre_tokens, @$rpre_tokens; } - # put a sentinal token to simplify stopping the search + # put a sentinel token to simplify stopping the search push @pre_types, '}'; my $jbeg = 0; @@ -27524,7 +27529,7 @@ if ( $type eq 'w' ) { # check for v-string with leading 'v' type character - # (This seems to have presidence over filehandle, type 'Y') + # (This seems to have precedence over filehandle, type 'Y') if ( $tok =~ /^v\d[_\d]*$/ ) { # we only have the first part - something like 'v101' - @@ -28178,10 +28183,10 @@ # # We have to be careful here. If we are in an unknown state, # we will reject the punctuation variable. In the following - # example the '&' is a binary opeator but we are in an unknown + # example the '&' is a binary operator but we are in an unknown # state because there is no sigil on 'Prima', so we don't # know what it is. But it is a bad guess that - # '&~' is a punction variable. + # '&~' is a function variable. # $self->{text}->{colorMap}->[ # Prima::PodView::COLOR_CODE_FOREGROUND # & ~tb::COLOR_INDEX ] = @@ -28617,7 +28622,7 @@ sub pattern_expected { # This is the start of a filter for a possible pattern. - # It looks at the token after a possbible pattern and tries to + # It looks at the token after a possible pattern and tries to # determine if that token could end a pattern. # returns - # 1 - yes @@ -28727,7 +28732,7 @@ my $str = substr( $input_line, $pos_beg, ( $pos - $pos_beg ) ); # Reject if the closing '>' follows a '-' as in: - # if ( VERSION < 5.009 && $op-> name eq 'aassign' ) { } + # if ( VERSION < 5.009 && $op-> name eq 'assign' ) { } if ( $expecting eq UNKNOWN ) { my $check = substr( $input_line, $pos - 2, 1 ); if ( $check eq '-' ) { @@ -29559,7 +29564,7 @@ # these functions have prototypes of the form (&), so when they are # followed by a block, that block MAY BE followed by an operator. - # Smartmatch operator ~~ may be followed by anonomous hash or array ref + # Smartmatch operator ~~ may be followed by anonymous hash or array ref @_ = qw( do eval ); @is_block_operator{@_} = (1) x scalar(@_); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Perl-Tidy-20130717/lib/Perl/Tidy.pod new/Perl-Tidy-20130806/lib/Perl/Tidy.pod --- old/Perl-Tidy-20130717/lib/Perl/Tidy.pod 2013-07-17 00:30:58.000000000 +0200 +++ new/Perl-Tidy-20130806/lib/Perl/Tidy.pod 2013-08-06 02:50:10.000000000 +0200 @@ -105,7 +105,7 @@ for each file and it would be very confusing if they were combined. However if perltidy is called to process just a single perl script then it may -be more conveninent to combine the B<errorfile> stream with the B<stderr> +be more convenient to combine the B<errorfile> stream with the B<stderr> stream. This can be done by setting the B<-se> parameter, in which case this parameter is ignored. @@ -394,7 +394,7 @@ to get started is to find one of the examples which most closely matches your application and start modifying it. -For help with perltidy's pecular way of breaking lines into tokens, you +For help with perltidy's peculiar way of breaking lines into tokens, you might run, from the command line, perltidy -D filename @@ -416,7 +416,7 @@ =head1 VERSION -This man page documents Perl::Tidy version 20130717. +This man page documents Perl::Tidy version 20130806. =head1 LICENSE -- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
