File tree Expand file tree Collapse file tree 3 files changed +8
-8
lines changed
src/Standards/Generic/Tests/CodeAnalysis Expand file tree Collapse file tree 3 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ function_call();
1919
2020?>
2121<input name="<?php ; something_else (); ?> " />
22- <input name="<?php something_else (); ; ?> " />
22+ <input name="<?php something_else (); ; ; ?> " />
2323
2424/*
2525 * Test empty statement: no code between PHP open and close tag.
@@ -42,7 +42,7 @@ function_call();
4242-->
4343<?php ; ?>
4444
45- <input name="<?php ; ?> " /> <!-- Bad. -->
45+ <input name="<?php ;; ?> " /> <!-- Bad. -->
4646
4747<!-- Tests with short open echo tag. -->
4848<input name="<?= 'some text ' ?> " /> <!-- OK. -->
@@ -53,7 +53,7 @@ function_call();
5353// Guard against false positives for two consecutive semicolons in a for statement.
5454for ( $ i = 0 ; ; $ i ++ ) {}
5555
56- // Test for useless semicolons
56+ // Test for useless semicolons.
5757for ( $ i = 0 ; ; $ i ++ ) {};
5858
5959if (true ) {};
@@ -80,7 +80,7 @@ if ($foo) {
8080;
8181}
8282
83- // Do not remove semicolon after match
83+ // Do not remove semicolon after match.
8484$ c = match ($ a ) {
8585 1 => true ,
8686};
Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ function_call();
4848// Guard against false positives for two consecutive semicolons in a for statement.
4949for ( $i = 0; ; $i++ ) {}
5050
51- // Test for useless semicolons
51+ // Test for useless semicolons.
5252for ( $i = 0; ; $i++ ) {}
5353
5454if (true) {}
@@ -74,7 +74,7 @@ echo $a{0};
7474if ($foo) {
7575}
7676
77- // Do not remove semicolon after match
77+ // Do not remove semicolon after match.
7878$c = match ($a) {
7979 1 => true,
8080};
Original file line number Diff line number Diff line change @@ -76,11 +76,11 @@ public function getWarningList($testFile='')
7676 15 => 1 ,
7777 18 => 1 ,
7878 21 => 1 ,
79- 22 => 1 ,
79+ 22 => 2 ,
8080 31 => 1 ,
8181 33 => 1 ,
8282 43 => 1 ,
83- 45 => 1 ,
83+ 45 => 2 ,
8484 49 => 1 ,
8585 50 => 1 ,
8686 57 => 1 ,
You can’t perform that action at this time.
0 commit comments