1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2024-11-25 16:22:42 +01:00
phorge-arcanist/src/lint
epriestley 7efe723ff5 Detect iterator reuse in for() and foreach() loops
Summary:
cpojer fixed a JS instance of this in D481, but we can catch it in PHP with
XHPAST. Add a lint rule to fail if nested loops use the same iterator.

Test Plan:
Ran unit test.

Reviewed By: tomo
Reviewers: aran, pad, cpojer, jungejason, tuomaspelkonen, tomo
Commenters: cpojer
CC: aran, cpojer, epriestley, tomo
Differential Revision: 489
2011-06-23 13:15:57 -07:00
..
engine Recognize "@nolint" and "@generated" in C++ files in PhutilLintEngine 2011-06-14 20:44:40 -07:00
linter Detect iterator reuse in for() and foreach() loops 2011-06-23 13:15:57 -07:00
message Some documentation. 2011-02-19 11:36:08 -08:00
patcher Stop arc from destroying files under HPHPi. 2011-02-24 14:08:49 -08:00
renderer Improve lint rendering 2011-04-08 19:18:34 -07:00
result Some documentation. 2011-02-19 11:36:08 -08:00
severity Some documentation. 2011-02-19 11:36:08 -08:00