1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374
|
Revision history for PPR
0.000001 Wed May 27 15:12:24 2015
* Initial release.
0.000003 Tue Jun 20 06:05:22 2017
* No changes logged
0.000005 Tue Jun 20 19:27:37 2017
* Added missing PPR::X module
(Thanks MST)
0.000006 Thu Jun 22 21:04:14 2017
* Fixed documentation bug with slurp (pre-)example.
(Thanks, Randal!)
* Optimized matching of builtins slightly
* Added $PPR::ERROR variable to assist error reporting on failure to match
(Many thanks, MST!)
0.000007 Fri Jun 23 06:45:49 2017
* Improved $PPR::ERROR API by adding origin location and diagnostics
0.000008 Sun Jun 25 15:24:13 2017
* Unknotted POD nits.
* Small optimizations to keyword and identifier recognition.
* Fixed handling of multiline quotelikes that span heredoc contents.
(Thanks Lukas)
* SIGNIFICANT CHANGE: The $PPR::GRAMMAR variable now has to be
interpolated at the start of any regex using it.
* Fixed handling of layered heredocs (at the cost of having to install
$PPR::GRAMMAR at the start of each grammar).
(Thanks Lukas)
* Fixed diamond operator parsing.
(Thanks Lukas)
0.000009 Thu Jun 29 08:17:24 2017
* SIGNIFICANT REVERSION: The $PPR::GRAMMAR variable no longer
has to be interpolated at the start of any regex using it.
Indeed, that placement is not recommended due to its effects
on the numbering of positional captures within the main regex.
* Fixed test files to allow testing under 5.10+, rather than 5.14+
0.000010 Fri Jul 14 07:36:47 2017
* Added yada-yada (...) statement
(Thanks, MST!)
0.000011 Fri Aug 11 17:52:14 2017
* Further optimized parsing of heredocs
* Eliminated even more repetition backtracking
(bringing the grammar ever closer to DFA-osity)
* Micro-optimization: Reordered PerlOWS and PerlNWS components to
reflect that \n whitespace is more common that # comments or
__END__ blocks
* Made formats and heredocs play nice together by adding a potential
heredoc skip at the end of the first line of a format.
(Sincere thanks to Merijn)
* Made interpolating quotelikes work (more) correctly.
0.000012 Mon Aug 21 20:40:08 2017
* Handled /.../n flag
(thanks, David)
* Handled leading BOM correctly
(thanks, David)
* Handled ${!}-style punctuation variables
(thanks, David)
* "fline" is not a word (thanks, Hugo ;-)
* Added (?&PerlEndOfLine)
(Thanks, Yves)
* Handled s/.../.../e behaviour better.
Still not perfect, but perfection may not be possible using regexes.
(Thanks, Aaron!)
* Neutralized bizarre undefined warnings
under earlier Perl versions.
0.000013 Mon Aug 21 20:54:42 2017
* Removed spurious Regexp::Debugger dependency
(Thanks Slaven!)
0.000014 Thu Sep 28 21:43:51 2017
* Added BAIL_OUTs to test suite to accelerate
and clarify testing under Perl 5.20
* Added missing optional whitespace to DESTROY and AUTOLOAD declarations
(thanks, Hauke D)
0.000015 Wed Dec 6 08:18:09 2017
* Fixed disapproval.t test
(Thanks, Martin!)
* Fixed handling of ->$*, ->@*, and ->%*
(Thanks, Curtis!)
0.000016 Mon Jun 4 13:58:06 2018
* Uninlined optimizations in PPR::X to make redeclaration
of subrules easier and more reliable.
(Thanks, Matt!)
* Added (?&PerlReturnExpression) to distinguish
in-term usages from statement-level usages
requiring (?&PerlReturnStatement)
0.000017 Tue Jun 19 07:57:57 2018
* Added PPR::decomment()
(mostly as an example of technique)
* Updated for loop parsing to support explicitly aliased iterator variables
(including arrays and hashes)
* Added (?&PerlTermPostfixDereference) to simplify PPR::X overloading of terms
* Added Perl 5.28 ":attributes(before) ($ignature)" syntax for subroutines
(thanks, Matt)
0.000018 Mon Jun 25 09:59:36 2018
* Fixed _uniq()
(thanks Adriano!)
0.000019 Tue Jun 26 19:33:17 2018
* Fixed parsing of multiple POD sections
(thanks Adriano!)
0.000020 Tue Jun 26 19:54:42 2018
* Oops, fixed decomment() too.
* Updates PPR::X appropriately as well.
0.000021 Wed Jun 27 06:33:51 2018
* Removed spurious Regexp::Debugger dependency
(thanks, Adriano)
* Fixed edge case on POD/whitespace parsing
(thanks, Adriano)
0.000022 Fri Oct 5 07:10:33 2018
* Optimized calls to (?&PerlStatementSequence) and (?&PerlPodSequence)
(thanks, Adriano)
* Optimized several tests to remove unnecessary (?&PerlOWS) calls
(thanks, Adriano)
0.000023 Fri Feb 15 09:20:25 2019
* Fixed (?&PerlScalarExpression)
0.000024 Tue Dec 10 05:20:23 2019
* Relaxed parsing of __DATA__ and __END__ in line with actual Perl parser
* Numerous doc bugs fixed (thanks F.Li!)
0.000025 Wed Apr 22 22:19:14 2020
* Added full code block parsing of
(?{...}) and (??{...}) within regexes
* Fixed an obscure problem when heredocs are greater than 32766 characters
(thanks Albert!)
0.000026 Fri Apr 24 04:39:59 2020
* Improved detection of trailing unbalanced curlies in decomment()
(thanks Albert)
* Added (?&PerlEntireDocument) rule
* BACKWARDS INCOMPATIBLE CHANGE:
PPR::decomment() now retains all newlines from any comments, POD, etc.
that it removes. This does not change the meaning or behaviour
of the decommented source code in any way, but ensures that consistent
line numbers are preserved through the operation.
(thanks Albert)
0.000027 Thu Jun 25 07:12:58 2020
* Tweaked handling of unary prefix operators to correctly
identify '++' and '--' as atomic lexemes
* Added correct parsing of lexical subroutines
0.000028 Sun Jun 28 02:58:01 2020
* Corrected edge-case behaviour in parsing __END__ and __DATA__
by adding the (?&PerlOWSOrEND) rule
(many thanks, Branislav!)
* Corrected edge-case behaviour in parsing of s/.../.../e constructs
0.001000 Wed Aug 3 00:33:24 2022
* Improved parsing of modern subroutine signatures
(Thanks, Juerd!)
* Now supports all the new syntactic features
added in Perls v5.28 to v5.36 including:
- try/catch/finally
- the isa operator
- named regex assertions
- missing lower bounds on regex counted repetitions
- "spacey" curlies in regexes
- 0o7777 octal constants
- Unicode paired delimiters on quotelikes
* Improved parsing of s/.../{...}e code blocks
(Thanks, Zaki!)
* Fixed several edge cases of postfix dereferencing
(Thanks, Zaki!)
* The perlop manpage states:
"Interpolation in patterns has several quirks:
$|, $(, and $) are not interpolated..."
PPR now enforces that.
(Thanks, Zaki!)
* Also fixed NON-interpolation of variables
inside qq'...', qr'...', etc.
(Thanks, Zaki!)
* NOTE: BACKWARDS INCOMPATIBLE CHANGE...
Solving some of the above issues required deep changes to the mechanism
of term-matching within the regex...to better reflect actual term precedence
within Perl. This means that the subrules (?&PerlTerm), (?&PerlScalarAccess)
and (?&PerlArrayAccess) now match differently. Specifically, (?&PerlTerm)
now matches chains of trailing -> dereferences and/or -> sub/method calls,
while (?&PerlScalarAccess) and (?&PerlArrayAccess) no longer do so.
If you were previously using these last two subrules for stand-along matching
you will need to be more specific:
# Old behaviour of... # Now requires...
/ (?&PerlScalarAccess) /x / (?&PerlScalarAccess) (?&PerlTermPostfixDerefence) /x
/ (?&PerlArrayAccess) /x / (?&PerlArrayAccess) (?&PerlTermPostfixDerefence) /x
0.001001 Wed Aug 3 01:52:51 2022
* Added try/catch/finally/defer to the list of keywords
that are never treated as barewords
* Corrected parsing of try/catch syntax
(the catch block is not optional!)
* Updated workarounds for parsing code that uses Try::Tiny and TryCatch
in line with the above changes
0.001002 Wed Aug 3 02:04:01 2022
* Rereleasing with ::X and ::Debug variations properly updated
0.001003 Mon Aug 8 04:27:57 2022
* Improved accuracy of variable-post-dereference detection
specifically: (?&PerlScalarAccessNoSpace) and (?&PerlArrayAccessNoSpace)
within interpolating quotelikes
(Thanks, Zaki!)
0.001004 Mon Aug 8 23:24:09 2022
* Fixed edge case of 'state' variable declarations
(Thanks, Zaki!)
0.001005 Tue Sep 6 22:54:34 2022
* Fixed erroneous non-interpolation of q'...'
(Thanks, Zaki!)
0.001006 Thu Sep 8 03:50:55 2022
* Worked around bugs in regex engine that made it impossible
to interpolate PPR grammars into other regexes in some cases.
Note that such interpolations still don't work under Perl 5.18
to 5.28, as the bug was only fixed in 5.30.
(Thanks, Zaki!)
0.001007 Fri Mar 3 09:44:34 2023
* Improved error handling via PPR::ERROR mechanism
(Thanks, Yves!)
0.001008 Tue Apr 11 15:49:58 2023
* Added support for Perl 5.38 features:
classes, methods, fields, optimistic regex evals, //= and ||= in signatures
0.001009 Wed Jun 26 14:33:28 2024
* Added explicit -- and extensible -- rule for (?&PerlComment)
* Some minor doc fixes
0.001010 Mon Oct 7 20:38:22 2024
* Clarified licensing of the module: "same terms as Perl itself".
(Thanks Gregor)
|