From a3e0c26ea8e3bf5b6db968e8a0fe1fe637e9bf6e Mon Sep 17 00:00:00 2001 From: vrana Date: Fri, 8 Feb 2013 14:30:25 -0800 Subject: [PATCH] Delete newLintAtLine() Summary: Nobody needs it because `raiseLintAtLine()` returns the message. Test Plan: $ arc unit Reviewers: epriestley Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D4870 --- src/lint/linter/ArcanistLinter.php | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/src/lint/linter/ArcanistLinter.php b/src/lint/linter/ArcanistLinter.php index ec7a7596..a96f8e67 100644 --- a/src/lint/linter/ArcanistLinter.php +++ b/src/lint/linter/ArcanistLinter.php @@ -151,17 +151,6 @@ abstract class ArcanistLinter { return $this->messages; } - protected function newLintAtLine($line, $char, $code, $desc) { - return id(new ArcanistLintMessage()) - ->setPath($this->getActivePath()) - ->setLine($line) - ->setChar($char) - ->setCode($this->getLintMessageFullCode($code)) - ->setSeverity($this->getLintMessageSeverity($code)) - ->setName($this->getLintMessageName($code)) - ->setDescription($desc); - } - protected function raiseLintAtLine( $line, $char, @@ -170,7 +159,14 @@ abstract class ArcanistLinter { $original = null, $replacement = null) { - $message = $this->newLintAtLine($line, $char, $code, $desc) + $message = id(new ArcanistLintMessage()) + ->setPath($this->getActivePath()) + ->setLine($line) + ->setChar($char) + ->setCode($this->getLintMessageFullCode($code)) + ->setSeverity($this->getLintMessageSeverity($code)) + ->setName($this->getLintMessageName($code)) + ->setDescription($desc) ->setOriginalText($original) ->setReplacementText($replacement);