tstyche 7.0.0-rc.0 → 7.0.0-rc.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/README.md +2 -2
- package/dist/api.js +20 -15
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -105,7 +105,7 @@ Visit [tstyche.org](https://tstyche.org) to view the full documentation.
|
|
|
105
105
|
[license-url]: https://github.com/tstyche/tstyche/blob/main/LICENSE.md
|
|
106
106
|
[install-size-badge]: https://badgen.net/packagephobia/install/tstyche
|
|
107
107
|
[install-size-url]: https://packagephobia.com/result?p=tstyche
|
|
108
|
-
[coverage-badge]: https://badgen.net/
|
|
109
|
-
[coverage-url]: https://app.
|
|
108
|
+
[coverage-badge]: https://badgen.net/codecov/github/tstyche/tstyche
|
|
109
|
+
[coverage-url]: https://app.codecov.io/gh/tstyche/tstyche
|
|
110
110
|
[starter-badge]: https://developer.stackblitz.com/img/open_in_stackblitz.svg
|
|
111
111
|
[starter-url]: https://tstyche.org/new
|
package/dist/api.js
CHANGED
|
@@ -3962,8 +3962,10 @@ class CollectService {
|
|
|
3962
3962
|
}
|
|
3963
3963
|
const matcherNode = this.#getMatcherNode(matcherNameNode);
|
|
3964
3964
|
if (!matcherNode) {
|
|
3965
|
-
const text = "The matcher must be
|
|
3966
|
-
const origin = DiagnosticOrigin.
|
|
3965
|
+
const text = "The matcher must be completed with '()'.";
|
|
3966
|
+
const origin = new DiagnosticOrigin(matcherNameNode.name.getStart(), this.#compiler.isExpressionWithTypeArguments(matcherNameNode.parent)
|
|
3967
|
+
? matcherNameNode.parent.getEnd()
|
|
3968
|
+
: matcherNameNode.getEnd(), matcherNameNode.getSourceFile());
|
|
3967
3969
|
this.#onDiagnostics(Diagnostic.error(text, origin));
|
|
3968
3970
|
return;
|
|
3969
3971
|
}
|
|
@@ -5144,18 +5146,20 @@ class Structure {
|
|
|
5144
5146
|
if (aSignatures.length !== bSignatures.length) {
|
|
5145
5147
|
return false;
|
|
5146
5148
|
}
|
|
5147
|
-
|
|
5148
|
-
|
|
5149
|
-
|
|
5150
|
-
|
|
5151
|
-
|
|
5152
|
-
|
|
5153
|
-
|
|
5154
|
-
|
|
5155
|
-
|
|
5156
|
-
|
|
5157
|
-
|
|
5158
|
-
|
|
5149
|
+
return aSignatures.every((aSignature) => {
|
|
5150
|
+
return bSignatures.some((bSignature) => {
|
|
5151
|
+
if (aSignature.isReadonly !== bSignature.isReadonly) {
|
|
5152
|
+
return false;
|
|
5153
|
+
}
|
|
5154
|
+
if (!this.compare(aSignature.keyType, bSignature.keyType)) {
|
|
5155
|
+
return false;
|
|
5156
|
+
}
|
|
5157
|
+
if (!this.compare(aSignature.type, bSignature.type)) {
|
|
5158
|
+
return false;
|
|
5159
|
+
}
|
|
5160
|
+
return true;
|
|
5161
|
+
});
|
|
5162
|
+
});
|
|
5159
5163
|
}
|
|
5160
5164
|
compareTypeParameters(a, b) {
|
|
5161
5165
|
if (getTypeParameterModifiers(a, this.#compiler) !== getTypeParameterModifiers(b, this.#compiler)) {
|
|
@@ -5491,6 +5495,7 @@ class ToBeInstantiableWith extends AbilityMatcherBase {
|
|
|
5491
5495
|
explainNotText = ExpectDiagnosticText.isNotInstantiable;
|
|
5492
5496
|
match(matchWorker, sourceNode, targetNode, onDiagnostics) {
|
|
5493
5497
|
if (!(this.compiler.isIdentifier(sourceNode) ||
|
|
5498
|
+
this.compiler.isPropertyAccessExpression(sourceNode) ||
|
|
5494
5499
|
this.compiler.isTypeReferenceNode(sourceNode) ||
|
|
5495
5500
|
this.compiler.isExpressionWithTypeArguments(sourceNode))) {
|
|
5496
5501
|
let text;
|
|
@@ -6165,7 +6170,7 @@ class FileRunner {
|
|
|
6165
6170
|
class Runner {
|
|
6166
6171
|
#eventEmitter = new EventEmitter();
|
|
6167
6172
|
#resolvedConfig;
|
|
6168
|
-
static version = "7.0.0-rc.
|
|
6173
|
+
static version = "7.0.0-rc.1";
|
|
6169
6174
|
constructor(resolvedConfig) {
|
|
6170
6175
|
this.#resolvedConfig = resolvedConfig;
|
|
6171
6176
|
}
|