Merge branch 'master' into autocomplet-speedup
commit
334683ae75
|
@ -1,9 +1,8 @@
|
|||
|
||||
language: php
|
||||
|
||||
php:
|
||||
- '7.0'
|
||||
- '7.2.0RC5'
|
||||
- '7.2'
|
||||
|
||||
git:
|
||||
depth: 10
|
||||
|
|
|
@ -51,11 +51,7 @@ foreach($frameworks as $framework) {
|
|||
$definitionResolver = new DefinitionResolver($index);
|
||||
$parser = new PhpParser\Parser();
|
||||
|
||||
try {
|
||||
$document = new PhpDocument($testCaseFile, $fileContents, $index, $parser, $docBlockFactory, $definitionResolver);
|
||||
} catch (\Throwable $e) {
|
||||
continue;
|
||||
}
|
||||
$document = new PhpDocument($testCaseFile, $fileContents, $index, $parser, $docBlockFactory, $definitionResolver);
|
||||
}
|
||||
|
||||
echo "------------------------------\n";
|
||||
|
|
|
@ -10,9 +10,6 @@ collectors:
|
|||
commit_message_prefix: "chore: "
|
||||
- type: js-npm
|
||||
path: /
|
||||
settings:
|
||||
dist_tags:
|
||||
semantic-release: next
|
||||
actors:
|
||||
- type: js-npm
|
||||
versions: "Y.0.0"
|
||||
|
|
|
@ -3,7 +3,6 @@ declare(strict_types = 1);
|
|||
|
||||
namespace LanguageServer\Cache;
|
||||
|
||||
use LanguageServer\LanguageClient;
|
||||
use Sabre\Event\Promise;
|
||||
|
||||
/**
|
||||
|
|
|
@ -4,7 +4,7 @@ declare(strict_types = 1);
|
|||
namespace LanguageServer\Client;
|
||||
|
||||
use LanguageServer\ClientHandler;
|
||||
use LanguageServer\Protocol\{Message, TextDocumentItem, TextDocumentIdentifier};
|
||||
use LanguageServer\Protocol\{TextDocumentItem, TextDocumentIdentifier};
|
||||
use Sabre\Event\Promise;
|
||||
use JsonMapper;
|
||||
|
||||
|
|
|
@ -4,7 +4,6 @@ declare(strict_types = 1);
|
|||
namespace LanguageServer\Client;
|
||||
|
||||
use LanguageServer\ClientHandler;
|
||||
use LanguageServer\Protocol\Message;
|
||||
use Sabre\Event\Promise;
|
||||
|
||||
/**
|
||||
|
|
|
@ -4,7 +4,6 @@ declare(strict_types = 1);
|
|||
namespace LanguageServer\Client;
|
||||
|
||||
use LanguageServer\ClientHandler;
|
||||
use LanguageServer\Protocol\Message;
|
||||
use Sabre\Event\Promise;
|
||||
|
||||
/**
|
||||
|
|
|
@ -6,7 +6,6 @@ namespace LanguageServer;
|
|||
use LanguageServer\Index\ReadableIndex;
|
||||
use phpDocumentor\Reflection\{Types, Type, Fqsen, TypeResolver};
|
||||
use LanguageServer\Protocol\SymbolInformation;
|
||||
use Exception;
|
||||
use Generator;
|
||||
|
||||
/**
|
||||
|
@ -69,7 +68,7 @@ class Definition
|
|||
public $canBeInstantiated;
|
||||
|
||||
/**
|
||||
* @var Protocol\SymbolInformation
|
||||
* @var SymbolInformation
|
||||
*/
|
||||
public $symbolInformation;
|
||||
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
namespace LanguageServer\FqnUtilities;
|
||||
|
||||
use phpDocumentor\Reflection\{Type, Types};
|
||||
use Microsoft\PhpParser;
|
||||
|
||||
/**
|
||||
* Returns all possible FQNs in a type
|
||||
|
|
|
@ -6,10 +6,8 @@ namespace LanguageServer;
|
|||
use LanguageServer\Cache\Cache;
|
||||
use LanguageServer\FilesFinder\FilesFinder;
|
||||
use LanguageServer\Index\{DependenciesIndex, Index};
|
||||
use LanguageServer\Protocol\Message;
|
||||
use LanguageServer\Protocol\MessageType;
|
||||
use Webmozart\PathUtil\Path;
|
||||
use Composer\Semver\VersionParser;
|
||||
use Sabre\Event\Promise;
|
||||
use function Sabre\Event\coroutine;
|
||||
|
||||
|
|
|
@ -160,7 +160,9 @@ class PhpDocument
|
|||
|
||||
// Register this document on the project for references
|
||||
foreach ($this->referenceNodes as $fqn => $nodes) {
|
||||
$this->index->addReferenceUri($fqn, $this->uri);
|
||||
// Cast the key to string. If (string)'2' is set as an array index, it will read out as (int)2. We must
|
||||
// deal with incorrect code, so this is a valid scenario.
|
||||
$this->index->addReferenceUri((string)$fqn, $this->uri);
|
||||
}
|
||||
|
||||
$this->sourceFileNode = $treeAnalyzer->getSourceFileNode();
|
||||
|
|
|
@ -4,7 +4,6 @@ namespace LanguageServer\Protocol;
|
|||
|
||||
use Microsoft\PhpParser;
|
||||
use Microsoft\PhpParser\Node;
|
||||
use Exception;
|
||||
|
||||
/**
|
||||
* Represents information about programming constructs like variables, classes,
|
||||
|
|
|
@ -8,7 +8,6 @@ use Sabre\Event\{
|
|||
Loop,
|
||||
Promise
|
||||
};
|
||||
use RuntimeException;
|
||||
|
||||
class ProtocolStreamWriter implements ProtocolWriter
|
||||
{
|
||||
|
|
|
@ -23,7 +23,6 @@ use LanguageServer\Protocol\{
|
|||
VersionedTextDocumentIdentifier,
|
||||
CompletionContext
|
||||
};
|
||||
use Microsoft\PhpParser;
|
||||
use Microsoft\PhpParser\Node;
|
||||
use Sabre\Event\Promise;
|
||||
use Sabre\Uri;
|
||||
|
|
|
@ -3,18 +3,16 @@ declare(strict_types = 1);
|
|||
|
||||
namespace LanguageServer\Server;
|
||||
|
||||
use LanguageServer\{LanguageClient, Project, PhpDocumentLoader};
|
||||
use LanguageServer\{LanguageClient, PhpDocumentLoader};
|
||||
use LanguageServer\Index\{ProjectIndex, DependenciesIndex, Index};
|
||||
use LanguageServer\Protocol\{
|
||||
FileChangeType,
|
||||
FileEvent,
|
||||
SymbolInformation,
|
||||
SymbolDescriptor,
|
||||
PackageDescriptor,
|
||||
ReferenceInformation,
|
||||
DependencyReference,
|
||||
Location,
|
||||
MessageType
|
||||
Location
|
||||
};
|
||||
use Sabre\Event\Promise;
|
||||
use function Sabre\Event\coroutine;
|
||||
|
|
|
@ -7,10 +7,8 @@ use LanguageServer\Index\ReadableIndex;
|
|||
use LanguageServer\Protocol\{
|
||||
Position,
|
||||
SignatureHelp,
|
||||
SignatureInformation,
|
||||
ParameterInformation
|
||||
};
|
||||
use Microsoft\PhpParser;
|
||||
use Microsoft\PhpParser\Node;
|
||||
use Sabre\Event\Promise;
|
||||
use function Sabre\Event\coroutine;
|
||||
|
|
|
@ -3,10 +3,8 @@ declare(strict_types = 1);
|
|||
|
||||
namespace LanguageServer;
|
||||
|
||||
use LanguageServer\Protocol\{Diagnostic, DiagnosticSeverity, Range, Position, TextEdit};
|
||||
use LanguageServer\Index\Index;
|
||||
use LanguageServer\Protocol\{Diagnostic, DiagnosticSeverity, Range, Position};
|
||||
use phpDocumentor\Reflection\DocBlockFactory;
|
||||
use Sabre\Uri;
|
||||
use Microsoft\PhpParser;
|
||||
use Microsoft\PhpParser\Node;
|
||||
use Microsoft\PhpParser\Token;
|
||||
|
|
Loading…
Reference in New Issue