From 9e5d3bbe25f3b4897feac82297dbaaf759382a92 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 30 Sep 2016 18:30:01 +0200 Subject: [PATCH] Remove Error::(get|set)RawLine() These have been superseded by Error::(get|set)StartLine(). --- lib/PhpParser/Error.php | 10 ---------- test/PhpParser/ErrorTest.php | 6 ------ 2 files changed, 16 deletions(-) diff --git a/lib/PhpParser/Error.php b/lib/PhpParser/Error.php index 1eac054..4caf582 100644 --- a/lib/PhpParser/Error.php +++ b/lib/PhpParser/Error.php @@ -153,14 +153,4 @@ class Error extends \RuntimeException $this->message .= ' on line ' . $this->getStartLine(); } } - - /** @deprecated Use getStartLine() instead */ - public function getRawLine() { - return $this->getStartLine(); - } - - /** @deprecated Use setStartLine() instead */ - public function setRawLine($line) { - $this->setStartLine($line); - } } diff --git a/test/PhpParser/ErrorTest.php b/test/PhpParser/ErrorTest.php index 021a7f8..59e880c 100644 --- a/test/PhpParser/ErrorTest.php +++ b/test/PhpParser/ErrorTest.php @@ -15,7 +15,6 @@ class ErrorTest extends \PHPUnit_Framework_TestCase $this->assertSame($attributes, $error->getAttributes()); $this->assertSame(10, $error->getStartLine()); $this->assertSame(11, $error->getEndLine()); - $this->assertSame(10, $error->getRawLine()); $this->assertSame('Some error on line 10', $error->getMessage()); return $error; @@ -31,10 +30,6 @@ class ErrorTest extends \PHPUnit_Framework_TestCase $error->setStartLine(15); $this->assertSame(15, $error->getStartLine()); $this->assertSame('Some other error on line 15', $error->getMessage()); - - $error->setRawLine(17); - $this->assertSame(17, $error->getRawLine()); - $this->assertSame('Some other error on line 17', $error->getMessage()); } public function testUnknownLine() { @@ -42,7 +37,6 @@ class ErrorTest extends \PHPUnit_Framework_TestCase $this->assertSame(-1, $error->getStartLine()); $this->assertSame(-1, $error->getEndLine()); - $this->assertSame(-1, $error->getRawLine()); $this->assertSame('Some error on unknown line', $error->getMessage()); }