1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2025-01-24 21:48:20 +01:00
phorge-arcanist/src/lint/linter
epriestley c999f3e6b5 Fix XHPAST to detect use of undeclared variables in catch
Summary:
Currently, when code has a block like:

  } catch (Exception $ex) {

...we attempt to mark "$ex" as declared. However, we incorrectly mark every variable used anywhere in the block as declared. This means we'll never raise this warning in a `catch` block.

Instead //only// mark the caught exception as declared.

Test Plan: Added a failing unit test and made it pass.

Reviewers: joshuaspence, btrahan

Reviewed By: btrahan

Subscribers: lpriestley, epriestley

Differential Revision: https://secure.phabricator.com/D9239
2014-05-21 12:23:51 -07:00
..
__tests__ Fix XHPAST to detect use of undeclared variables in catch 2014-05-21 12:23:51 -07:00
spelling Minor formatting changes to ArcanistSpellingDefaultData. 2014-05-11 05:25:47 -07:00
xhpast Implement hook for checking switch lint 2013-02-05 11:46:59 -08:00
ArcanistBaseXHPASTLinter.php Made some additional methods of ArcanistLinter and ArcanistExternalLinter final 2014-05-12 09:49:45 -07:00
ArcanistChmodLinter.php Add an ArcanistChmodLinter. 2014-05-18 16:57:08 -07:00
ArcanistClosureLinter.php Add Closure linter to arcanist 2014-05-15 09:19:28 -07:00
ArcanistCoffeeLintLinter.php Update ArcanistCoffeeLintLinter to be compatible with CoffeeLint v1.4.0. 2014-05-18 06:07:35 -07:00
ArcanistConduitLinter.php Remove severity options from some linters. 2014-05-11 19:28:27 -07:00
ArcanistCppcheckLinter.php Fixed the error message when cppcheck isn't installed to not be completely wrong. 2014-05-12 12:58:03 -07:00
ArcanistCpplintLinter.php Warn when accessing deprecated lint config 2014-05-11 18:39:28 -07:00
ArcanistCSharpLinter.php Fix issue where message contained % but wasn't intended for use with parameters 2014-05-14 17:11:45 -07:00
ArcanistCSSLintLinter.php Warn when accessing deprecated lint config 2014-05-11 18:39:28 -07:00
ArcanistExternalLinter.php Set the working directory to the project root for external linter ExecFuture classes. 2014-05-16 21:48:12 -07:00
ArcanistFilenameLinter.php Provide more help text for arc linters 2014-05-11 16:16:45 -07:00
ArcanistFlake8Linter.php Relax the version regex for ArcanistFlake8Linter. 2014-05-17 18:18:03 -07:00
ArcanistFutureLinter.php Made some additional methods of ArcanistLinter and ArcanistExternalLinter final 2014-05-12 09:49:45 -07:00
ArcanistGeneratedLinter.php Remove severity options from some linters. 2014-05-11 19:28:27 -07:00
ArcanistJSHintLinter.php Fix the ArcanistJSHintLinter::getVersion function. 2014-05-17 18:17:47 -07:00
ArcanistJSONLintLinter.php Fix the ArcanistJSONLintLinter::getVersion function. 2014-05-17 18:36:25 -07:00
ArcanistLesscLinter.php Remove the getConfig and setConfig method. 2014-05-12 04:46:56 -07:00
ArcanistLinter.php Made some additional methods of ArcanistLinter and ArcanistExternalLinter final 2014-05-12 09:49:45 -07:00
ArcanistMergeConflictLinter.php Provide more help text for arc linters 2014-05-11 16:16:45 -07:00
ArcanistNoLintLinter.php Remove severity options from some linters. 2014-05-11 19:28:27 -07:00
ArcanistPEP8Linter.php Warn when accessing deprecated lint config 2014-05-11 18:39:28 -07:00
ArcanistPhpcsLinter.php Warn when accessing deprecated lint config 2014-05-11 18:39:28 -07:00
ArcanistPhutilLibraryLinter.php Fill out some more info functions for libphutil-specific linters 2014-05-12 05:06:04 -07:00
ArcanistPhutilXHPASTLinter.php Fill out some more info functions for libphutil-specific linters 2014-05-12 05:06:04 -07:00
ArcanistPuppetLintLinter.php Provide more help text for arc linters 2014-05-11 16:16:45 -07:00
ArcanistPyFlakesLinter.php Don't support severity customization in pyflakes 2014-05-20 12:44:55 -07:00
ArcanistPyLintLinter.php Updating the pylint linter to set the output fomat correctly depending on the version of pylint installed 2014-05-05 19:05:16 -07:00
ArcanistRubyLinter.php Warn when accessing deprecated lint config 2014-05-11 18:39:28 -07:00
ArcanistScalaSBTLinter.php Modernize ArcanistScalaSBTLinter. 2014-05-18 10:49:22 -07:00
ArcanistScriptAndRegexLinter.php Provide more help text for arc linters 2014-05-11 16:16:45 -07:00
ArcanistSpellingLinter.php Add 'arc linters' to list available linters and status 2014-05-11 13:42:56 -07:00
ArcanistTextLinter.php Provide arc linters --verbose to list all available options 2014-05-11 20:23:07 -07:00
ArcanistXHPASTLinter.php Fix XHPAST to detect use of undeclared variables in catch 2014-05-21 12:23:51 -07:00
ArcanistXMLLinter.php Made some additional methods of ArcanistLinter and ArcanistExternalLinter final 2014-05-12 09:49:45 -07:00
reporter.js Modernize ArcanistJSHintLinter. 2014-05-05 14:22:27 -07:00