From f51af8bc0d89e90363494c7e366e3a2debf50833 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Tue, 23 May 2017 18:27:11 -0700 Subject: [PATCH] Minor cleanup --- fixtures/global_symbols.php | 2 +- src/Protocol/SymbolInformation.php | 1 - src/Server/TextDocument.php | 3 +-- tests/Server/TextDocument/References/NamespacedTest.php | 1 - 4 files changed, 2 insertions(+), 5 deletions(-) diff --git a/fixtures/global_symbols.php b/fixtures/global_symbols.php index 098d187..ac93b68 100644 --- a/fixtures/global_symbols.php +++ b/fixtures/global_symbols.php @@ -55,7 +55,7 @@ class TestClass implements TestInterface * @param TestClass $testParameter Lorem sunt velit incididunt mollit * @return TestClass */ - public function testMethod($testParameter) : TestInterface + public function testMethod($testParameter): TestInterface { $this->testProperty = $testParameter; } diff --git a/src/Protocol/SymbolInformation.php b/src/Protocol/SymbolInformation.php index 5d1f361..ec8730c 100644 --- a/src/Protocol/SymbolInformation.php +++ b/src/Protocol/SymbolInformation.php @@ -54,7 +54,6 @@ class SymbolInformation } else if ($node instanceof Tolerant\Node\Statement\TraitDeclaration) { $symbol->kind = SymbolKind::CLASS_; } - // TODO 'define' else if (\LanguageServer\ParserHelpers::isConstDefineExpression($node)) { // constants with define() like // define('TEST_DEFINE_CONSTANT', false); diff --git a/src/Server/TextDocument.php b/src/Server/TextDocument.php index 97a1781..6dadf2f 100644 --- a/src/Server/TextDocument.php +++ b/src/Server/TextDocument.php @@ -209,7 +209,7 @@ class TextDocument } else { // Definition with a global FQN $fqn = DefinitionResolver::getDefinedFqn($node); - // var_dump($fqn); + // Wait until indexing finished if (!$this->index->isComplete()) { yield waitForEvent($this->index, 'complete'); @@ -228,7 +228,6 @@ class TextDocument $refs = $document->getReferenceNodesByFqn($fqn); if ($refs !== null) { foreach ($refs as $ref) { - // var_dump($ref->getNodeKindName()); $locations[] = Location::fromNode($ref); } } diff --git a/tests/Server/TextDocument/References/NamespacedTest.php b/tests/Server/TextDocument/References/NamespacedTest.php index 32b8c4b..1ee1ab4 100644 --- a/tests/Server/TextDocument/References/NamespacedTest.php +++ b/tests/Server/TextDocument/References/NamespacedTest.php @@ -28,7 +28,6 @@ class NamespacedTest extends GlobalTest new TextDocumentIdentifier($definition->uri), $definition->range->end )->wait(); - // var_dump($result); $this->assertEquals(parent::getReferenceLocations('TestNamespace'), $result); } }