From: Steve Hancock Date: Fri, 5 Nov 2021 14:07:16 +0000 (-0700) Subject: update comments X-Git-Tag: 20211029.01~31 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=e2e86efab9bdb3cb4b029952f345f0ed514d1e22;p=perltidy.git update comments --- diff --git a/lib/Perl/Tidy/FileWriter.pm b/lib/Perl/Tidy/FileWriter.pm index 4f909903..0f124b4d 100644 --- a/lib/Perl/Tidy/FileWriter.pm +++ b/lib/Perl/Tidy/FileWriter.pm @@ -44,7 +44,8 @@ my $MAX_NAG_MESSAGES = 6; BEGIN { - # Array index names for variables + # Array index names for variables. + # Do not combine with other BEGIN blocks (c101). my $i = 0; use constant { _line_sink_object_ => $i++, diff --git a/lib/Perl/Tidy/IndentationItem.pm b/lib/Perl/Tidy/IndentationItem.pm index f81b9c0f..86cbf4c5 100644 --- a/lib/Perl/Tidy/IndentationItem.pm +++ b/lib/Perl/Tidy/IndentationItem.pm @@ -13,6 +13,7 @@ our $VERSION = '20211029'; BEGIN { # Array index names + # Do not combine with other BEGIN blocks (c101). my $i = 0; use constant { _spaces_ => $i++, diff --git a/lib/Perl/Tidy/Tokenizer.pm b/lib/Perl/Tidy/Tokenizer.pm index 64d3ded2..585a506d 100644 --- a/lib/Perl/Tidy/Tokenizer.pm +++ b/lib/Perl/Tidy/Tokenizer.pm @@ -132,7 +132,8 @@ use constant MAX_NAG_MESSAGES => 6; BEGIN { - # Array index names for $self + # Array index names for $self. + # Do not combine with other BEGIN blocks (c101). my $i = 0; use constant { _rhere_target_list_ => $i++, diff --git a/lib/Perl/Tidy/VerticalAligner.pm b/lib/Perl/Tidy/VerticalAligner.pm index 4306b757..1864b7e0 100644 --- a/lib/Perl/Tidy/VerticalAligner.pm +++ b/lib/Perl/Tidy/VerticalAligner.pm @@ -122,6 +122,7 @@ BEGIN { # Define the fixed indexes for variables in $self, which is an array # reference. Note the convention of leading and trailing underscores to # keep them unique. + # Do not combine with other BEGIN blocks (c101). my $i = 0; use constant { _file_writer_object_ => $i++, diff --git a/lib/Perl/Tidy/VerticalAligner/Alignment.pm b/lib/Perl/Tidy/VerticalAligner/Alignment.pm index 756a8e53..0d2e6d90 100644 --- a/lib/Perl/Tidy/VerticalAligner/Alignment.pm +++ b/lib/Perl/Tidy/VerticalAligner/Alignment.pm @@ -12,13 +12,18 @@ use warnings; our $VERSION = '20211029'; -# _column_ # the current column number -# _saved_column_ # a place for temporary storage -my $i = 0; -use constant { - _column_ => $i++, - _saved_column_ => $i++, -}; +BEGIN { + + # Indexes for variables in $self. + # Do not combine with other BEGIN blocks (c101). + # _column_ # the current column number + # _saved_column_ # a place for temporary storage + my $i = 0; + use constant { + _column_ => $i++, + _saved_column_ => $i++, + }; +} sub new { my ( $class, $rarg ) = @_; diff --git a/lib/Perl/Tidy/VerticalAligner/Line.pm b/lib/Perl/Tidy/VerticalAligner/Line.pm index 84968738..68f9e0e8 100644 --- a/lib/Perl/Tidy/VerticalAligner/Line.pm +++ b/lib/Perl/Tidy/VerticalAligner/Line.pm @@ -11,6 +11,9 @@ use warnings; our $VERSION = '20211029'; BEGIN { + + # Indexes for variables in $self. + # Do not combine with other BEGIN blocks (c101). my $i = 0; use constant { _jmax_ => $i++,