@mrclrchtr/supi-lsp 7.3.0 → 7.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/node_modules/@mrclrchtr/supi-code-runtime/package.json +1 -1
- package/node_modules/@mrclrchtr/supi-core/package.json +1 -1
- package/node_modules/ignore/index.js +25 -6
- package/node_modules/ignore/legacy.js +22 -6
- package/node_modules/ignore/package.json +1 -1
- package/node_modules/vscode-jsonrpc/lib/common/connection.js +2 -2
- package/node_modules/vscode-jsonrpc/lib/node/main.d.ts +1 -0
- package/node_modules/vscode-jsonrpc/lib/node/main.js +7 -0
- package/node_modules/vscode-jsonrpc/package.json +2 -2
- package/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.d.ts +2 -2
- package/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.d.ts +2 -2
- package/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.d.ts +2 -2
- package/node_modules/vscode-languageserver-protocol/package.json +4 -4
- package/node_modules/vscode-languageserver-types/package.json +2 -2
- package/package.json +3 -3
|
@@ -727,6 +727,20 @@ const WILDCARD = '[^\\/]*'
|
|
|
727
727
|
// The source is read one token at a time -- a wildcard, a single-character
|
|
728
728
|
// piece (a literal, an escape, a class), or a parenthesised group or anchor
|
|
729
729
|
// that ends the run -- so only a genuine wildcard is touched.
|
|
730
|
+
|
|
731
|
+
// The fixed pieces between the wildcard at `at` and the next wildcard of the
|
|
732
|
+
// run, joined as they appear in the source. A run never holds two wildcards
|
|
733
|
+
// in a row, so there is always at least one piece.
|
|
734
|
+
const separatorAfter = (run, at) => {
|
|
735
|
+
let separator = EMPTY
|
|
736
|
+
|
|
737
|
+
for (let index = at + 1; index < run.length && !run[index].wildcard; index ++) {
|
|
738
|
+
separator += run[index].single
|
|
739
|
+
}
|
|
740
|
+
|
|
741
|
+
return separator
|
|
742
|
+
}
|
|
743
|
+
|
|
730
744
|
const pinWildcards = source => {
|
|
731
745
|
if (source.indexOf(WILDCARD) < 0) {
|
|
732
746
|
return source
|
|
@@ -814,14 +828,19 @@ const pinWildcards = source => {
|
|
|
814
828
|
return
|
|
815
829
|
}
|
|
816
830
|
|
|
817
|
-
// A wildcard that is not the last in the run is
|
|
818
|
-
//
|
|
819
|
-
//
|
|
820
|
-
//
|
|
821
|
-
// the
|
|
831
|
+
// A wildcard that is not the last in the run is pinned to the whole
|
|
832
|
+
// fixed piece that separates it from the next wildcard, not just to
|
|
833
|
+
// that piece's first character: stopping at the first character alone
|
|
834
|
+
// would let the wildcard hand over at a place where the rest of the
|
|
835
|
+
// separator cannot follow, and the pin leaves no way back, so
|
|
836
|
+
// `f*o/*/*` would miss `foo/b/c` -- the first `o` of `foo` is not the
|
|
837
|
+
// one the `o/` after it needs. Every piece matches exactly one
|
|
838
|
+
// character, so pinning to the first place the whole separator fits
|
|
839
|
+
// is the leftmost place it can sit, and the wildcards that follow
|
|
840
|
+
// take up whatever is left.
|
|
822
841
|
out += at === lastWildcard
|
|
823
842
|
? WILDCARD
|
|
824
|
-
: `(?:(?!${run
|
|
843
|
+
: `(?:(?!${separatorAfter(run, at)})[^\\/])*`
|
|
825
844
|
})
|
|
826
845
|
|
|
827
846
|
run = []
|
|
@@ -632,6 +632,17 @@ var WILDCARD = '[^\\/]*';
|
|
|
632
632
|
// The source is read one token at a time -- a wildcard, a single-character
|
|
633
633
|
// piece (a literal, an escape, a class), or a parenthesised group or anchor
|
|
634
634
|
// that ends the run -- so only a genuine wildcard is touched.
|
|
635
|
+
|
|
636
|
+
// The fixed pieces between the wildcard at `at` and the next wildcard of the
|
|
637
|
+
// run, joined as they appear in the source. A run never holds two wildcards
|
|
638
|
+
// in a row, so there is always at least one piece.
|
|
639
|
+
var separatorAfter = function separatorAfter(run, at) {
|
|
640
|
+
var separator = EMPTY;
|
|
641
|
+
for (var index = at + 1; index < run.length && !run[index].wildcard; index++) {
|
|
642
|
+
separator += run[index].single;
|
|
643
|
+
}
|
|
644
|
+
return separator;
|
|
645
|
+
};
|
|
635
646
|
var pinWildcards = function pinWildcards(source) {
|
|
636
647
|
if (source.indexOf(WILDCARD) < 0) {
|
|
637
648
|
return source;
|
|
@@ -714,12 +725,17 @@ var pinWildcards = function pinWildcards(source) {
|
|
|
714
725
|
return;
|
|
715
726
|
}
|
|
716
727
|
|
|
717
|
-
// A wildcard that is not the last in the run is
|
|
718
|
-
//
|
|
719
|
-
//
|
|
720
|
-
//
|
|
721
|
-
// the
|
|
722
|
-
|
|
728
|
+
// A wildcard that is not the last in the run is pinned to the whole
|
|
729
|
+
// fixed piece that separates it from the next wildcard, not just to
|
|
730
|
+
// that piece's first character: stopping at the first character alone
|
|
731
|
+
// would let the wildcard hand over at a place where the rest of the
|
|
732
|
+
// separator cannot follow, and the pin leaves no way back, so
|
|
733
|
+
// `f*o/*/*` would miss `foo/b/c` -- the first `o` of `foo` is not the
|
|
734
|
+
// one the `o/` after it needs. Every piece matches exactly one
|
|
735
|
+
// character, so pinning to the first place the whole separator fits
|
|
736
|
+
// is the leftmost place it can sit, and the wildcards that follow
|
|
737
|
+
// take up whatever is left.
|
|
738
|
+
out += at === lastWildcard ? WILDCARD : "(?:(?!".concat(separatorAfter(run, at), ")[^\\/])*");
|
|
723
739
|
});
|
|
724
740
|
run = [];
|
|
725
741
|
};
|
|
@@ -781,7 +781,8 @@ function createMessageConnection(messageReader, messageWriter, _logger, options)
|
|
|
781
781
|
}
|
|
782
782
|
}
|
|
783
783
|
}
|
|
784
|
-
|
|
784
|
+
const error = message.error ? ` Request failed: ${message.error.message} (${message.error.code}).` : '';
|
|
785
|
+
tracer.log(`Sending response '${method} - (${message.id})'. Processing request took ${Date.now() - startTime}ms.${error}`, data);
|
|
785
786
|
}
|
|
786
787
|
else {
|
|
787
788
|
logLSPMessage('send-response', message);
|
|
@@ -1145,7 +1146,6 @@ function createMessageConnection(messageReader, messageWriter, _logger, options)
|
|
|
1145
1146
|
responsePromises.delete(id);
|
|
1146
1147
|
responsePromise.reject(new messages_1.ResponseError(messages_1.ErrorCodes.MessageWriteError, error.message ? error.message : 'Unknown reason'));
|
|
1147
1148
|
logger.error(`Sending request failed.`);
|
|
1148
|
-
throw error;
|
|
1149
1149
|
}
|
|
1150
1150
|
});
|
|
1151
1151
|
},
|
|
@@ -50,6 +50,7 @@ export interface PipeTransport {
|
|
|
50
50
|
export declare function createClientPipeTransport(pipeName: string, encoding?: RAL.MessageBufferEncoding): Promise<PipeTransport>;
|
|
51
51
|
export declare function createServerPipeTransport(pipeName: string, encoding?: RAL.MessageBufferEncoding): [MessageReader, MessageWriter];
|
|
52
52
|
export interface SocketTransport {
|
|
53
|
+
port(): number;
|
|
53
54
|
onConnected(): Promise<[MessageReader, MessageWriter]>;
|
|
54
55
|
}
|
|
55
56
|
export declare function createClientSocketTransport(port: number, encoding?: RAL.MessageBufferEncoding): Promise<SocketTransport>;
|
|
@@ -255,7 +255,14 @@ function createClientSocketTransport(port, encoding = 'utf-8') {
|
|
|
255
255
|
server.on('error', reject);
|
|
256
256
|
server.listen(port, '127.0.0.1', () => {
|
|
257
257
|
server.removeListener('error', reject);
|
|
258
|
+
const address = server.address();
|
|
259
|
+
if (address === null || typeof address === 'string') {
|
|
260
|
+
reject(new Error(`Unexpected server address: ${address}`));
|
|
261
|
+
return;
|
|
262
|
+
}
|
|
263
|
+
const boundPort = address.port;
|
|
258
264
|
resolve({
|
|
265
|
+
port: () => boundPort,
|
|
259
266
|
onConnected: () => { return connected; }
|
|
260
267
|
});
|
|
261
268
|
});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vscode-jsonrpc",
|
|
3
3
|
"description": "A json rpc implementation over streams",
|
|
4
|
-
"version": "9.0.
|
|
4
|
+
"version": "9.0.3",
|
|
5
5
|
"author": "Microsoft Corporation",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"msgpack-lite": "^0.1.26"
|
|
35
35
|
},
|
|
36
36
|
"scripts": {
|
|
37
|
-
"prepublishOnly": "
|
|
37
|
+
"prepublishOnly": "npm run all:publish",
|
|
38
38
|
"prepack": "npm run all:publish",
|
|
39
39
|
"preversion": "npm test",
|
|
40
40
|
"compile": "tsc -b ./tsconfig.json",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { RequestHandler, RequestHandler0 } from 'vscode-jsonrpc';
|
|
2
2
|
import { Range, TextDocumentIdentifier, InlayHint } from 'vscode-languageserver-types';
|
|
3
3
|
import { CM, MessageDirection, ProtocolRequestType, ProtocolRequestType0 } from './messages';
|
|
4
|
-
import { type StaticRegistrationOptions, type TextDocumentRegistrationOptions, type WorkDoneProgressOptions, type WorkDoneProgressParams } from './protocol';
|
|
4
|
+
import { type PartialResultParams, type StaticRegistrationOptions, type TextDocumentRegistrationOptions, type WorkDoneProgressOptions, type WorkDoneProgressParams } from './protocol';
|
|
5
5
|
/**
|
|
6
6
|
* @since 3.18.0
|
|
7
7
|
*/
|
|
@@ -67,7 +67,7 @@ export type InlayHintRegistrationOptions = InlayHintOptions & TextDocumentRegist
|
|
|
67
67
|
*
|
|
68
68
|
* @since 3.17.0
|
|
69
69
|
*/
|
|
70
|
-
export type InlayHintParams = WorkDoneProgressParams & {
|
|
70
|
+
export type InlayHintParams = WorkDoneProgressParams & PartialResultParams & {
|
|
71
71
|
/**
|
|
72
72
|
* The text document.
|
|
73
73
|
*/
|
package/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { InlineCompletionItem, InlineCompletionContext, InlineCompletionList } from 'vscode-languageserver-types';
|
|
2
2
|
import { RequestHandler } from 'vscode-jsonrpc';
|
|
3
3
|
import { CM, MessageDirection, ProtocolRequestType } from './messages';
|
|
4
|
-
import { type TextDocumentRegistrationOptions, type WorkDoneProgressOptions, type StaticRegistrationOptions, type WorkDoneProgressParams, type TextDocumentPositionParams } from './protocol';
|
|
4
|
+
import { type TextDocumentRegistrationOptions, type WorkDoneProgressOptions, type StaticRegistrationOptions, type WorkDoneProgressParams, type TextDocumentPositionParams, type PartialResultParams } from './protocol';
|
|
5
5
|
/**
|
|
6
6
|
* Client capabilities specific to inline completions.
|
|
7
7
|
*
|
|
@@ -30,7 +30,7 @@ export type InlineCompletionRegistrationOptions = InlineCompletionOptions & Text
|
|
|
30
30
|
*
|
|
31
31
|
* @since 3.18.0
|
|
32
32
|
*/
|
|
33
|
-
export type InlineCompletionParams = WorkDoneProgressParams & TextDocumentPositionParams & {
|
|
33
|
+
export type InlineCompletionParams = WorkDoneProgressParams & TextDocumentPositionParams & PartialResultParams & {
|
|
34
34
|
/**
|
|
35
35
|
* Additional information about the context in which inline completions were
|
|
36
36
|
* requested.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { TextDocumentIdentifier, Range, InlineValue, InlineValueContext } from 'vscode-languageserver-types';
|
|
2
2
|
import { RequestHandler, RequestHandler0 } from 'vscode-jsonrpc';
|
|
3
3
|
import { CM, MessageDirection, ProtocolRequestType, ProtocolRequestType0 } from './messages';
|
|
4
|
-
import { type TextDocumentRegistrationOptions, type WorkDoneProgressOptions, type StaticRegistrationOptions, type WorkDoneProgressParams } from './protocol';
|
|
4
|
+
import { type TextDocumentRegistrationOptions, type WorkDoneProgressOptions, type StaticRegistrationOptions, type WorkDoneProgressParams, type PartialResultParams } from './protocol';
|
|
5
5
|
/**
|
|
6
6
|
* Client capabilities specific to inline values.
|
|
7
7
|
*
|
|
@@ -47,7 +47,7 @@ export type InlineValueRegistrationOptions = InlineValueOptions & TextDocumentRe
|
|
|
47
47
|
*
|
|
48
48
|
* @since 3.17.0
|
|
49
49
|
*/
|
|
50
|
-
export type InlineValueParams = WorkDoneProgressParams & {
|
|
50
|
+
export type InlineValueParams = WorkDoneProgressParams & PartialResultParams & {
|
|
51
51
|
/**
|
|
52
52
|
* The text document.
|
|
53
53
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vscode-languageserver-protocol",
|
|
3
3
|
"description": "VSCode Language Server Protocol implementation",
|
|
4
|
-
"version": "3.18.
|
|
4
|
+
"version": "3.18.4",
|
|
5
5
|
"author": "Microsoft Corporation",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -27,11 +27,11 @@
|
|
|
27
27
|
}
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"vscode-jsonrpc": "9.0.
|
|
31
|
-
"vscode-languageserver-types": "3.18.
|
|
30
|
+
"vscode-jsonrpc": "9.0.3",
|
|
31
|
+
"vscode-languageserver-types": "3.18.4"
|
|
32
32
|
},
|
|
33
33
|
"scripts": {
|
|
34
|
-
"prepublishOnly": "
|
|
34
|
+
"prepublishOnly": "npm run all:publish",
|
|
35
35
|
"prepack": "npm run all:publish",
|
|
36
36
|
"postpublish": "node ../build/npm/post-publish.js",
|
|
37
37
|
"preversion": "npm test",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vscode-languageserver-types",
|
|
3
3
|
"description": "Types used by the Language server for node",
|
|
4
|
-
"version": "3.18.
|
|
4
|
+
"version": "3.18.4",
|
|
5
5
|
"author": "Microsoft Corporation",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
}
|
|
24
24
|
},
|
|
25
25
|
"scripts": {
|
|
26
|
-
"prepublishOnly": "
|
|
26
|
+
"prepublishOnly": "npm run all:publish",
|
|
27
27
|
"prepack": "npm run all:publish",
|
|
28
28
|
"compile": "tsc -b ./tsconfig.json",
|
|
29
29
|
"clean": "rimraf lib",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mrclrchtr/supi-lsp",
|
|
3
|
-
"version": "7.3.
|
|
3
|
+
"version": "7.3.1",
|
|
4
4
|
"description": "Language Server Protocol runtime for SuPi code intelligence",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -37,8 +37,8 @@
|
|
|
37
37
|
"vscode-jsonrpc": "^9.0.0",
|
|
38
38
|
"vscode-languageserver-protocol": "^3.18.0",
|
|
39
39
|
"vscode-languageserver-types": "^3.18.0",
|
|
40
|
-
"@mrclrchtr/supi-
|
|
41
|
-
"@mrclrchtr/supi-
|
|
40
|
+
"@mrclrchtr/supi-core": "7.3.1",
|
|
41
|
+
"@mrclrchtr/supi-code-runtime": "7.3.1"
|
|
42
42
|
},
|
|
43
43
|
"bundledDependencies": [
|
|
44
44
|
"@mrclrchtr/supi-code-runtime",
|