1
0
Fork 0
pull/79/merge
Felix Becker 2016-10-18 09:38:31 +00:00 committed by GitHub
commit 2874bedde2
2 changed files with 7 additions and 4 deletions

View File

@ -10,10 +10,9 @@ class TestClass implements TestInterface
public static $staticTestProperty; public static $staticTestProperty;
public $testProperty; public $testProperty;
public static function staticTestMethod() public static function staticTestMethod() {}
{
} public function __construct() {}
public function testMethod($testParameter) public function testMethod($testParameter)
{ {

View File

@ -63,7 +63,11 @@ class SymbolInformation
throw new Exception("Not a declaration node: $class"); throw new Exception("Not a declaration node: $class");
} }
$symbol = new self; $symbol = new self;
if ($node instanceof Node\Stmt\ClassMethod && $node->name === '__construct') {
$symbol->kind = SymbolKind::CONSTRUCTOR;
} else {
$symbol->kind = $nodeSymbolKindMap[$class]; $symbol->kind = $nodeSymbolKindMap[$class];
}
$symbol->name = (string)$node->name; $symbol->name = (string)$node->name;
$symbol->location = Location::fromNode($node); $symbol->location = Location::fromNode($node);
if ($fqn !== null) { if ($fqn !== null) {