]> git.donarmstrong.com Git - perltidy.git/log
perltidy.git
2 years agoavoid poor alignment of lines with different ci (issue c225)
Steve Hancock [Thu, 15 Jun 2023 13:48:30 +0000 (06:48 -0700)]
avoid poor alignment of lines with different ci (issue c225)

2 years agofix doc
Steve Hancock [Wed, 14 Jun 2023 18:45:30 +0000 (11:45 -0700)]
fix doc

2 years agoDo not align opening braces across ci level changes (c224)
Steve Hancock [Wed, 14 Jun 2023 18:24:17 +0000 (11:24 -0700)]
Do not align opening braces across ci level changes (c224)

2 years agoupdate docs for -xbt and -xbtl
Steve Hancock [Wed, 14 Jun 2023 18:23:07 +0000 (11:23 -0700)]
update docs for -xbt and -xbtl

2 years agoremove any space between isolated '$' and '{' (c221)
Steve Hancock [Mon, 12 Jun 2023 02:21:44 +0000 (19:21 -0700)]
remove any space between isolated '$' and '{' (c221)

2 years agoavoid testing files known to produce errors
Steve Hancock [Sun, 11 Jun 2023 21:56:29 +0000 (14:56 -0700)]
avoid testing files known to produce errors

2 years agofix semicolon count; minor code cleanups
Steve Hancock [Sun, 11 Jun 2023 19:07:50 +0000 (12:07 -0700)]
fix semicolon count; minor code cleanups

2 years agobump vertion to 20230309.03 20230309.03
Steve Hancock [Sat, 10 Jun 2023 22:12:44 +0000 (15:12 -0700)]
bump vertion to 20230309.03

2 years agoadd parameters -xbt, -xbtl; see issue git #121
Steve Hancock [Sat, 10 Jun 2023 02:55:08 +0000 (19:55 -0700)]
add parameters -xbt, -xbtl; see issue git #121

2 years agosimplify and improve efficiency of sub set_ci
Steve Hancock [Tue, 6 Jun 2023 01:20:31 +0000 (18:20 -0700)]
simplify and improve efficiency of sub set_ci

2 years agoincrease max_mccabe
Steve Hancock [Tue, 6 Jun 2023 01:20:16 +0000 (18:20 -0700)]
increase max_mccabe

2 years agofix undef when -dbs applied to script without subs
Steve Hancock [Mon, 5 Jun 2023 01:50:54 +0000 (18:50 -0700)]
fix undef when -dbs applied to script without subs

2 years agosimplify coding to use available comma counts
Steve Hancock [Sun, 4 Jun 2023 23:51:06 +0000 (16:51 -0700)]
simplify coding to use available comma counts

2 years agoimprove formatting of sort/map/grep blocks
Steve Hancock [Mon, 29 May 2023 13:14:27 +0000 (06:14 -0700)]
improve formatting of sort/map/grep blocks

2 years agominor optimization
Steve Hancock [Sun, 28 May 2023 00:36:25 +0000 (17:36 -0700)]
minor optimization

2 years agoadd a clarifying comment
Steve Hancock [Sun, 28 May 2023 00:36:05 +0000 (17:36 -0700)]
add a clarifying comment

2 years agooptimization
Steve Hancock [Fri, 26 May 2023 22:05:50 +0000 (15:05 -0700)]
optimization

2 years agooptimizations
Steve Hancock [Fri, 26 May 2023 17:50:44 +0000 (10:50 -0700)]
optimizations

2 years agofix spelling
Steve Hancock [Fri, 26 May 2023 17:50:30 +0000 (10:50 -0700)]
fix spelling

2 years agofix ci of a comment in a ternary expression
Steve Hancock [Thu, 25 May 2023 20:14:24 +0000 (13:14 -0700)]
fix ci of a comment in a ternary expression

2 years agoupdate docs
Steve Hancock [Thu, 25 May 2023 20:13:50 +0000 (13:13 -0700)]
update docs

2 years agoOptimizations, mostly avoiding needless calls
Steve Hancock [Wed, 24 May 2023 17:06:49 +0000 (10:06 -0700)]
Optimizations, mostly avoiding needless calls

2 years agoreformat
Steve Hancock [Wed, 24 May 2023 16:36:59 +0000 (09:36 -0700)]
reformat

2 years agoupdate docs
Steve Hancock [Wed, 24 May 2023 16:36:39 +0000 (09:36 -0700)]
update docs

2 years agooptimization of sub tokenizer_wrapup_no_ci
Steve Hancock [Mon, 22 May 2023 19:50:33 +0000 (12:50 -0700)]
optimization of sub tokenizer_wrapup_no_ci

2 years agoupdate docs
Steve Hancock [Mon, 22 May 2023 19:50:19 +0000 (12:50 -0700)]
update docs

2 years agoupdate docs
Steve Hancock [Sat, 20 May 2023 02:12:39 +0000 (19:12 -0700)]
update docs

2 years agoadd doc on ci update
Steve Hancock [Sat, 20 May 2023 00:33:12 +0000 (17:33 -0700)]
add doc on ci update

2 years agooptimization of some new code
Steve Hancock [Fri, 19 May 2023 16:27:00 +0000 (09:27 -0700)]
optimization of some new code

2 years agoactivate sub set_ci
Steve Hancock [Fri, 19 May 2023 02:59:30 +0000 (19:59 -0700)]
activate sub set_ci

2 years agoadd option to skip ci calc in tokenizer
Steve Hancock [Wed, 17 May 2023 14:21:48 +0000 (07:21 -0700)]
add option to skip ci calc in tokenizer

This will be the future default

2 years agorecent updates to sub set_ci
Steve Hancock [Tue, 16 May 2023 21:32:03 +0000 (14:32 -0700)]
recent updates to sub set_ci

all open issues with sub set_ci have been resolved

2 years agominor fixes for sub set_ci
Steve Hancock [Wed, 10 May 2023 20:42:38 +0000 (13:42 -0700)]
minor fixes for sub set_ci

2 years agominor fixes for sub set_ci
Steve Hancock [Sun, 7 May 2023 13:52:19 +0000 (06:52 -0700)]
minor fixes for sub set_ci

2 years agominor fixes to sub set_ci
Steve Hancock [Fri, 5 May 2023 13:52:21 +0000 (06:52 -0700)]
minor fixes to sub set_ci

2 years agoimprove indentation of comments within deeply nested ternaries
Steve Hancock [Sun, 30 Apr 2023 22:29:22 +0000 (15:29 -0700)]
improve indentation of comments within deeply nested ternaries

2 years agostreamline sub set_ci
Steve Hancock [Sat, 29 Apr 2023 04:21:02 +0000 (21:21 -0700)]
streamline sub set_ci

2 years agoimprove and optimize sub set_ci
Steve Hancock [Fri, 28 Apr 2023 02:24:46 +0000 (19:24 -0700)]
improve and optimize sub set_ci

2 years agoInsure correct marking of a brace following a format stmt
Steve Hancock [Wed, 26 Apr 2023 12:45:38 +0000 (05:45 -0700)]
Insure correct marking of a brace following a format stmt

This does not change formatting but insures that braces
are correctly marked. This fixes issue c202/t032.

2 years agoadd sub set_ci
Steve Hancock [Wed, 26 Apr 2023 12:39:53 +0000 (05:39 -0700)]
add sub set_ci

This will be the new method for computing ci after testing.

2 years agoupdate for issue git #118
Steve Hancock [Thu, 13 Apr 2023 03:37:37 +0000 (20:37 -0700)]
update for issue git #118

2 years agosome tokenizer clean-ups, part 15
Steve Hancock [Wed, 5 Apr 2023 00:04:03 +0000 (17:04 -0700)]
some tokenizer clean-ups, part 15

2 years agosome tokenizer clean-ups, part 14
Steve Hancock [Tue, 4 Apr 2023 21:23:09 +0000 (14:23 -0700)]
some tokenizer clean-ups, part 14

2 years agosome tokenizer clean-ups, part 13
Steve Hancock [Tue, 4 Apr 2023 18:37:21 +0000 (11:37 -0700)]
some tokenizer clean-ups, part 13

2 years agoupdate markup language filter
Steve Hancock [Mon, 3 Apr 2023 04:18:21 +0000 (21:18 -0700)]
update markup language filter

2 years agoremove unused code
Steve Hancock [Sun, 2 Apr 2023 23:34:44 +0000 (16:34 -0700)]
remove unused code

2 years agoimprove html detection
Steve Hancock [Sun, 2 Apr 2023 14:31:34 +0000 (07:31 -0700)]
improve html detection

Add code to guard against reformatting a file written in a markup language

2 years agofix c208, misparse of '$1x$2'
Steve Hancock [Thu, 30 Mar 2023 23:41:42 +0000 (16:41 -0700)]
fix c208, misparse of '$1x$2'

This was found in some obfuscated perl code.

2 years agosome tokenizer clean-ups, part 12
Steve Hancock [Thu, 30 Mar 2023 21:46:22 +0000 (14:46 -0700)]
some tokenizer clean-ups, part 12

2 years agosome tokenizer clean-ups, part 11
Steve Hancock [Thu, 30 Mar 2023 03:03:18 +0000 (20:03 -0700)]
some tokenizer clean-ups, part 11

2 years agosome tokenizer clean-ups, part 10
Steve Hancock [Thu, 30 Mar 2023 00:13:22 +0000 (17:13 -0700)]
some tokenizer clean-ups, part 10

2 years agosome tokenizer clean-ups, part 9
Steve Hancock [Wed, 29 Mar 2023 21:40:55 +0000 (14:40 -0700)]
some tokenizer clean-ups, part 9

2 years agosome tokenizer clean-ups, part 8
Steve Hancock [Wed, 29 Mar 2023 20:15:13 +0000 (13:15 -0700)]
some tokenizer clean-ups, part 8

2 years agosome tokenizer clean-ups, part 7
Steve Hancock [Wed, 29 Mar 2023 00:07:13 +0000 (17:07 -0700)]
some tokenizer clean-ups, part 7

2 years agosome tokenizer clean-ups, part 6
Steve Hancock [Tue, 28 Mar 2023 13:57:42 +0000 (06:57 -0700)]
some tokenizer clean-ups, part 6

2 years agosome tokenizer clean-ups, part 5
Steve Hancock [Mon, 27 Mar 2023 13:38:19 +0000 (06:38 -0700)]
some tokenizer clean-ups, part 5

2 years agosome tokenizer clean-ups, part 4
Steve Hancock [Sun, 26 Mar 2023 02:38:24 +0000 (19:38 -0700)]
some tokenizer clean-ups, part 4

2 years agobump version to .02 20230309.02
Steve Hancock [Sat, 25 Mar 2023 01:52:51 +0000 (18:52 -0700)]
bump version to .02

2 years agoupdate for issue c206
Steve Hancock [Sat, 25 Mar 2023 01:40:04 +0000 (18:40 -0700)]
update for issue c206

2 years agoparam --valign-if-unless, -viu, added for git #116
Steve Hancock [Sat, 25 Mar 2023 01:34:17 +0000 (18:34 -0700)]
param --valign-if-unless, -viu, added for git #116

2 years agosome tokenizer clean-ups, part 3
Steve Hancock [Thu, 23 Mar 2023 18:34:01 +0000 (11:34 -0700)]
some tokenizer clean-ups, part 3

2 years agosome tokenizer clean-ups, part 2
Steve Hancock [Wed, 22 Mar 2023 20:41:51 +0000 (13:41 -0700)]
some tokenizer clean-ups, part 2

2 years agosimplify diagnostics object
Steve Hancock [Wed, 22 Mar 2023 14:41:55 +0000 (07:41 -0700)]
simplify diagnostics object

Previously, the diagnostics object made a call back to the tokenizer to get
the input line number. Now the line number arrives as an optional arg.

2 years agosome tokenizer clean-ups, part 1
Steve Hancock [Tue, 21 Mar 2023 16:39:55 +0000 (09:39 -0700)]
some tokenizer clean-ups, part 1

remove unused sub; switch from $tokenizer_self to $self

2 years agoremove unused DIAGNOSTICS parameter, fix comments
Steve Hancock [Mon, 20 Mar 2023 02:37:26 +0000 (19:37 -0700)]
remove unused DIAGNOSTICS parameter, fix comments

2 years agoImprove efficiency of counting and removing leading spaces
Steve Hancock [Sun, 19 Mar 2023 00:31:59 +0000 (17:31 -0700)]
Improve efficiency of counting and removing leading spaces

2 years agoreplace regex with index function for efficiency
Steve Hancock [Sat, 18 Mar 2023 00:30:18 +0000 (17:30 -0700)]
replace regex with index function for efficiency

The index functions are about 3x faster in this critical section.

2 years agoeliminate sub length_tag
Steve Hancock [Fri, 17 Mar 2023 14:01:33 +0000 (07:01 -0700)]
eliminate sub length_tag

This eliminates a large amount of sub call overhead.

2 years agooutput file verbatim for certain lexical sub names
Steve Hancock [Thu, 16 Mar 2023 00:27:34 +0000 (17:27 -0700)]
output file verbatim for certain lexical sub names

Lexical (my) subs which use the builtin names of certain quote-like
operators may cause problems in this version of perltidy.  For example
'my sub s {...}' may cause parsing errors. If something like this is
encountered, then formatting will not be attempted; the file will be
output verbatim.

2 years agoeliminate sub store_space
Steve Hancock [Tue, 14 Mar 2023 23:43:16 +0000 (16:43 -0700)]
eliminate sub store_space

This is now handled by sub store_token to improve efficiency by
reducing per-token sub calls

2 years agomake formatting of 'class' more like 'package'
Steve Hancock [Tue, 14 Mar 2023 00:21:01 +0000 (17:21 -0700)]
make formatting of 'class' more like 'package'

This update makes any 'class' keyword be formatted as if it were
'package' as far as spaces and blank lines go (i.e., -blpb=n flag applies).
This also improves coding efficiency.

2 years agobump version to 20230309.01 20230309.01
Steve Hancock [Mon, 13 Mar 2023 15:16:02 +0000 (08:16 -0700)]
bump version to 20230309.01

This has fixes for git #110 (missing docs) and git #115

2 years agoupdate comments
Steve Hancock [Mon, 13 Mar 2023 15:03:38 +0000 (08:03 -0700)]
update comments

2 years agosome minor cleanups and comment updates
Steve Hancock [Mon, 13 Mar 2023 00:42:11 +0000 (17:42 -0700)]
some minor cleanups and comment updates

2 years agofix git #115
Steve Hancock [Sun, 12 Mar 2023 02:16:58 +0000 (18:16 -0800)]
fix git #115

(Destination incorrectly set to stdout when source is set). The fix proposed
in git #115 is correct, but I decided to pass $source_stream as a new arg
so that the input hash can remain unchanged for possible diagnostic use.

2 years agofix spelling
Steve Hancock [Sat, 11 Mar 2023 01:59:10 +0000 (17:59 -0800)]
fix spelling

2 years agoremove outdated docs
Steve Hancock [Sat, 11 Mar 2023 01:57:55 +0000 (17:57 -0800)]
remove outdated docs

The parameter check-syntax is accepted but now ignored due to security concerns

2 years agoadd tests b1452, b1453
Steve Hancock [Sat, 11 Mar 2023 01:57:26 +0000 (17:57 -0800)]
add tests b1452, b1453

2 years agoadd missing docs for -cpb and -bfvt=n, issue git #110
Steve Hancock [Sat, 11 Mar 2023 01:56:04 +0000 (17:56 -0800)]
add missing docs for -cpb and -bfvt=n, issue git #110

2 years agoupdate version number 20230309
Steve Hancock [Tue, 7 Mar 2023 01:50:20 +0000 (17:50 -0800)]
update version number

This will be the next release to CPAN after testing is complete.

2 years agoremove unused code, update comments
Steve Hancock [Mon, 6 Mar 2023 18:13:32 +0000 (10:13 -0800)]
remove unused code, update comments

2 years agoimprove recombine operation, c200
Steve Hancock [Sat, 4 Mar 2023 15:41:59 +0000 (07:41 -0800)]
improve recombine operation, c200

This update consolidates the three possible optimization methods in the
recombine operation into a single, simpler method which can be
shown to run in linear time.

2 years agoupdate closing side comments
Steve Hancock [Thu, 2 Mar 2023 02:03:57 +0000 (18:03 -0800)]
update closing side comments

2 years agoupdate docs
Steve Hancock [Wed, 1 Mar 2023 23:03:02 +0000 (15:03 -0800)]
update docs

2 years agofix c198
Steve Hancock [Wed, 1 Mar 2023 22:35:57 +0000 (14:35 -0800)]
fix c198

2 years agoupdate some comments and docs
Steve Hancock [Tue, 28 Feb 2023 22:40:01 +0000 (14:40 -0800)]
update some comments and docs

2 years agofix incorrect log message, issue c195
Steve Hancock [Tue, 28 Feb 2023 16:05:21 +0000 (08:05 -0800)]
fix incorrect log message, issue c195

2 years agoremove unused vars
Steve Hancock [Tue, 28 Feb 2023 03:34:40 +0000 (19:34 -0800)]
remove unused vars

2 years agofix c169
Steve Hancock [Mon, 27 Feb 2023 17:43:53 +0000 (09:43 -0800)]
fix c169

2 years agofix b1451
Steve Hancock [Mon, 27 Feb 2023 01:09:58 +0000 (17:09 -0800)]
fix b1451

2 years agoadd recombine optimization when ties are detected
Steve Hancock [Mon, 27 Feb 2023 00:20:05 +0000 (16:20 -0800)]
add recombine optimization when ties are detected

2 years agorestructure recombine operation
Steve Hancock [Fri, 24 Feb 2023 20:59:04 +0000 (12:59 -0800)]
restructure recombine operation

This avoids having a nested loop in a single sub

2 years agosimplify coding for variable _radjusted_levels_
Steve Hancock [Tue, 21 Feb 2023 20:12:16 +0000 (12:12 -0800)]
simplify coding for variable _radjusted_levels_

Coding of the array _radjusted_levels_ can be simplified since it
is now always used.  Previously it was not always available.

2 years agoremove unused vars
Steve Hancock [Mon, 20 Feb 2023 23:56:12 +0000 (15:56 -0800)]
remove unused vars

I found these with a utility I wrote to scan for unused vars.  Most are
remnants from debugging, or variables that might have been useful but
were not actually used.  I left a few unused hashes in the tokenizer which
might be useful in the future.

2 years agosimplify recombine optimization
Steve Hancock [Mon, 20 Feb 2023 19:15:56 +0000 (11:15 -0800)]
simplify recombine optimization

2 years agobe sure output batches do not end in a blank token
Steve Hancock [Sun, 19 Feb 2023 03:17:27 +0000 (19:17 -0800)]
be sure output batches do not end in a blank token

They will not be output but might cause incorrect line length calcs

2 years agosimplify calculation of some flags in sub recombine
Steve Hancock [Sun, 19 Feb 2023 00:55:47 +0000 (16:55 -0800)]
simplify calculation of some flags in sub recombine

2 years agocleanup sub check_old_breakpoints
Steve Hancock [Fri, 17 Feb 2023 23:49:21 +0000 (15:49 -0800)]
cleanup sub check_old_breakpoints

2 years agoimprove recombine reverse normal mode
Steve Hancock [Fri, 17 Feb 2023 21:43:08 +0000 (13:43 -0800)]
improve recombine reverse normal mode

2 years agofix issue c190
Steve Hancock [Fri, 17 Feb 2023 05:39:33 +0000 (21:39 -0800)]
fix issue c190