Merge branch 'master' into fix/eol
commit
c29bae2512
|
@ -11,6 +11,11 @@ use Sabre\Event\Promise;
|
||||||
*/
|
*/
|
||||||
class ClientCache implements Cache
|
class ClientCache implements Cache
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* @var LanguageClient
|
||||||
|
*/
|
||||||
|
public $client;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param LanguageClient $client
|
* @param LanguageClient $client
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -4,7 +4,7 @@ declare(strict_types = 1);
|
||||||
namespace LanguageServer\Client;
|
namespace LanguageServer\Client;
|
||||||
|
|
||||||
use LanguageServer\ClientHandler;
|
use LanguageServer\ClientHandler;
|
||||||
use LanguageServerProtocol\{TextDocumentItem, TextDocumentIdentifier};
|
use LanguageServerProtocol\{Diagnostic, TextDocumentItem, TextDocumentIdentifier};
|
||||||
use Sabre\Event\Promise;
|
use Sabre\Event\Promise;
|
||||||
use JsonMapper;
|
use JsonMapper;
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ declare(strict_types = 1);
|
||||||
namespace LanguageServer;
|
namespace LanguageServer;
|
||||||
|
|
||||||
use LanguageServer\Index\ReadableIndex;
|
use LanguageServer\Index\ReadableIndex;
|
||||||
use phpDocumentor\Reflection\{Types, Type, Fqsen, TypeResolver};
|
use phpDocumentor\Reflection\{Types, Type, TypeResolver};
|
||||||
use LanguageServerProtocol\SymbolInformation;
|
use LanguageServerProtocol\SymbolInformation;
|
||||||
use Generator;
|
use Generator;
|
||||||
|
|
||||||
|
@ -80,7 +80,7 @@ class Definition
|
||||||
* Can also be a compound type.
|
* Can also be a compound type.
|
||||||
* If it is unknown, will be Types\Mixed_.
|
* If it is unknown, will be Types\Mixed_.
|
||||||
*
|
*
|
||||||
* @var \phpDocumentor\Type|null
|
* @var Type|null
|
||||||
*/
|
*/
|
||||||
public $type;
|
public $type;
|
||||||
|
|
||||||
|
|
|
@ -274,7 +274,6 @@ class Index implements ReadableIndex, \Serializable
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param string $serialized
|
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function serialize()
|
public function serialize()
|
||||||
|
|
|
@ -167,7 +167,7 @@ class LanguageServer extends AdvancedJsonRpc\Dispatcher
|
||||||
*/
|
*/
|
||||||
public function initialize(ClientCapabilities $capabilities, string $rootPath = null, int $processId = null, string $rootUri = null): Promise
|
public function initialize(ClientCapabilities $capabilities, string $rootPath = null, int $processId = null, string $rootUri = null): Promise
|
||||||
{
|
{
|
||||||
if ($rootPath === null) {
|
if ($rootPath === null && $rootUri !== null) {
|
||||||
$rootPath = uriToPath($rootUri);
|
$rootPath = uriToPath($rootUri);
|
||||||
}
|
}
|
||||||
return coroutine(function () use ($capabilities, $rootPath, $processId) {
|
return coroutine(function () use ($capabilities, $rootPath, $processId) {
|
||||||
|
|
|
@ -63,7 +63,7 @@ class PhpDocument
|
||||||
/**
|
/**
|
||||||
* Map from fully qualified name (FQN) to Node
|
* Map from fully qualified name (FQN) to Node
|
||||||
*
|
*
|
||||||
* @var Node
|
* @var Node[]
|
||||||
*/
|
*/
|
||||||
private $definitionNodes;
|
private $definitionNodes;
|
||||||
|
|
||||||
|
|
|
@ -6,8 +6,7 @@ namespace LanguageServer;
|
||||||
use LanguageServer\Index\ReadableIndex;
|
use LanguageServer\Index\ReadableIndex;
|
||||||
use LanguageServerProtocol\{
|
use LanguageServerProtocol\{
|
||||||
Position,
|
Position,
|
||||||
SignatureHelp,
|
SignatureHelp
|
||||||
ParameterInformation
|
|
||||||
};
|
};
|
||||||
use Microsoft\PhpParser\Node;
|
use Microsoft\PhpParser\Node;
|
||||||
use Sabre\Event\Promise;
|
use Sabre\Event\Promise;
|
||||||
|
|
Loading…
Reference in New Issue