Commit 0778eb7
committed
Improve perl style in ecpg's parser-construction scripts.
parse.pl and check_rules.pl used "no warnings 'uninitialized'",
which doesn't seem like it measures up to current project standards.
Removing that shows that it was hiding various places that accessed
off the end of an array, which are easily protected by minor logic
adjustments. There's no change in the script results.
While here, improve the Makefile rule that invokes these scripts.
It neglected to depend on check_rules.pl, so that editing that file
didn't result in re-running the check; and it ran check_rules.pl
after building preproc.y, so that if check_rules.pl did fail the
next "make" attempt would just bypass it. check_rules.pl failures
are sufficiently un-heard-of that I don't feel a need to back-patch
this.
Discussion: https://postgr.es/m/838180.1658181982@sss.pgh.pa.us1 parent d268d0f commit 0778eb7
File tree
3 files changed
+25
-11
lines changed- src/interfaces/ecpg/preproc
3 files changed
+25
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
68 | | - | |
| 67 | + | |
69 | 68 | | |
| 69 | + | |
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
| |||
142 | 141 | | |
143 | 142 | | |
144 | 143 | | |
145 | | - | |
| 144 | + | |
| 145 | + | |
146 | 146 | | |
147 | 147 | | |
148 | 148 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
18 | 17 | | |
19 | 18 | | |
20 | 19 | | |
| |||
40 | 39 | | |
41 | 40 | | |
42 | 41 | | |
43 | | - | |
| 42 | + | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| |||
195 | 195 | | |
196 | 196 | | |
197 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
198 | 208 | | |
199 | 209 | | |
200 | 210 | | |
| |||
341 | 351 | | |
342 | 352 | | |
343 | 353 | | |
344 | | - | |
| 354 | + | |
| 355 | + | |
345 | 356 | | |
346 | 357 | | |
347 | 358 | | |
| |||
409 | 420 | | |
410 | 421 | | |
411 | 422 | | |
| 423 | + | |
412 | 424 | | |
413 | 425 | | |
414 | 426 | | |
415 | 427 | | |
416 | | - | |
| 428 | + | |
| 429 | + | |
417 | 430 | | |
418 | 431 | | |
419 | 432 | | |
| |||
472 | 485 | | |
473 | 486 | | |
474 | 487 | | |
475 | | - | |
| 488 | + | |
| 489 | + | |
476 | 490 | | |
477 | 491 | | |
478 | 492 | | |
479 | | - | |
| 493 | + | |
480 | 494 | | |
481 | 495 | | |
482 | 496 | | |
| |||
487 | 501 | | |
488 | 502 | | |
489 | 503 | | |
490 | | - | |
| 504 | + | |
491 | 505 | | |
492 | 506 | | |
493 | 507 | | |
| |||
0 commit comments