@artel/artc 0.6.25229 → 0.6.25230
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/build/Cli.js +3 -3
- package/build/api/Api.js +2 -4
- package/build/api/ApiNodeJS.js +3 -3
- package/build/api/ApiServices.js +39 -39
- package/build/{chunk-4UBNOTKC.js → chunk-3LHZOXTJ.js} +2 -2
- package/build/{chunk-2FHW6RUS.js → chunk-WS3ILL2L.js} +1 -1
- package/build/{chunk-6YPLDA76.js → chunk-ZUIGWNN5.js} +713 -564
- package/build/types/analysis/Analyzer.d.ts +47 -8
- package/build/types/analysis/BaseExpressionMeaning.d.ts +1 -1
- package/build/types/analysis/DiagnosticCollector.d.ts +0 -1
- package/build/types/analysis/{OperationOverloadResolver.d.ts → FunctionOverloadResolver.d.ts} +2 -0
- package/build/types/analysis/IdentifierExpressionMeaning.d.ts +2 -2
- package/build/types/analysis/MemberAccessExpressionMeaning.d.ts +4 -4
- package/build/types/analysis/ModifierFlags.d.ts +1 -1
- package/build/types/analysis/PackageMemberNameConflictsValidator.d.ts +2 -3
- package/build/types/analysis/control-flow/NarrowableReference.d.ts +4 -4
- package/build/types/analysis/control-flow/Nodes.d.ts +1 -1
- package/build/types/analysis/semantic-context/Declarations.d.ts +2 -2
- package/build/types/analysis/semantic-context/SemanticContextValidatingNameConflicts.d.ts +0 -1
- package/build/types/emitter/Entities.d.ts +3 -3
- package/build/types/entities/AliasTypeEntity.d.ts +1 -1
- package/build/types/entities/ConstructorEntity.d.ts +8 -8
- package/build/types/entities/DereferenceOperatorEntity.d.ts +7 -7
- package/build/types/entities/DestructorEntity.d.ts +3 -3
- package/build/types/entities/FunctionEntity.d.ts +14 -14
- package/build/types/entities/FunctionTypeEntity.d.ts +1 -1
- package/build/types/entities/GetterEntity.d.ts +4 -4
- package/build/types/entities/IndexerEntity.d.ts +8 -8
- package/build/types/entities/OperatorEntity.d.ts +7 -7
- package/build/types/entities/SetterEntity.d.ts +4 -4
- package/build/types/entities/StructuredTypeEntity.d.ts +1 -1
- package/build/types/entities/TypeExtensionEntity.d.ts +1 -1
- package/build/types/entities/VariableEntity.d.ts +28 -28
- package/build/types/entities/VariantTypeEntity.d.ts +1 -1
- package/build/types/entities/index.d.ts +28 -0
- package/build/types/services/DisplayService.d.ts +2 -2
- package/build/types/services/NodeSemanticInfo.d.ts +3 -3
- package/build/types/tree/KeywordKind.d.ts +1 -1
- package/build/types/tree/green/Nodes.d.ts +1 -1
- package/build/types/tree/red/Nodes.d.ts +1 -1
- package/build/types/ts-interop/Entities.d.ts +24 -24
- package/build/types/ts-interop/TsTypeMembersCreator.d.ts +1 -1
- package/build/types/types/TypeMembers.d.ts +5 -5
- package/package.json +4 -4
@@ -617,7 +617,7 @@ var UniqueWithComparatorQuery = class extends Query {
|
|
617
617
|
};
|
618
618
|
|
619
619
|
// source/common/Constants.ts
|
620
|
-
var ArtelVersion = true ? "0.6.
|
620
|
+
var ArtelVersion = true ? "0.6.25230" : "";
|
621
621
|
var ArtelSourceFileExtensions = [".\u0430\u0440\u0442", ".\u0430\u0440\u0442\u0435\u043B\u044C", ".art", ".artel"];
|
622
622
|
var ArtelSourceFileExtensionSet = new Set(ArtelSourceFileExtensions);
|
623
623
|
var ArtelSourceAndConfigurationFileExtensionSet = new Set(ArtelSourceFileExtensionSet).add(".json");
|
@@ -1214,7 +1214,7 @@ var KeywordKind = /* @__PURE__ */ ((KeywordKind5) => {
|
|
1214
1214
|
KeywordKind5[KeywordKind5["Const"] = 36] = "Const";
|
1215
1215
|
KeywordKind5[KeywordKind5["Hidden"] = 37] = "Hidden";
|
1216
1216
|
KeywordKind5[KeywordKind5["Abstract"] = 38] = "Abstract";
|
1217
|
-
KeywordKind5[KeywordKind5["
|
1217
|
+
KeywordKind5[KeywordKind5["Override"] = 39] = "Override";
|
1218
1218
|
KeywordKind5[KeywordKind5["Async"] = 40] = "Async";
|
1219
1219
|
KeywordKind5[KeywordKind5["Static"] = 41] = "Static";
|
1220
1220
|
KeywordKind5[KeywordKind5["As"] = 42] = "As";
|
@@ -2058,8 +2058,7 @@ var englishKeywords = new Lazy(() => [
|
|
2058
2058
|
{ keyword: "in hierarchy", kind: 48 /* InHierarchy */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2059
2059
|
{ keyword: "in file", kind: 49 /* InFile */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2060
2060
|
{ keyword: "in package", kind: 50 /* InPackage */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2061
|
-
{ keyword: "override", kind: 39 /*
|
2062
|
-
{ keyword: "redefined", kind: 39 /* Redefined */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2061
|
+
{ keyword: "override", kind: 39 /* Override */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2063
2062
|
{ keyword: "static", kind: 41 /* Static */, dialects: [1 /* Usual */, 2 /* Special */] }
|
2064
2063
|
]);
|
2065
2064
|
var russianKeywords = new Lazy(() => [
|
@@ -2135,15 +2134,11 @@ var russianKeywords = new Lazy(() => [
|
|
2135
2134
|
{ keyword: "\u0432\u0441\u0435\u043E\u0431\u0449\u0435\u0435", kind: 41 /* Static */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2136
2135
|
{ keyword: "\u0432\u0441\u0435\u043E\u0431\u0449\u0438\u0439", kind: 41 /* Static */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2137
2136
|
{ keyword: "\u0432\u0441\u0435\u043E\u0431\u0449\u0438\u0435", kind: 41 /* Static */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2138
|
-
{ keyword: "\u0437\u0430\u043C
|
2139
|
-
{ keyword: "\
|
2140
|
-
{ keyword: "\
|
2141
|
-
{ keyword: "\
|
2142
|
-
{ keyword: "\
|
2143
|
-
{ keyword: "\u0438\u0441\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u043D\u0430\u044F", kind: 39 /* Redefined */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2144
|
-
{ keyword: "\u0438\u0441\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u043D\u043E\u0435", kind: 39 /* Redefined */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2145
|
-
{ keyword: "\u0438\u0441\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u043D\u044B\u0439", kind: 39 /* Redefined */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2146
|
-
{ keyword: "\u0438\u0441\u043F\u0440\u0430\u0432\u043B\u0435\u043D\u043D\u044B\u0435", kind: 39 /* Redefined */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2137
|
+
{ keyword: "\u0437\u0430\u043C", kind: 39 /* Override */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2138
|
+
{ keyword: "\u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043D\u043D\u0430\u044F", kind: 39 /* Override */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2139
|
+
{ keyword: "\u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043D\u043D\u043E\u0435", kind: 39 /* Override */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2140
|
+
{ keyword: "\u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043D\u043D\u044B\u0439", kind: 39 /* Override */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2141
|
+
{ keyword: "\u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043D\u043D\u044B\u0435", kind: 39 /* Override */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2147
2142
|
{ keyword: "\u0441\u043A\u0440\u044B\u0442\u043E", kind: 37 /* Hidden */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2148
2143
|
{ keyword: "\u0441\u043A\u0440\u044B\u0442\u044B\u0439", kind: 37 /* Hidden */, dialects: [1 /* Usual */, 2 /* Special */] },
|
2149
2144
|
{ keyword: "\u0441\u043A\u0440\u044B\u0442\u043E\u0435", kind: 37 /* Hidden */, dialects: [1 /* Usual */, 2 /* Special */] },
|
@@ -13021,7 +13016,7 @@ var russianErrorMessages = {
|
|
13021
13016
|
[210 /* IndexerNotFound */]: "\u0418\u043D\u0434\u0435\u043A\u0441\u0430\u0442\u043E\u0440 \u043D\u0435 \u043D\u0430\u0439\u0434\u0435\u043D.",
|
13022
13017
|
[244 /* BaseCannotBeUsedInThisContext */]: "'\u043E\u0441\u043D\u043E\u0432\u0430' \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u044C\u0441\u044F \u0432 \u044D\u0442\u043E\u043C \u043A\u043E\u043D\u0442\u0435\u043A\u0441\u0442\u0435.",
|
13023
13018
|
[247 /* BaseCannotBeUsedAsAnExpressionInItself */]: "'\u043E\u0441\u043D\u043E\u0432\u0430' \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u044C\u0441\u044F \u0432 \u043A\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u0430\u043C\u043E\u0441\u0442\u043E\u044F\u0442\u0435\u043B\u044C\u043D\u043E\u0433\u043E \u0432\u044B\u0440\u0430\u0436\u0435\u043D\u0438\u044F.",
|
13024
|
-
[245 /* OverriddenMethodNotFound */]: "\
|
13019
|
+
[245 /* OverriddenMethodNotFound */]: "\u0420\u0430\u0441\u0448\u0438\u0440\u0435\u043D\u043D\u044B\u0439 \u043C\u0435\u0442\u043E\u0434 \u043D\u0435 \u043D\u0430\u0439\u0434\u0435\u043D.",
|
13025
13020
|
[246 /* ObjectCannotBeUsedInThisContext */]: "'\u043E\u0431\u044A\u0435\u043A\u0442' \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u043E\u0432\u0430\u0442\u044C\u0441\u044F \u0432 \u044D\u0442\u043E\u043C \u043A\u043E\u043D\u0442\u0435\u043A\u0441\u0442\u0435.",
|
13026
13021
|
[248 /* InterfacePackageMustNotContainImplementation */]: "\u0418\u043D\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043D\u044B\u0439 \u043F\u0430\u043A\u0435\u0442 \u043D\u0435 \u0434\u043E\u043B\u0436\u0435\u043D \u0441\u043E\u0434\u0435\u0440\u0436\u0430\u0442\u044C \u0440\u0435\u0430\u043B\u0438\u0437\u0430\u0446\u0438\u044E.",
|
13027
13022
|
[249 /* InterfacePackageVariablesMustNotHaveInitializers */]: "\u041F\u0435\u0440\u0435\u043C\u0435\u043D\u043D\u044B\u0435 \u0432 \u0438\u043D\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043D\u043E\u043C \u043F\u0430\u043A\u0435\u0442\u0435 \u043D\u0435 \u0434\u043E\u043B\u0436\u043D\u044B \u0438\u043C\u0435\u0442\u044C \u043D\u0430\u0447\u0430\u043B\u044C\u043D\u044B\u0435 \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u044F.",
|
@@ -13051,7 +13046,7 @@ var russianErrorMessages = {
|
|
13051
13046
|
[273 /* FunctionIsDeclaredButNotUsed */]: "\u0424\u0443\u043D\u043A\u0446\u0438\u044F \u043E\u0431\u044A\u044F\u0432\u043B\u0435\u043D\u0430, \u043D\u043E \u043D\u0435 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u0435\u0442\u0441\u044F.",
|
13052
13047
|
[274 /* TypeParameterIsDeclaredButNotUsed */]: "\u041F\u0430\u0440\u0430\u043C\u0435\u0442\u0440 \u0442\u0438\u043F\u0430 \u043E\u0431\u044A\u044F\u0432\u043B\u0435\u043D, \u043D\u043E \u043D\u0435 \u0438\u0441\u043F\u043E\u043B\u044C\u0437\u0443\u0435\u0442\u0441\u044F.",
|
13053
13048
|
[275 /* DefaultConstructorArgumentsMustBeNamed */]: "\u0410\u0440\u0433\u0443\u043C\u0435\u043D\u0442\u044B \u043A\u043E\u043D\u0441\u0442\u0440\u0443\u043A\u0442\u043E\u0440\u0430 \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E \u0434\u043E\u043B\u0436\u043D\u044B \u043F\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044C\u0441\u044F \u0441 \u0443\u043A\u0430\u0437\u0430\u043D\u0438\u0435\u043C \u0438\u043C\u0435\u043D\u0438 \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044E\u0449\u0435\u0433\u043E \u043F\u0430\u0440\u0430\u043C\u0435\u0442\u0440\u0430.",
|
13054
|
-
[276 /* IncorrectBodyOfBasicAliasTypeMethod */]: "\u0422\u0435\u043B\u043E \
|
13049
|
+
[276 /* IncorrectBodyOfBasicAliasTypeMethod */]: "\u0422\u0435\u043B\u043E \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043D\u043D\u043E\u0433\u043E \u043C\u0435\u0442\u043E\u0434\u0430, \u043E\u0431\u044A\u044F\u0432\u043B\u0435\u043D\u043D\u043E\u0433\u043E \u0432 \u0442\u043E\u0436\u0434\u0435\u0441\u0442\u0432\u0435\u043D\u043D\u043E\u043C \u0442\u0438\u043F\u0435, \u0434\u043E\u043B\u0436\u043D\u043E \u0441\u043E\u0441\u0442\u043E\u044F\u0442\u044C \u0438\u0437 \u0432\u044B\u0437\u043E\u0432\u0430 \u0431\u0430\u0437\u043E\u0432\u043E\u0433\u043E \u043C\u0435\u0442\u043E\u0434\u0430 \u043E\u0440\u0438\u0433\u0438\u043D\u0430\u043B\u044C\u043D\u043E\u0433\u043E \u0442\u0438\u043F\u0430 \u0441 \u0442\u0430\u043A\u0438\u043C\u0438 \u0436\u0435 \u043F\u0430\u0440\u0430\u043C\u0435\u0442\u0440\u0430\u043C\u0438 \u0438 \u0432\u043E\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043C\u044B\u043C \u0437\u043D\u0430\u0447\u0435\u043D\u0438\u0435\u043C.",
|
13055
13050
|
[277 /* TheFollowingDeclarationsAreNotTranslated0 */]: "\u0421\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0435 \u043E\u0431\u044A\u044F\u0432\u043B\u0435\u043D\u0438\u044F \u043D\u0435 \u043F\u0435\u0440\u0435\u0432\u0435\u0434\u0435\u043D\u044B: {0}.",
|
13056
13051
|
[278 /* TheFollowingDeclarationAreNotTranslated0And1More */]: "\u0421\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0435 \u043E\u0431\u044A\u044F\u0432\u043B\u0435\u043D\u0438\u044F \u043D\u0435 \u043F\u0435\u0440\u0435\u0432\u0435\u0434\u0435\u043D\u044B: {0} \u0438 \u0435\u0449\u0451 {1}.",
|
13057
13052
|
[279 /* OperatorFunctionMustNotBeStatic */]: "\u0424\u0443\u043D\u043A\u0446\u0438\u044F \u043E\u043F\u0435\u0440\u0430\u0446\u0438\u0438 \u043D\u0435 \u0434\u043E\u043B\u0436\u043D\u0430 \u0431\u044B\u0442\u044C \u0432\u0441\u0435\u043E\u0431\u0449\u0435\u0439.",
|
@@ -13060,7 +13055,7 @@ var russianErrorMessages = {
|
|
13060
13055
|
[282 /* OperatorFunction0MustHaveNoMoreThanOneParameter */]: "\u0424\u0443\u043D\u043A\u0446\u0438\u044F \u043E\u043F\u0435\u0440\u0430\u0446\u0438\u0438 '{0}' \u0434\u043E\u043B\u0436\u043D\u0430 \u0438\u043C\u0435\u0442\u044C \u043D\u0435 \u0431\u043E\u043B\u0435\u0435 \u043E\u0434\u043D\u043E\u0433\u043E \u043F\u0430\u0440\u0430\u043C\u0435\u0442\u0440\u0430.",
|
13061
13056
|
[283 /* CorrespondingBasicTypeMemberNotFound */]: "\u041D\u0435 \u043D\u0430\u0439\u0434\u0435\u043D \u0441\u043E\u043E\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044E\u0449\u0438\u0439 \u0431\u0430\u0437\u043E\u0432\u044B\u0439 \u0447\u043B\u0435\u043D \u0442\u0438\u043F\u0430.",
|
13062
13057
|
[284 /* ConstructorCannotBeDeclaredAsBasic */]: "\u041A\u043E\u043D\u0441\u0442\u0440\u0443\u043A\u0442\u043E\u0440 \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u0431\u044B\u0442\u044C \u043E\u0431\u044A\u044F\u0432\u043B\u0435\u043D \u043A\u0430\u043A \u0431\u0430\u0437\u043E\u0432\u044B\u0439.",
|
13063
|
-
[285 /* ConstructorCannotBeDeclaredAsOverridden */]: "\u041A\u043E\u043D\u0441\u0442\u0440\u0443\u043A\u0442\u043E\u0440 \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u0431\u044B\u0442\u044C \u043E\u0431\u044A\u044F\u0432\u043B\u0435\u043D \u043A\u0430\u043A \
|
13058
|
+
[285 /* ConstructorCannotBeDeclaredAsOverridden */]: "\u041A\u043E\u043D\u0441\u0442\u0440\u0443\u043A\u0442\u043E\u0440 \u043D\u0435 \u043C\u043E\u0436\u0435\u0442 \u0431\u044B\u0442\u044C \u043E\u0431\u044A\u044F\u0432\u043B\u0435\u043D \u043A\u0430\u043A \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043D\u043D\u044B\u0439.",
|
13064
13059
|
[286 /* AsyncFunctionCanOnlyBeCalledFromFunctionMarkedWithAsyncModifier */]: "\u0410\u0441\u0438\u043D\u0445\u0440\u043E\u043D\u043D\u0430\u044F \u0444\u0443\u043D\u043A\u0446\u0438\u044F \u043C\u043E\u0436\u0435\u0442 \u0431\u044B\u0442\u044C \u0432\u044B\u0437\u0432\u0430\u043D\u0430 \u0442\u043E\u043B\u044C\u043A\u043E \u0438\u0437 \u0444\u0443\u043D\u043A\u0446\u0438\u0438, \u043F\u043E\u043C\u0435\u0447\u0435\u043D\u043D\u043E\u0439 \u043C\u043E\u0434\u0438\u0444\u0438\u043A\u0430\u0442\u043E\u0440\u043E\u043C '\u0430\u0441\u0438\u043D\u0445\u0440\u043E\u043D\u043D\u043E'.",
|
13065
13060
|
[130 /* TagNameExpected */]: "\u041E\u0436\u0438\u0434\u0430\u043B\u043E\u0441\u044C \u0438\u043C\u044F \u0442\u0435\u0433\u0430",
|
13066
13061
|
[287 /* TagNotFound */]: "\u0422\u0435\u0433 \u043D\u0435 \u043D\u0430\u0439\u0434\u0435\u043D.",
|
@@ -16502,13 +16497,13 @@ var FunctionTypeBodyDisplayParts = class {
|
|
16502
16497
|
};
|
16503
16498
|
|
16504
16499
|
// source/entities/TypeEntity.ts
|
16505
|
-
var TypeEntityKind = /* @__PURE__ */ ((
|
16506
|
-
|
16507
|
-
|
16508
|
-
|
16509
|
-
|
16510
|
-
|
16511
|
-
return
|
16500
|
+
var TypeEntityKind = /* @__PURE__ */ ((TypeEntityKind4) => {
|
16501
|
+
TypeEntityKind4[TypeEntityKind4["Function"] = 0] = "Function";
|
16502
|
+
TypeEntityKind4[TypeEntityKind4["Structured"] = 1] = "Structured";
|
16503
|
+
TypeEntityKind4[TypeEntityKind4["Parameter"] = 2] = "Parameter";
|
16504
|
+
TypeEntityKind4[TypeEntityKind4["Variant"] = 3] = "Variant";
|
16505
|
+
TypeEntityKind4[TypeEntityKind4["Alias"] = 4] = "Alias";
|
16506
|
+
return TypeEntityKind4;
|
16512
16507
|
})(TypeEntityKind || {});
|
16513
16508
|
|
16514
16509
|
// source/entities/PackageMembers.ts
|
@@ -21093,7 +21088,7 @@ var ModifierParser = class {
|
|
21093
21088
|
case 17 /* Basic */:
|
21094
21089
|
case 38 /* Abstract */:
|
21095
21090
|
case 41 /* Static */:
|
21096
|
-
case 39 /*
|
21091
|
+
case 39 /* Override */:
|
21097
21092
|
case 40 /* Async */:
|
21098
21093
|
return true;
|
21099
21094
|
default:
|
@@ -23120,6 +23115,7 @@ __export(types_exports, {
|
|
23120
23115
|
Constructor: () => Constructor,
|
23121
23116
|
DereferenceOperator: () => DereferenceOperator,
|
23122
23117
|
Destructor: () => Destructor,
|
23118
|
+
Field: () => Field,
|
23123
23119
|
FunctionType: () => FunctionType,
|
23124
23120
|
Indexer: () => Indexer,
|
23125
23121
|
IntersectionType: () => IntersectionType,
|
@@ -23133,7 +23129,6 @@ __export(types_exports, {
|
|
23133
23129
|
UnionType: () => UnionType,
|
23134
23130
|
UnresolvedType: () => UnresolvedType2,
|
23135
23131
|
ValueParameter: () => ValueParameter,
|
23136
|
-
Variable: () => Variable,
|
23137
23132
|
VariantType: () => VariantType2
|
23138
23133
|
});
|
23139
23134
|
|
@@ -23175,6 +23170,9 @@ var AliasType = class {
|
|
23175
23170
|
default:
|
23176
23171
|
Debug.never(mode);
|
23177
23172
|
}
|
23173
|
+
if (newSubstitutions === this._substitutions) {
|
23174
|
+
return this;
|
23175
|
+
}
|
23178
23176
|
return this._analyzer.typeFactory.getAliasType(this._entity, newSubstitutions);
|
23179
23177
|
}
|
23180
23178
|
equals(other) {
|
@@ -23234,19 +23232,32 @@ var Substitutions = class _Substitutions {
|
|
23234
23232
|
}
|
23235
23233
|
substituteTypes(map) {
|
23236
23234
|
const newMap = /* @__PURE__ */ new Map();
|
23235
|
+
let mapChanged = false;
|
23237
23236
|
for (const [parameter, type] of this.map) {
|
23238
|
-
|
23237
|
+
const substitutedType = type.applySubstitutions(map);
|
23238
|
+
mapChanged ||= substitutedType !== type;
|
23239
|
+
newMap.set(parameter, substitutedType);
|
23240
|
+
}
|
23241
|
+
if (!mapChanged) {
|
23242
|
+
return this;
|
23239
23243
|
}
|
23240
23244
|
return new _Substitutions(this._analyzer, newMap);
|
23241
23245
|
}
|
23242
23246
|
substituteTypesAndMerge(map) {
|
23243
23247
|
const newMap = /* @__PURE__ */ new Map();
|
23248
|
+
let mapChanged = false;
|
23244
23249
|
for (const [parameter, type] of this.map) {
|
23245
|
-
|
23250
|
+
const substitutedType = type.applySubstitutions(map);
|
23251
|
+
mapChanged ||= substitutedType !== type;
|
23252
|
+
newMap.set(parameter, substitutedType);
|
23246
23253
|
}
|
23247
23254
|
for (const [parameter, type] of map) {
|
23255
|
+
mapChanged ||= this.map.get(parameter) !== type;
|
23248
23256
|
newMap.set(parameter, type);
|
23249
23257
|
}
|
23258
|
+
if (!mapChanged) {
|
23259
|
+
return this;
|
23260
|
+
}
|
23250
23261
|
return new _Substitutions(this._analyzer, newMap);
|
23251
23262
|
}
|
23252
23263
|
equals(other) {
|
@@ -23281,7 +23292,16 @@ var IntersectionType = class {
|
|
23281
23292
|
return Substitutions.empty(this._analyzer);
|
23282
23293
|
}
|
23283
23294
|
applySubstitutions(map) {
|
23284
|
-
const types =
|
23295
|
+
const types = new Array();
|
23296
|
+
let typesChanged = false;
|
23297
|
+
for (const type of this.originalTypes) {
|
23298
|
+
const substitutedType = type.applySubstitutions(map);
|
23299
|
+
typesChanged ||= substitutedType !== type;
|
23300
|
+
types.push(substitutedType);
|
23301
|
+
}
|
23302
|
+
if (!typesChanged) {
|
23303
|
+
return this;
|
23304
|
+
}
|
23285
23305
|
return this._analyzer.typeFactory.getIntersectionType(types);
|
23286
23306
|
}
|
23287
23307
|
getEntity() {
|
@@ -23338,6 +23358,9 @@ var FunctionType = class {
|
|
23338
23358
|
default:
|
23339
23359
|
Debug.never(mode);
|
23340
23360
|
}
|
23361
|
+
if (newSubstitutions === this._substitutions) {
|
23362
|
+
return this;
|
23363
|
+
}
|
23341
23364
|
return this._analyzer.typeFactory.getFunctionType(this._entity, newSubstitutions);
|
23342
23365
|
}
|
23343
23366
|
equals(other) {
|
@@ -23619,6 +23642,9 @@ var StructuredType2 = class {
|
|
23619
23642
|
default:
|
23620
23643
|
Debug.never(mode);
|
23621
23644
|
}
|
23645
|
+
if (newSubstitutions === this._substitutions) {
|
23646
|
+
return this;
|
23647
|
+
}
|
23622
23648
|
return this._analyzer.typeFactory.getStructuredType(this._entity, newSubstitutions);
|
23623
23649
|
}
|
23624
23650
|
isAspect() {
|
@@ -23835,11 +23861,11 @@ var ValueParameter = class {
|
|
23835
23861
|
return this._entity.isVariadic();
|
23836
23862
|
}
|
23837
23863
|
};
|
23838
|
-
var
|
23864
|
+
var Field = class _Field {
|
23839
23865
|
constructor(_entity, _substitutions) {
|
23840
23866
|
this._entity = _entity;
|
23841
23867
|
this._substitutions = _substitutions;
|
23842
|
-
this.kind = "
|
23868
|
+
this.kind = "field";
|
23843
23869
|
}
|
23844
23870
|
getName() {
|
23845
23871
|
return this._entity.getName();
|
@@ -23866,13 +23892,13 @@ var Variable = class _Variable {
|
|
23866
23892
|
return this._entity.isVariant();
|
23867
23893
|
}
|
23868
23894
|
applySubstitutions(substitutions) {
|
23869
|
-
return new
|
23895
|
+
return new _Field(this._entity, this._substitutions.substituteTypes(substitutions.map));
|
23870
23896
|
}
|
23871
23897
|
equals(other) {
|
23872
23898
|
if (this === other) {
|
23873
23899
|
return true;
|
23874
23900
|
}
|
23875
|
-
return other.kind === "
|
23901
|
+
return other.kind === "field" && this._entity === other._entity && this._substitutions.equals(other._substitutions);
|
23876
23902
|
}
|
23877
23903
|
};
|
23878
23904
|
var Operator = class _Operator {
|
@@ -24106,7 +24132,16 @@ var UnionType = class {
|
|
24106
24132
|
return Substitutions.empty(this._analyzer);
|
24107
24133
|
}
|
24108
24134
|
applySubstitutions(map) {
|
24109
|
-
const types =
|
24135
|
+
const types = new Array();
|
24136
|
+
let typesChanged = false;
|
24137
|
+
for (const type of this.originalTypes) {
|
24138
|
+
const substitutedType = type.applySubstitutions(map);
|
24139
|
+
typesChanged ||= substitutedType !== type;
|
24140
|
+
types.push(substitutedType);
|
24141
|
+
}
|
24142
|
+
if (!typesChanged) {
|
24143
|
+
return this;
|
24144
|
+
}
|
24110
24145
|
return this._analyzer.typeFactory.getUnionType(types);
|
24111
24146
|
}
|
24112
24147
|
getEntity() {
|
@@ -24188,6 +24223,9 @@ var VariantType2 = class {
|
|
24188
24223
|
default:
|
24189
24224
|
Debug.never(mode);
|
24190
24225
|
}
|
24226
|
+
if (newSubstitutions === this._substitutions) {
|
24227
|
+
return this;
|
24228
|
+
}
|
24191
24229
|
return this._analyzer.typeFactory.getVariantType(this._entity, newSubstitutions);
|
24192
24230
|
}
|
24193
24231
|
getEntity() {
|
@@ -24440,7 +24478,7 @@ var TypeMemberLookupBase = class {
|
|
24440
24478
|
if (mergeNonAspectShadowedMembersFirst) {
|
24441
24479
|
for (const shadowedMembers of shadowedMembersFromMultipleTypes) {
|
24442
24480
|
for (const shadowedMember of shadowedMembers) {
|
24443
|
-
if (
|
24481
|
+
if (TypeMemberEntity.isAspectTypeMember(shadowedMember.value.getEntity())) {
|
24444
24482
|
continue;
|
24445
24483
|
}
|
24446
24484
|
if (shadowingMembers.some((shadowingMember) => this.checkShadowing(shadowingMember, shadowedMember))) {
|
@@ -24452,7 +24490,7 @@ var TypeMemberLookupBase = class {
|
|
24452
24490
|
const newShadowingMembers = Array.from(result);
|
24453
24491
|
for (const shadowedMembers of shadowedMembersFromMultipleTypes) {
|
24454
24492
|
for (const shadowedMember of shadowedMembers) {
|
24455
|
-
if (!
|
24493
|
+
if (!TypeMemberEntity.isAspectTypeMember(shadowedMember.value.getEntity())) {
|
24456
24494
|
continue;
|
24457
24495
|
}
|
24458
24496
|
if (newShadowingMembers.some((shadowingMember) => this.checkShadowing(shadowingMember, shadowedMember))) {
|
@@ -25085,7 +25123,7 @@ var NamedTypeMemberLookup = class extends TypeMemberLookupByKeyBase {
|
|
25085
25123
|
return result;
|
25086
25124
|
}
|
25087
25125
|
checkShadowing(shadowing, shadowed) {
|
25088
|
-
if (shadowing.value.kind === "
|
25126
|
+
if (shadowing.value.kind === "field" && shadowed.value.kind === "field") {
|
25089
25127
|
return shadowing.name.value.considerEqual(shadowed.name.value);
|
25090
25128
|
}
|
25091
25129
|
if (shadowing.value.kind === "method" && shadowed.value.kind === "method") {
|
@@ -25095,24 +25133,10 @@ var NamedTypeMemberLookup = class extends TypeMemberLookupByKeyBase {
|
|
25095
25133
|
}
|
25096
25134
|
return shadowing.name.value.considerEqual(shadowed.name.value);
|
25097
25135
|
}
|
25098
|
-
isAspectMember(member) {
|
25099
|
-
switch (member.value.kind) {
|
25100
|
-
case "variable": {
|
25101
|
-
const container = member.value.getEntity().getContainer();
|
25102
|
-
return container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
25103
|
-
}
|
25104
|
-
case "method": {
|
25105
|
-
const container = member.value.getEntity().getContainer();
|
25106
|
-
return container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
25107
|
-
}
|
25108
|
-
default:
|
25109
|
-
Debug.never(member.value);
|
25110
|
-
}
|
25111
|
-
}
|
25112
25136
|
convertNamedMember(member, substitutions) {
|
25113
25137
|
switch (member.kind) {
|
25114
25138
|
case 0 /* Variable */:
|
25115
|
-
return new
|
25139
|
+
return new Field(member, substitutions);
|
25116
25140
|
case 1 /* Function */:
|
25117
25141
|
return new Method(this._analyzer, member, substitutions);
|
25118
25142
|
default:
|
@@ -25184,10 +25208,6 @@ var OperatorLookup = class extends TypeMemberLookupByKeyBase {
|
|
25184
25208
|
const shadowedParameters = shadowed.value.getValueParameters();
|
25185
25209
|
return shadowing.value.getOperatorKind() === shadowed.value.getOperatorKind() && shadowingParameters.length === shadowedParameters.length && Query.from(shadowingParameters).zip(shadowedParameters, (l, r) => l.getType().equals(r.getType())).all((v) => v);
|
25186
25210
|
}
|
25187
|
-
isAspectMember(member) {
|
25188
|
-
const container = member.value.getEntity().getContainer();
|
25189
|
-
return container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
25190
|
-
}
|
25191
25211
|
};
|
25192
25212
|
var IndexerLookup = class extends TypeMemberLookupBase {
|
25193
25213
|
constructor(analyzer, localizationContext) {
|
@@ -25223,10 +25243,6 @@ var IndexerLookup = class extends TypeMemberLookupBase {
|
|
25223
25243
|
const shadowedParameters = shadowed.value.getValueParameters();
|
25224
25244
|
return shadowingParameters.length === shadowedParameters.length && Query.from(shadowingParameters).zip(shadowedParameters, (l, r) => l.getType().equals(r.getType())).all((v) => v);
|
25225
25245
|
}
|
25226
|
-
isAspectMember(member) {
|
25227
|
-
const container = member.value.getEntity().getContainer();
|
25228
|
-
return container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
25229
|
-
}
|
25230
25246
|
};
|
25231
25247
|
var DereferenceOperatorLookup = class extends TypeMemberLookupBase {
|
25232
25248
|
constructor(analyzer, localizationContext) {
|
@@ -25260,10 +25276,6 @@ var DereferenceOperatorLookup = class extends TypeMemberLookupBase {
|
|
25260
25276
|
checkShadowing(shadowing, shadowed) {
|
25261
25277
|
return shadowing.value.getType().equals(shadowed.value.getType());
|
25262
25278
|
}
|
25263
|
-
isAspectMember(member) {
|
25264
|
-
const container = member.value.getEntity().getContainer();
|
25265
|
-
return container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
25266
|
-
}
|
25267
25279
|
};
|
25268
25280
|
var ConstructorLookup = class {
|
25269
25281
|
constructor(analyzer, localizationContext) {
|
@@ -25651,10 +25663,10 @@ var TsTypeMembersCreator = class {
|
|
25651
25663
|
}
|
25652
25664
|
return symbol.declarations?.filter(
|
25653
25665
|
(d) => ts.isMethodDeclaration(d) || ts.isMethodSignature(d)
|
25654
|
-
).map((d) => this.
|
25666
|
+
).map((d) => this.createMethodEntityNoReplacement(symbol, d, forceStatic)) ?? [];
|
25655
25667
|
}
|
25656
|
-
|
25657
|
-
const entity = new
|
25668
|
+
createMethodEntityNoReplacement(symbol, declaration, forceStatic) {
|
25669
|
+
const entity = new TsMethodEntity(this._tsctx, symbol, declaration, this._typeEntity, forceStatic);
|
25658
25670
|
this.registerTypeParameters(declaration, entity.getTypeParameters());
|
25659
25671
|
return entity;
|
25660
25672
|
}
|
@@ -26494,8 +26506,8 @@ var TsPropertyEntity = class {
|
|
26494
26506
|
const decl = this.getDeclaration();
|
26495
26507
|
return this._forceStatic || decl !== void 0 && (ts2.getCombinedModifierFlags(decl) & ts2.ModifierFlags.Static) !== 0;
|
26496
26508
|
}
|
26497
|
-
|
26498
|
-
let result = !this.isStatic();
|
26509
|
+
markedBasic() {
|
26510
|
+
let result = !this.isStatic() && !this.markedAbstract();
|
26499
26511
|
if (result) {
|
26500
26512
|
const isHidden = this.isHidden();
|
26501
26513
|
if (isHidden !== void 0) {
|
@@ -26511,19 +26523,18 @@ var TsPropertyEntity = class {
|
|
26511
26523
|
Debug.never(isHidden);
|
26512
26524
|
}
|
26513
26525
|
}
|
26526
|
+
if (result) {
|
26527
|
+
result = !(this._containingType.typeEntityKind === 1 /* Structured */ && this._containingType.isAspect());
|
26528
|
+
}
|
26514
26529
|
}
|
26515
26530
|
return result;
|
26516
26531
|
}
|
26517
|
-
|
26532
|
+
isOverride() {
|
26518
26533
|
return false;
|
26519
26534
|
}
|
26520
|
-
|
26535
|
+
markedAbstract() {
|
26521
26536
|
const declaration = this.getDeclaration();
|
26522
|
-
|
26523
|
-
if (!result) {
|
26524
|
-
result = this._containingType.typeEntityKind === 1 /* Structured */ && this._containingType.isAspect();
|
26525
|
-
}
|
26526
|
-
return result;
|
26537
|
+
return declaration !== void 0 && (ts2.getCombinedModifierFlags(declaration) & ts2.ModifierFlags.Abstract) !== 0;
|
26527
26538
|
}
|
26528
26539
|
getOverriddenMembers() {
|
26529
26540
|
return this._overriddenMembers.getOrInsertWith(() => {
|
@@ -26534,7 +26545,7 @@ var TsPropertyEntity = class {
|
|
26534
26545
|
result = TypeMemberLookup.ofType(this._tsctx.analyzer, baseType, void 0).getNamedMembersByName(
|
26535
26546
|
new SearchName(this.getName(), true),
|
26536
26547
|
1 /* OnlyInstanceMembers */
|
26537
|
-
).find((m) => m.value.kind === "
|
26548
|
+
).find((m) => m.value.kind === "field")?.value;
|
26538
26549
|
}
|
26539
26550
|
}
|
26540
26551
|
return result !== void 0 ? [result] : [];
|
@@ -26615,8 +26626,8 @@ var TsAccessorEntity = class {
|
|
26615
26626
|
const declaration = this.getGetAccessorDeclaration();
|
26616
26627
|
return this._forceStatic || declaration !== void 0 && (ts2.getCombinedModifierFlags(declaration) & ts2.ModifierFlags.Static) !== 0;
|
26617
26628
|
}
|
26618
|
-
|
26619
|
-
let result = !this.isStatic();
|
26629
|
+
markedBasic() {
|
26630
|
+
let result = !this.isStatic() && !this.markedAbstract();
|
26620
26631
|
if (result) {
|
26621
26632
|
const isHidden = this.isHidden();
|
26622
26633
|
if (isHidden !== void 0) {
|
@@ -26632,19 +26643,18 @@ var TsAccessorEntity = class {
|
|
26632
26643
|
Debug.never(isHidden);
|
26633
26644
|
}
|
26634
26645
|
}
|
26646
|
+
if (result) {
|
26647
|
+
result = !(this._containingType.typeEntityKind === 1 /* Structured */ && this._containingType.isAspect());
|
26648
|
+
}
|
26635
26649
|
}
|
26636
26650
|
return result;
|
26637
26651
|
}
|
26638
|
-
|
26652
|
+
isOverride() {
|
26639
26653
|
return false;
|
26640
26654
|
}
|
26641
|
-
|
26655
|
+
markedAbstract() {
|
26642
26656
|
const declaration = this.getGetAccessorDeclaration();
|
26643
|
-
|
26644
|
-
if (!result) {
|
26645
|
-
result = this._containingType.typeEntityKind === 1 /* Structured */ && this._containingType.isAspect();
|
26646
|
-
}
|
26647
|
-
return result;
|
26657
|
+
return declaration !== void 0 && (ts2.getCombinedModifierFlags(declaration) & ts2.ModifierFlags.Abstract) !== 0;
|
26648
26658
|
}
|
26649
26659
|
getOverriddenMembers() {
|
26650
26660
|
return this._overriddenMembers.getOrInsertWith(() => {
|
@@ -26655,7 +26665,7 @@ var TsAccessorEntity = class {
|
|
26655
26665
|
result = TypeMemberLookup.ofType(this._tsctx.analyzer, baseType, void 0).getNamedMembersByName(
|
26656
26666
|
new SearchName(this.getName(), true),
|
26657
26667
|
1 /* OnlyInstanceMembers */
|
26658
|
-
).find((m) => m.value.kind === "
|
26668
|
+
).find((m) => m.value.kind === "field")?.value;
|
26659
26669
|
}
|
26660
26670
|
}
|
26661
26671
|
return result !== void 0 ? [result] : [];
|
@@ -26729,7 +26739,7 @@ var TsSetAccessorEntity = class {
|
|
26729
26739
|
TsSetAccessorEntity = __decorateClass([
|
26730
26740
|
entityToStringDecorator
|
26731
26741
|
], TsSetAccessorEntity);
|
26732
|
-
var
|
26742
|
+
var TsMethodEntity = class {
|
26733
26743
|
constructor(_tsctx, _symbol, _declaration, _containingType, _forceStatic) {
|
26734
26744
|
this._tsctx = _tsctx;
|
26735
26745
|
this._symbol = _symbol;
|
@@ -26774,8 +26784,8 @@ var TsFunctionEntity = class {
|
|
26774
26784
|
isStatic() {
|
26775
26785
|
return this._forceStatic || (ts2.getCombinedModifierFlags(this._declaration) & ts2.ModifierFlags.Static) !== 0;
|
26776
26786
|
}
|
26777
|
-
|
26778
|
-
let result = !this.isStatic();
|
26787
|
+
markedBasic() {
|
26788
|
+
let result = !this.isStatic() && !this.markedAbstract();
|
26779
26789
|
if (result) {
|
26780
26790
|
const isHidden = this.isHidden();
|
26781
26791
|
if (isHidden !== void 0) {
|
@@ -26791,18 +26801,17 @@ var TsFunctionEntity = class {
|
|
26791
26801
|
Debug.never(isHidden);
|
26792
26802
|
}
|
26793
26803
|
}
|
26804
|
+
if (result) {
|
26805
|
+
result = !(this._containingType.typeEntityKind === 1 /* Structured */ && this._containingType.isAspect());
|
26806
|
+
}
|
26794
26807
|
}
|
26795
26808
|
return result;
|
26796
26809
|
}
|
26797
|
-
|
26810
|
+
isOverride() {
|
26798
26811
|
return false;
|
26799
26812
|
}
|
26800
|
-
|
26801
|
-
|
26802
|
-
if (!result) {
|
26803
|
-
result = this._containingType.typeEntityKind === 1 /* Structured */ && this._containingType.isAspect();
|
26804
|
-
}
|
26805
|
-
return result;
|
26813
|
+
markedAbstract() {
|
26814
|
+
return (ts2.getCombinedModifierFlags(this._declaration) & ts2.ModifierFlags.Abstract) !== 0;
|
26806
26815
|
}
|
26807
26816
|
isModifyingOwningPlainObject() {
|
26808
26817
|
return false;
|
@@ -26841,9 +26850,9 @@ var TsFunctionEntity = class {
|
|
26841
26850
|
});
|
26842
26851
|
}
|
26843
26852
|
};
|
26844
|
-
|
26853
|
+
TsMethodEntity = __decorateClass([
|
26845
26854
|
entityToStringDecorator
|
26846
|
-
],
|
26855
|
+
], TsMethodEntity);
|
26847
26856
|
var TsIteratorFunctionEntity = class {
|
26848
26857
|
constructor(_tsctx, _symbol, _containingType) {
|
26849
26858
|
this._tsctx = _tsctx;
|
@@ -26894,19 +26903,15 @@ var TsIteratorFunctionEntity = class {
|
|
26894
26903
|
isStatic() {
|
26895
26904
|
return false;
|
26896
26905
|
}
|
26897
|
-
|
26906
|
+
markedBasic() {
|
26898
26907
|
return true;
|
26899
26908
|
}
|
26900
|
-
|
26909
|
+
isOverride() {
|
26901
26910
|
return false;
|
26902
26911
|
}
|
26903
|
-
|
26912
|
+
markedAbstract() {
|
26904
26913
|
const declaration = this.getFirstDeclaration();
|
26905
|
-
|
26906
|
-
if (!result) {
|
26907
|
-
result = this._containingType.typeEntityKind === 1 /* Structured */ && this._containingType.isAspect();
|
26908
|
-
}
|
26909
|
-
return result;
|
26914
|
+
return declaration !== void 0 && (ts2.getCombinedModifierFlags(declaration) & ts2.ModifierFlags.Abstract) !== 0;
|
26910
26915
|
}
|
26911
26916
|
isModifyingOwningPlainObject() {
|
26912
26917
|
return false;
|
@@ -27115,13 +27120,13 @@ var TsIndexSignatureEntity = class {
|
|
27115
27120
|
isHidden() {
|
27116
27121
|
return this._tsctx.getTypeMemberHiding(this._declaration, this._containingType);
|
27117
27122
|
}
|
27118
|
-
|
27123
|
+
markedBasic() {
|
27119
27124
|
return false;
|
27120
27125
|
}
|
27121
|
-
|
27126
|
+
isOverride() {
|
27122
27127
|
return false;
|
27123
27128
|
}
|
27124
|
-
|
27129
|
+
markedAbstract() {
|
27125
27130
|
return false;
|
27126
27131
|
}
|
27127
27132
|
getTags() {
|
@@ -27172,7 +27177,7 @@ var TsConstructorEntity = class {
|
|
27172
27177
|
isHidden() {
|
27173
27178
|
return this._tsctx.getTypeMemberHiding(this._declaration, this._containingType);
|
27174
27179
|
}
|
27175
|
-
|
27180
|
+
markedAbstract() {
|
27176
27181
|
return false;
|
27177
27182
|
}
|
27178
27183
|
getTags() {
|
@@ -27210,7 +27215,7 @@ var TsSignatureBasedDefaultConstructorEntity = class {
|
|
27210
27215
|
isHidden() {
|
27211
27216
|
return void 0;
|
27212
27217
|
}
|
27213
|
-
|
27218
|
+
markedAbstract() {
|
27214
27219
|
return false;
|
27215
27220
|
}
|
27216
27221
|
getTags() {
|
@@ -27297,13 +27302,13 @@ var TsEnumMemberEntity = class {
|
|
27297
27302
|
isStatic() {
|
27298
27303
|
return true;
|
27299
27304
|
}
|
27300
|
-
|
27305
|
+
markedBasic() {
|
27301
27306
|
return false;
|
27302
27307
|
}
|
27303
|
-
|
27308
|
+
isOverride() {
|
27304
27309
|
return false;
|
27305
27310
|
}
|
27306
|
-
|
27311
|
+
markedAbstract() {
|
27307
27312
|
return false;
|
27308
27313
|
}
|
27309
27314
|
getOverriddenMembers() {
|
@@ -27916,7 +27921,10 @@ var PackageVariableDeclarationEntity = class {
|
|
27916
27921
|
this._hasReportedAllDiagnostics = false;
|
27917
27922
|
}
|
27918
27923
|
get modifierFlags() {
|
27919
|
-
|
27924
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
27925
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
27926
|
+
}
|
27927
|
+
return this._modifierFlags;
|
27920
27928
|
}
|
27921
27929
|
getName() {
|
27922
27930
|
return this._analyzer.createNameFromIdentifier(this._node.name);
|
@@ -27992,7 +28000,10 @@ var ComputedPackageVariableDeclarationEntity = class {
|
|
27992
28000
|
}
|
27993
28001
|
}
|
27994
28002
|
get modifierFlags() {
|
27995
|
-
|
28003
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
28004
|
+
this._modifierFlags = createDeclaredModifierFlags(this._getterOrSetterDeclaration);
|
28005
|
+
}
|
28006
|
+
return this._modifierFlags;
|
27996
28007
|
}
|
27997
28008
|
getName() {
|
27998
28009
|
return this._analyzer.createNameFromIdentifier(this._getterOrSetterDeclaration.name);
|
@@ -28051,7 +28062,10 @@ var FieldDeclarationEntity = class {
|
|
28051
28062
|
this._node = node;
|
28052
28063
|
}
|
28053
28064
|
get modifierFlags() {
|
28054
|
-
|
28065
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
28066
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
28067
|
+
}
|
28068
|
+
return this._modifierFlags;
|
28055
28069
|
}
|
28056
28070
|
getName() {
|
28057
28071
|
return this._analyzer.createNameFromIdentifier(this._node.name);
|
@@ -28096,22 +28110,17 @@ var FieldDeclarationEntity = class {
|
|
28096
28110
|
isStatic() {
|
28097
28111
|
return (this.modifierFlags & 64 /* Static */) !== 0;
|
28098
28112
|
}
|
28099
|
-
|
28113
|
+
markedBasic() {
|
28100
28114
|
return (this.modifierFlags & 32 /* Basic */) !== 0;
|
28101
28115
|
}
|
28102
|
-
|
28103
|
-
return (this.modifierFlags & 256 /*
|
28116
|
+
isOverride() {
|
28117
|
+
return (this.modifierFlags & 256 /* Override */) !== 0;
|
28104
28118
|
}
|
28105
|
-
|
28106
|
-
|
28107
|
-
if (!result && this._node.initializer === void 0) {
|
28108
|
-
const container = this.getContainer();
|
28109
|
-
result = container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
28110
|
-
}
|
28111
|
-
return result;
|
28119
|
+
markedAbstract() {
|
28120
|
+
return (this.modifierFlags & 128 /* Abstract */) !== 0;
|
28112
28121
|
}
|
28113
28122
|
getOverriddenMembers() {
|
28114
|
-
return this._overriddenMembers.getOrInsertWith(() => this._analyzer.overriddenMember.
|
28123
|
+
return this._overriddenMembers.getOrInsertWith(() => this._analyzer.overriddenMember.getOverriddenFields(this._node));
|
28115
28124
|
}
|
28116
28125
|
isVariant() {
|
28117
28126
|
return false;
|
@@ -28152,7 +28161,10 @@ var ComputedFieldDeclarationEntity = class {
|
|
28152
28161
|
}
|
28153
28162
|
}
|
28154
28163
|
get modifierFlags() {
|
28155
|
-
|
28164
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
28165
|
+
this._modifierFlags = createDeclaredModifierFlags(this._getterOrSetterDeclaration);
|
28166
|
+
}
|
28167
|
+
return this._modifierFlags;
|
28156
28168
|
}
|
28157
28169
|
getName() {
|
28158
28170
|
return this._analyzer.createNameFromIdentifier(this._getterOrSetterDeclaration.name);
|
@@ -28176,19 +28188,14 @@ var ComputedFieldDeclarationEntity = class {
|
|
28176
28188
|
isStatic() {
|
28177
28189
|
return (this.modifierFlags & 64 /* Static */) !== 0;
|
28178
28190
|
}
|
28179
|
-
|
28191
|
+
markedBasic() {
|
28180
28192
|
return (this.modifierFlags & 32 /* Basic */) !== 0;
|
28181
28193
|
}
|
28182
|
-
|
28183
|
-
return (this.modifierFlags & 256 /*
|
28194
|
+
isOverride() {
|
28195
|
+
return (this.modifierFlags & 256 /* Override */) !== 0;
|
28184
28196
|
}
|
28185
|
-
|
28186
|
-
|
28187
|
-
if (!result && this._getterOrSetterDeclaration.block === void 0) {
|
28188
|
-
const container = this.getContainer();
|
28189
|
-
result = container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
28190
|
-
}
|
28191
|
-
return result;
|
28197
|
+
markedAbstract() {
|
28198
|
+
return (this.modifierFlags & 128 /* Abstract */) !== 0;
|
28192
28199
|
}
|
28193
28200
|
getDefinition() {
|
28194
28201
|
const nodes = [];
|
@@ -28213,7 +28220,7 @@ var ComputedFieldDeclarationEntity = class {
|
|
28213
28220
|
return this.getGetter()?.getTags() ?? [];
|
28214
28221
|
}
|
28215
28222
|
getOverriddenMembers() {
|
28216
|
-
return this._overriddenMembers.getOrInsertWith(() => this._analyzer.overriddenMember.
|
28223
|
+
return this._overriddenMembers.getOrInsertWith(() => this._analyzer.overriddenMember.getOverriddenFields(this._getterOrSetterDeclaration));
|
28217
28224
|
}
|
28218
28225
|
isVariant() {
|
28219
28226
|
return false;
|
@@ -28269,13 +28276,13 @@ var VariantDeclarationEntity = class {
|
|
28269
28276
|
isStatic() {
|
28270
28277
|
return true;
|
28271
28278
|
}
|
28272
|
-
|
28279
|
+
markedBasic() {
|
28273
28280
|
return false;
|
28274
28281
|
}
|
28275
|
-
|
28282
|
+
isOverride() {
|
28276
28283
|
return false;
|
28277
28284
|
}
|
28278
|
-
|
28285
|
+
markedAbstract() {
|
28279
28286
|
return false;
|
28280
28287
|
}
|
28281
28288
|
getOverriddenMembers() {
|
@@ -28787,14 +28794,14 @@ IntrinsicPackageVariableEntity = __decorateClass([
|
|
28787
28794
|
entityToStringDecorator
|
28788
28795
|
], IntrinsicPackageVariableEntity);
|
28789
28796
|
var IntrinsicFieldEntity = class {
|
28790
|
-
constructor(_name, _type, _container, _isStatic,
|
28797
|
+
constructor(_name, _type, _container, _isStatic, _markedBasic, _isOverride, _markedAbstract, _isSpecial, _isHidden, _getter, _setter, _overriddenMembers) {
|
28791
28798
|
this._name = _name;
|
28792
28799
|
this._type = _type;
|
28793
28800
|
this._container = _container;
|
28794
28801
|
this._isStatic = _isStatic;
|
28795
|
-
this.
|
28796
|
-
this.
|
28797
|
-
this.
|
28802
|
+
this._markedBasic = _markedBasic;
|
28803
|
+
this._isOverride = _isOverride;
|
28804
|
+
this._markedAbstract = _markedAbstract;
|
28798
28805
|
this._isSpecial = _isSpecial;
|
28799
28806
|
this._isHidden = _isHidden;
|
28800
28807
|
this._getter = _getter;
|
@@ -28836,14 +28843,14 @@ var IntrinsicFieldEntity = class {
|
|
28836
28843
|
isStatic() {
|
28837
28844
|
return this._isStatic;
|
28838
28845
|
}
|
28839
|
-
|
28840
|
-
return this.
|
28846
|
+
markedBasic() {
|
28847
|
+
return this._markedBasic;
|
28841
28848
|
}
|
28842
|
-
|
28843
|
-
return this.
|
28849
|
+
isOverride() {
|
28850
|
+
return this._isOverride;
|
28844
28851
|
}
|
28845
|
-
|
28846
|
-
return this.
|
28852
|
+
markedAbstract() {
|
28853
|
+
return this._markedAbstract;
|
28847
28854
|
}
|
28848
28855
|
getOverriddenMembers() {
|
28849
28856
|
return this._overriddenMembers;
|
@@ -31721,14 +31728,14 @@ var DeclarationsUsageCounter = class {
|
|
31721
31728
|
case "package-name-segment-access":
|
31722
31729
|
break;
|
31723
31730
|
case "static-field-access":
|
31724
|
-
entity = meaning.
|
31731
|
+
entity = meaning.field.value.getEntity();
|
31725
31732
|
accessKind = meaning.accessKind;
|
31726
31733
|
break;
|
31727
31734
|
case "static-method-access":
|
31728
31735
|
entity = meaning.singleSuitableFunction?.value.getEntity();
|
31729
31736
|
break;
|
31730
31737
|
case "instance-field-access":
|
31731
|
-
entity = meaning.
|
31738
|
+
entity = meaning.field.value.getEntity();
|
31732
31739
|
accessKind = meaning.accessKind;
|
31733
31740
|
break;
|
31734
31741
|
case "instance-method-access":
|
@@ -31861,6 +31868,45 @@ var Meaning_unresolved4 = class {
|
|
31861
31868
|
}
|
31862
31869
|
};
|
31863
31870
|
|
31871
|
+
// source/analysis/FunctionOverloadResolver.ts
|
31872
|
+
var Resolver6 = class {
|
31873
|
+
constructor(_analyzer) {
|
31874
|
+
this._analyzer = _analyzer;
|
31875
|
+
}
|
31876
|
+
resolveByCallExpression(candidates, node) {
|
31877
|
+
const typeArgumentCount = node.expression.kind === 89 /* GenericSpecializationExpression */ ? node.expression.typeArgumentClause.typeArgumentList.typeArguments.count() : 0;
|
31878
|
+
const signatures = candidates.filter((c) => typeArgumentCount >= c.getRequiredTypeParameterCount() && typeArgumentCount <= c.getTypeParameterCount()).map((c) => new MatcherSignature2(c));
|
31879
|
+
const args = node.argumentList.arguments.map((a) => new SourceArgument(this._analyzer, a)).toArray();
|
31880
|
+
return new OverloadResolver(this._analyzer, signatures, args).resolveOverload().map((s) => s.value);
|
31881
|
+
}
|
31882
|
+
resolveByTargetType(candidates, targetType) {
|
31883
|
+
return candidates.filter((c) => this._analyzer.isTypeAssignableTo(c.getSignatureType(), targetType));
|
31884
|
+
}
|
31885
|
+
};
|
31886
|
+
var MatcherSignature2 = class {
|
31887
|
+
constructor(value) {
|
31888
|
+
this._parameters = new Cached();
|
31889
|
+
this.value = value;
|
31890
|
+
}
|
31891
|
+
getParameters() {
|
31892
|
+
return this._parameters.getOrInsertWith(() => this.value.getValueParameters().map((p) => new MatcherSignatureParameter2(p)));
|
31893
|
+
}
|
31894
|
+
};
|
31895
|
+
var MatcherSignatureParameter2 = class {
|
31896
|
+
constructor(value) {
|
31897
|
+
this.value = value;
|
31898
|
+
}
|
31899
|
+
getName() {
|
31900
|
+
return this.value.getName();
|
31901
|
+
}
|
31902
|
+
getType() {
|
31903
|
+
return this.value.getType();
|
31904
|
+
}
|
31905
|
+
isOptional() {
|
31906
|
+
return this.value.isOptional();
|
31907
|
+
}
|
31908
|
+
};
|
31909
|
+
|
31864
31910
|
// source/analysis/SubstitutedFunction.ts
|
31865
31911
|
var SubstitutedFunction_entity = class {
|
31866
31912
|
constructor(entity, entitySignatureType, substitutions) {
|
@@ -31927,7 +31973,7 @@ var SubstitutedFunction_typeMember = class {
|
|
31927
31973
|
};
|
31928
31974
|
|
31929
31975
|
// source/analysis/IdentifierExpressionMeaning.ts
|
31930
|
-
var
|
31976
|
+
var Resolver7 = class {
|
31931
31977
|
constructor(analyzer, node, targetTypeHint) {
|
31932
31978
|
this._semanticContext = new Cached();
|
31933
31979
|
this._analyzer = analyzer;
|
@@ -32289,6 +32335,12 @@ var FunctionOverloadResolverCandidate = class {
|
|
32289
32335
|
getSignatureType() {
|
32290
32336
|
return this._analyzer.type.ofAccessedFunction(this.func);
|
32291
32337
|
}
|
32338
|
+
getTypeParameterCount() {
|
32339
|
+
return this.func.value.getTypeParameters().length;
|
32340
|
+
}
|
32341
|
+
getRequiredTypeParameterCount() {
|
32342
|
+
return getRequiredTypeParameterCount(this.func.value.getTypeParameters());
|
32343
|
+
}
|
32292
32344
|
};
|
32293
32345
|
var OperatorOverloadResolverCandidate = class {
|
32294
32346
|
constructor(analyzer, operator) {
|
@@ -32311,6 +32363,12 @@ var OperatorOverloadResolverCandidate = class {
|
|
32311
32363
|
getSignatureType() {
|
32312
32364
|
return this.operator.value.getSignatureType();
|
32313
32365
|
}
|
32366
|
+
getTypeParameterCount() {
|
32367
|
+
return 0;
|
32368
|
+
}
|
32369
|
+
getRequiredTypeParameterCount() {
|
32370
|
+
return 0;
|
32371
|
+
}
|
32314
32372
|
};
|
32315
32373
|
var GenericOverloadResolverCandidateValueParameter = class {
|
32316
32374
|
constructor(entity, type, localizedName) {
|
@@ -32406,7 +32464,7 @@ var ImportedPackage = class {
|
|
32406
32464
|
};
|
32407
32465
|
|
32408
32466
|
// source/analysis/IndexedAccessExpressionMeaning.ts
|
32409
|
-
var
|
32467
|
+
var Resolver8 = class {
|
32410
32468
|
constructor(_analyzer, _node) {
|
32411
32469
|
this._analyzer = _analyzer;
|
32412
32470
|
this._node = _node;
|
@@ -32618,7 +32676,7 @@ var PackageMemberLookup = class {
|
|
32618
32676
|
};
|
32619
32677
|
|
32620
32678
|
// source/analysis/MemberAccessExpressionMeaning.ts
|
32621
|
-
var
|
32679
|
+
var Resolver9 = class {
|
32622
32680
|
constructor(analyzer, node, targetTypeHint) {
|
32623
32681
|
this._semanticContext = new Cached();
|
32624
32682
|
this._analyzer = analyzer;
|
@@ -32814,7 +32872,7 @@ var Resolver8 = class {
|
|
32814
32872
|
}
|
32815
32873
|
if (namedMembers.length === 1) {
|
32816
32874
|
const namedMember = namedMembers[0];
|
32817
|
-
if (namedMember.value.kind === "
|
32875
|
+
if (namedMember.value.kind === "field") {
|
32818
32876
|
const variable = namedMember.value;
|
32819
32877
|
const accessKind = this.convertSyntacticAccessKind(
|
32820
32878
|
this._analyzer.getSyntacticAccessKind(this._node),
|
@@ -32908,7 +32966,7 @@ var Resolver8 = class {
|
|
32908
32966
|
}
|
32909
32967
|
if (namedMembers.length === 1) {
|
32910
32968
|
const namedMember = namedMembers[0];
|
32911
|
-
if (namedMember.value.kind === "
|
32969
|
+
if (namedMember.value.kind === "field") {
|
32912
32970
|
const variable = namedMember.value;
|
32913
32971
|
const accessKind = this.convertSyntacticAccessKind(
|
32914
32972
|
this._analyzer.getSyntacticAccessKind(this._node),
|
@@ -33084,9 +33142,9 @@ var Meaning_packageNameSegmentAccess2 = class {
|
|
33084
33142
|
}
|
33085
33143
|
};
|
33086
33144
|
var Meaning_staticFieldAccess = class {
|
33087
|
-
constructor(type,
|
33145
|
+
constructor(type, field, accessKind) {
|
33088
33146
|
this.type = type;
|
33089
|
-
this.
|
33147
|
+
this.field = field;
|
33090
33148
|
this.accessKind = accessKind;
|
33091
33149
|
this.kind = "static-field-access";
|
33092
33150
|
}
|
@@ -33103,8 +33161,8 @@ var Meaning_staticMethodAccess = class {
|
|
33103
33161
|
}
|
33104
33162
|
};
|
33105
33163
|
var Meaning_instanceFieldAccess = class {
|
33106
|
-
constructor(
|
33107
|
-
this.
|
33164
|
+
constructor(field, accessKind) {
|
33165
|
+
this.field = field;
|
33108
33166
|
this.accessKind = accessKind;
|
33109
33167
|
this.kind = "instance-field-access";
|
33110
33168
|
}
|
@@ -33161,6 +33219,12 @@ var FunctionOverloadResolverCandidate2 = class {
|
|
33161
33219
|
getSignatureType() {
|
33162
33220
|
return this._analyzer.type.ofAccessedFunction(this.func);
|
33163
33221
|
}
|
33222
|
+
getTypeParameterCount() {
|
33223
|
+
return this.func.value.getTypeParameters().length;
|
33224
|
+
}
|
33225
|
+
getRequiredTypeParameterCount() {
|
33226
|
+
return getRequiredTypeParameterCount(this.func.value.getTypeParameters());
|
33227
|
+
}
|
33164
33228
|
};
|
33165
33229
|
var OperatorOverloadResolverCandidate2 = class {
|
33166
33230
|
constructor(analyzer, operator) {
|
@@ -33183,6 +33247,12 @@ var OperatorOverloadResolverCandidate2 = class {
|
|
33183
33247
|
getSignatureType() {
|
33184
33248
|
return this.operator.value.getSignatureType();
|
33185
33249
|
}
|
33250
|
+
getTypeParameterCount() {
|
33251
|
+
return 0;
|
33252
|
+
}
|
33253
|
+
getRequiredTypeParameterCount() {
|
33254
|
+
return 0;
|
33255
|
+
}
|
33186
33256
|
};
|
33187
33257
|
var GenericOverloadResolverCandidateValueParameter2 = class {
|
33188
33258
|
constructor(entity, type, localizedName) {
|
@@ -33500,7 +33570,7 @@ var TypeOverloadResolverCandidate3 = class {
|
|
33500
33570
|
};
|
33501
33571
|
|
33502
33572
|
// source/analysis/ObjectExpressionMeaning.ts
|
33503
|
-
var
|
33573
|
+
var Resolver10 = class {
|
33504
33574
|
constructor(analyzer, node) {
|
33505
33575
|
this._analyzer = analyzer;
|
33506
33576
|
this._node = node;
|
@@ -33598,44 +33668,6 @@ var Meaning_unresolved8 = class {
|
|
33598
33668
|
}
|
33599
33669
|
};
|
33600
33670
|
|
33601
|
-
// source/analysis/OperationOverloadResolver.ts
|
33602
|
-
var Resolver10 = class {
|
33603
|
-
constructor(_analyzer) {
|
33604
|
-
this._analyzer = _analyzer;
|
33605
|
-
}
|
33606
|
-
resolveByCallExpression(candidates, node) {
|
33607
|
-
const signatures = candidates.map((c) => new MatcherSignature2(c));
|
33608
|
-
const args = node.argumentList.arguments.map((a) => new SourceArgument(this._analyzer, a)).toArray();
|
33609
|
-
return new OverloadResolver(this._analyzer, signatures, args).resolveOverload().map((s) => s.value);
|
33610
|
-
}
|
33611
|
-
resolveByTargetType(candidates, targetType) {
|
33612
|
-
return candidates.filter((c) => this._analyzer.isTypeAssignableTo(c.getSignatureType(), targetType));
|
33613
|
-
}
|
33614
|
-
};
|
33615
|
-
var MatcherSignature2 = class {
|
33616
|
-
constructor(value) {
|
33617
|
-
this._parameters = new Cached();
|
33618
|
-
this.value = value;
|
33619
|
-
}
|
33620
|
-
getParameters() {
|
33621
|
-
return this._parameters.getOrInsertWith(() => this.value.getValueParameters().map((p) => new MatcherSignatureParameter2(p)));
|
33622
|
-
}
|
33623
|
-
};
|
33624
|
-
var MatcherSignatureParameter2 = class {
|
33625
|
-
constructor(value) {
|
33626
|
-
this.value = value;
|
33627
|
-
}
|
33628
|
-
getName() {
|
33629
|
-
return this.value.getName();
|
33630
|
-
}
|
33631
|
-
getType() {
|
33632
|
-
return this.value.getType();
|
33633
|
-
}
|
33634
|
-
isOptional() {
|
33635
|
-
return this.value.isOptional();
|
33636
|
-
}
|
33637
|
-
};
|
33638
|
-
|
33639
33671
|
// source/analysis/PackageMemberNameConflictsValidator.ts
|
33640
33672
|
var PackageMemberNameConflictsValidator = class {
|
33641
33673
|
constructor(_analyzer, _members) {
|
@@ -33663,99 +33695,60 @@ var PackageMemberNameConflictsValidator = class {
|
|
33663
33695
|
return this._diagnostics;
|
33664
33696
|
}
|
33665
33697
|
validateFunctionNameConflicts(entities) {
|
33666
|
-
const functionGroups = [];
|
33667
33698
|
for (const entity of entities) {
|
33668
|
-
|
33669
|
-
|
33670
|
-
|
33671
|
-
|
33672
|
-
|
33673
|
-
|
33674
|
-
|
33675
|
-
|
33676
|
-
|
33677
|
-
|
33699
|
+
for (const entityToCheckAgainst of entities) {
|
33700
|
+
if (entityToCheckAgainst === entity) {
|
33701
|
+
continue;
|
33702
|
+
}
|
33703
|
+
if (this._analyzer.conflictsCheck.doFunctionSignaturesConflict(entity, entityToCheckAgainst) && this.shouldReportConflictWithMemberBasedOnHiding(entity, entityToCheckAgainst)) {
|
33704
|
+
this.reportNameConflictDiagnostic(
|
33705
|
+
entity,
|
33706
|
+
299 /* PackageAlreadyContainsFunctionWithTheSameNameAndParameterTypes */
|
33707
|
+
);
|
33708
|
+
break;
|
33709
|
+
}
|
33678
33710
|
}
|
33679
|
-
this.createAndAddNameConflictDiagnosticsForAllEntities(
|
33680
|
-
group,
|
33681
|
-
299 /* PackageAlreadyContainsFunctionWithTheSameNameAndParameterTypes */
|
33682
|
-
);
|
33683
33711
|
}
|
33684
33712
|
}
|
33685
|
-
areFunctionSignaturesEqual(entity1, entity2) {
|
33686
|
-
const valueParameters1 = entity1.getValueParameters();
|
33687
|
-
const valueParameters2 = entity2.getValueParameters();
|
33688
|
-
return valueParameters1.length === valueParameters2.length && Query.from(valueParameters1).zip(valueParameters2, (p1, p2) => p1.getType().equals(p2.getType())).all((v) => v);
|
33689
|
-
}
|
33690
33713
|
validateTypeNameConflicts(entities) {
|
33691
33714
|
for (const entity of entities) {
|
33692
|
-
const
|
33693
|
-
|
33694
|
-
let conflictingTypes;
|
33695
|
-
for (const typeToCompareWith of entities) {
|
33696
|
-
if (typeToCompareWith === entity) {
|
33715
|
+
for (const entityToCheckAgainst of entities) {
|
33716
|
+
if (entityToCheckAgainst === entity) {
|
33697
33717
|
continue;
|
33698
33718
|
}
|
33699
|
-
|
33700
|
-
|
33701
|
-
|
33702
|
-
|
33703
|
-
|
33704
|
-
|
33705
|
-
)) {
|
33706
|
-
conflictingTypes ??= [];
|
33707
|
-
conflictingTypes.push(typeToCompareWith);
|
33719
|
+
if (this._analyzer.conflictsCheck.doPackageTypesConflict(entity, entityToCheckAgainst) && this.shouldReportConflictWithMemberBasedOnHiding(entity, entityToCheckAgainst)) {
|
33720
|
+
this.reportNameConflictDiagnostic(
|
33721
|
+
entity,
|
33722
|
+
300 /* PackageAlreadyContainsTypeWithTheSameNameAndSameOrIntersectingTypeParameterCount */
|
33723
|
+
);
|
33724
|
+
break;
|
33708
33725
|
}
|
33709
33726
|
}
|
33710
|
-
if (conflictingTypes !== void 0) {
|
33711
|
-
this.createAndAddNameConflictDiagnostic(
|
33712
|
-
entity,
|
33713
|
-
conflictingTypes,
|
33714
|
-
300 /* PackageAlreadyContainsTypeWithTheSameNameAndSameOrIntersectingTypeParameterCount */
|
33715
|
-
);
|
33716
|
-
}
|
33717
33727
|
}
|
33718
33728
|
}
|
33719
|
-
typeParameterCountsIntersect(requiredCount1, count1, requiredCount2, count2) {
|
33720
|
-
return requiredCount1 <= count2 && requiredCount2 <= count1;
|
33721
|
-
}
|
33722
33729
|
createAndAddNameConflictDiagnosticsForAllEntities(entities, diagnosticCode) {
|
33723
33730
|
for (const entity of entities) {
|
33724
|
-
this.
|
33731
|
+
if (entities.some((e) => e !== entity && this.shouldReportConflictWithMemberBasedOnHiding(entity, e))) {
|
33732
|
+
this.reportNameConflictDiagnostic(entity, diagnosticCode);
|
33733
|
+
}
|
33725
33734
|
}
|
33726
33735
|
}
|
33727
|
-
|
33728
|
-
const
|
33729
|
-
|
33730
|
-
|
33731
|
-
|
33732
|
-
|
33733
|
-
|
33734
|
-
|
33735
|
-
|
33736
|
-
|
33737
|
-
|
33738
|
-
|
33739
|
-
|
33740
|
-
|
33741
|
-
|
33742
|
-
|
33743
|
-
}
|
33744
|
-
} else if (hiding.kind === "file") {
|
33745
|
-
const conflictsWithOtherMembers = conflictingEntities.some((e) => {
|
33746
|
-
if (e === entity) {
|
33747
|
-
return false;
|
33748
|
-
}
|
33749
|
-
const currentHiding = e.isHidden();
|
33750
|
-
return currentHiding === void 0 || currentHiding.kind === "package" || currentHiding?.kind === "file" && currentHiding.sourceFile === hiding.sourceFile;
|
33751
|
-
});
|
33752
|
-
if (conflictsWithOtherMembers) {
|
33753
|
-
const diagnosticLocation = this.getDiagnosticLocation(entity);
|
33754
|
-
if (diagnosticLocation !== void 0) {
|
33755
|
-
const diagnosticData = DiagnosticData.withCode(diagnosticCode);
|
33756
|
-
this._diagnostics.push(new Diagnostic(diagnosticData, diagnosticLocation));
|
33757
|
-
}
|
33758
|
-
}
|
33736
|
+
shouldReportConflictWithMemberBasedOnHiding(entity1, entity2) {
|
33737
|
+
const entity1Hiding = entity1.isHidden();
|
33738
|
+
const entity2Hiding = entity2.isHidden();
|
33739
|
+
if (entity1Hiding === void 0 || entity1Hiding.kind === "package") {
|
33740
|
+
return entity2Hiding === void 0 || entity2Hiding.kind === "package";
|
33741
|
+
} else if (entity1Hiding.kind === "file") {
|
33742
|
+
return entity2Hiding === void 0 || entity2Hiding.kind === "package" || entity2Hiding.kind === "file" && entity2Hiding.sourceFile === entity1Hiding.sourceFile;
|
33743
|
+
} else {
|
33744
|
+
return true;
|
33745
|
+
}
|
33746
|
+
}
|
33747
|
+
reportNameConflictDiagnostic(entity, code) {
|
33748
|
+
const diagnosticLocation = this.getDiagnosticLocation(entity);
|
33749
|
+
if (diagnosticLocation !== void 0) {
|
33750
|
+
const diagnosticData = DiagnosticData.withCode(code);
|
33751
|
+
this._diagnostics.push(new Diagnostic(diagnosticData, diagnosticLocation));
|
33759
33752
|
}
|
33760
33753
|
}
|
33761
33754
|
getDiagnosticLocation(entity) {
|
@@ -35207,14 +35200,14 @@ var NarrowableReference;
|
|
35207
35200
|
}
|
35208
35201
|
NarrowableReference2.PackageVariable = PackageVariable;
|
35209
35202
|
class InstanceField {
|
35210
|
-
constructor(_analyzer,
|
35203
|
+
constructor(_analyzer, field, receiver) {
|
35211
35204
|
this._analyzer = _analyzer;
|
35212
|
-
this.
|
35205
|
+
this.field = field;
|
35213
35206
|
this.receiver = receiver;
|
35214
35207
|
this.kind = "instance-field";
|
35215
35208
|
}
|
35216
35209
|
equals(other) {
|
35217
|
-
return other.kind === "instance-field" && this.
|
35210
|
+
return other.kind === "instance-field" && this.field.equals(other.field) && this.receiver.equals(other.receiver);
|
35218
35211
|
}
|
35219
35212
|
contains(other) {
|
35220
35213
|
if (this.receiver.equals(other)) {
|
@@ -35228,7 +35221,7 @@ var NarrowableReference;
|
|
35228
35221
|
return false;
|
35229
35222
|
}
|
35230
35223
|
const meaning = this._analyzer.resolveIdentifierExpression(expression).meaning;
|
35231
|
-
return meaning.kind === "variable-access" && meaning.variable.value.kind === "type-member" && meaning.variable.value.value.equals(this.
|
35224
|
+
return meaning.kind === "variable-access" && meaning.variable.value.kind === "type-member" && meaning.variable.value.value.equals(this.field);
|
35232
35225
|
} else if (expression.kind === 78 /* MemberAccessExpression */) {
|
35233
35226
|
const receiverExpression = unwrapExpressionForNarrowableReferenceCheck(expression.expression);
|
35234
35227
|
if (!isNarrowableReferenceExpression(receiverExpression)) {
|
@@ -35238,7 +35231,7 @@ var NarrowableReference;
|
|
35238
35231
|
return false;
|
35239
35232
|
}
|
35240
35233
|
const meaning = this._analyzer.resolveMemberAccessExpression(expression).meaning;
|
35241
|
-
return meaning.kind === "instance-field-access" && meaning.
|
35234
|
+
return meaning.kind === "instance-field-access" && meaning.field.value.equals(this.field);
|
35242
35235
|
} else {
|
35243
35236
|
return false;
|
35244
35237
|
}
|
@@ -35255,13 +35248,13 @@ var NarrowableReference;
|
|
35255
35248
|
}
|
35256
35249
|
NarrowableReference2.InstanceField = InstanceField;
|
35257
35250
|
class StaticField {
|
35258
|
-
constructor(_analyzer,
|
35251
|
+
constructor(_analyzer, field) {
|
35259
35252
|
this._analyzer = _analyzer;
|
35260
|
-
this.
|
35253
|
+
this.field = field;
|
35261
35254
|
this.kind = "static-field";
|
35262
35255
|
}
|
35263
35256
|
equals(other) {
|
35264
|
-
return other.kind === "static-field" && this.
|
35257
|
+
return other.kind === "static-field" && this.field.equals(other.field);
|
35265
35258
|
}
|
35266
35259
|
contains(_other) {
|
35267
35260
|
return false;
|
@@ -35269,7 +35262,7 @@ var NarrowableReference;
|
|
35269
35262
|
equalsExpression(expression) {
|
35270
35263
|
if (expression.kind === 88 /* IdentifierExpression */) {
|
35271
35264
|
const meaning = this._analyzer.resolveIdentifierExpression(expression).meaning;
|
35272
|
-
return meaning.kind === "variable-access" && meaning.variable.value.kind === "type-member" && meaning.variable.value.value.equals(this.
|
35265
|
+
return meaning.kind === "variable-access" && meaning.variable.value.kind === "type-member" && meaning.variable.value.value.equals(this.field);
|
35273
35266
|
} else if (expression.kind === 78 /* MemberAccessExpression */) {
|
35274
35267
|
let result = NarrowableReferenceComparisonUtils.checkExpressionDenotesType(
|
35275
35268
|
this._analyzer,
|
@@ -35277,7 +35270,7 @@ var NarrowableReference;
|
|
35277
35270
|
);
|
35278
35271
|
if (result) {
|
35279
35272
|
const meaning = this._analyzer.resolveMemberAccessExpression(expression).meaning;
|
35280
|
-
result = meaning.kind === "static-field-access" && meaning.
|
35273
|
+
result = meaning.kind === "static-field-access" && meaning.field.value.equals(this.field);
|
35281
35274
|
}
|
35282
35275
|
return result;
|
35283
35276
|
} else {
|
@@ -35352,12 +35345,12 @@ function getReferenceAtNarrowableExpression(analyzer, node) {
|
|
35352
35345
|
if (isNarrowableReferenceExpression(receiverExpression)) {
|
35353
35346
|
const receiver = getReferenceAtNarrowableExpression(analyzer, receiverExpression);
|
35354
35347
|
if (receiver !== void 0) {
|
35355
|
-
return new NarrowableReference.InstanceField(analyzer, meaning.
|
35348
|
+
return new NarrowableReference.InstanceField(analyzer, meaning.field.value, receiver);
|
35356
35349
|
}
|
35357
35350
|
}
|
35358
35351
|
return void 0;
|
35359
35352
|
} else if (meaning.kind === "static-field-access") {
|
35360
|
-
return new NarrowableReference.StaticField(analyzer, meaning.
|
35353
|
+
return new NarrowableReference.StaticField(analyzer, meaning.field.value);
|
35361
35354
|
} else if (meaning.kind === "package-variable-access") {
|
35362
35355
|
return new NarrowableReference.PackageVariable(analyzer, meaning.variable.value);
|
35363
35356
|
}
|
@@ -37362,35 +37355,27 @@ var SemanticContextValidatingNameConflictsBase = class extends SemanticContextWi
|
|
37362
37355
|
return this._memberEntitiesByNameKey;
|
37363
37356
|
}
|
37364
37357
|
validateNestedFunctionsConflicts(entities, sourceFile, diagnostics) {
|
37365
|
-
const functionGroups = [];
|
37366
37358
|
for (const entity of entities) {
|
37367
|
-
|
37368
|
-
|
37369
|
-
|
37370
|
-
|
37371
|
-
|
37372
|
-
|
37373
|
-
|
37374
|
-
|
37375
|
-
|
37376
|
-
|
37377
|
-
|
37378
|
-
|
37379
|
-
|
37380
|
-
|
37381
|
-
|
37382
|
-
|
37383
|
-
if (diagnosticRange !== void 0) {
|
37384
|
-
diagnostics.addDiagnostic(new Diagnostic(diagnosticData, new DiagnosticLocation(diagnosticRange, sourceFile)));
|
37359
|
+
for (const entityToCheckAgainst of entities) {
|
37360
|
+
if (entityToCheckAgainst === entity) {
|
37361
|
+
continue;
|
37362
|
+
}
|
37363
|
+
if (this._analyzer.conflictsCheck.doFunctionSignaturesConflict(entity, entityToCheckAgainst)) {
|
37364
|
+
const diagnosticRange = getDiagnosticRange(entity);
|
37365
|
+
if (diagnosticRange !== void 0) {
|
37366
|
+
const diagnosticData = DiagnosticData.withCode(
|
37367
|
+
296 /* ScopeAlreadyContainsFunctionWithTheSameNameAndParameterTypes */
|
37368
|
+
);
|
37369
|
+
diagnostics.addDiagnostic(new Diagnostic(
|
37370
|
+
diagnosticData,
|
37371
|
+
new DiagnosticLocation(diagnosticRange, sourceFile)
|
37372
|
+
));
|
37373
|
+
}
|
37374
|
+
break;
|
37385
37375
|
}
|
37386
37376
|
}
|
37387
37377
|
}
|
37388
37378
|
}
|
37389
|
-
areNestedFunctionSignaturesEqual(entity1, entity2) {
|
37390
|
-
const valueParameters1 = entity1.getValueParameters();
|
37391
|
-
const valueParameters2 = entity2.getValueParameters();
|
37392
|
-
return valueParameters1.length === valueParameters2.length && Query.from(valueParameters1).zip(valueParameters2, (p1, p2) => p1.getType().equals(p2.getType())).all((v) => v);
|
37393
|
-
}
|
37394
37379
|
createNamedDeclarations() {
|
37395
37380
|
const locale = TreeQuery.fromNode(this.node).projectSourceFile(this._analyzer).package.locale;
|
37396
37381
|
return this.memberEntities.map((e) => {
|
@@ -38283,7 +38268,7 @@ var TypeOrExtensionBodySemanticContext = class extends SemanticContextWithParent
|
|
38283
38268
|
}
|
38284
38269
|
convertNamedMember(member) {
|
38285
38270
|
switch (member.value.kind) {
|
38286
|
-
case "
|
38271
|
+
case "field":
|
38287
38272
|
return member.withValue(new NamedDeclaration_variable(
|
38288
38273
|
new NamedDeclarationVariable_typeMember(member.value)
|
38289
38274
|
));
|
@@ -38408,6 +38393,7 @@ var Analyzer = class _Analyzer {
|
|
38408
38393
|
this.owningPlainObjectModificationCheck = new OwningPlainObjectModificationCheck(this);
|
38409
38394
|
this.packageImports = new PackageImports(this);
|
38410
38395
|
this.typeUtils = new TypeUtils(this);
|
38396
|
+
this.conflictsCheck = new ConflictsCheck(this);
|
38411
38397
|
const systemPackageName = PackageName3.parse("\u0410\u0440\u0442\u0435\u043B\u044C");
|
38412
38398
|
const systemPackage = this.getPackageEntity(systemPackageName);
|
38413
38399
|
if (systemPackage === void 0) {
|
@@ -38612,10 +38598,10 @@ var Analyzer = class _Analyzer {
|
|
38612
38598
|
return result;
|
38613
38599
|
}
|
38614
38600
|
resolveFunctionOverloadByCallExpression(candidates, node) {
|
38615
|
-
return new
|
38601
|
+
return new Resolver6(this).resolveByCallExpression(candidates, node);
|
38616
38602
|
}
|
38617
38603
|
resolveFunctionOverloadByTargetType(candidates, targetType) {
|
38618
|
-
return new
|
38604
|
+
return new Resolver6(this).resolveByTargetType(candidates, targetType);
|
38619
38605
|
}
|
38620
38606
|
resolveConstructorOverload(candidates, args) {
|
38621
38607
|
return new Resolver(this).resolve(candidates, args);
|
@@ -38629,7 +38615,7 @@ var Analyzer = class _Analyzer {
|
|
38629
38615
|
result = void 0;
|
38630
38616
|
}
|
38631
38617
|
if (result === void 0) {
|
38632
|
-
result = new
|
38618
|
+
result = new Resolver9(this, node, targetTypeHint).resolve();
|
38633
38619
|
if (targetTypeHint === void 0 || !result.dependsOnTargetType) {
|
38634
38620
|
this._memberAccessExpressionResolutionResults.set(node, result);
|
38635
38621
|
}
|
@@ -38688,7 +38674,7 @@ var Analyzer = class _Analyzer {
|
|
38688
38674
|
resolveIndexedAccessExpression(node) {
|
38689
38675
|
let result = this._indexedAccessExpressionResolutionResults.get(node);
|
38690
38676
|
if (result === void 0) {
|
38691
|
-
result = new
|
38677
|
+
result = new Resolver8(this, node).resolve();
|
38692
38678
|
this._indexedAccessExpressionResolutionResults.set(node, result);
|
38693
38679
|
}
|
38694
38680
|
return result;
|
@@ -38720,7 +38706,7 @@ var Analyzer = class _Analyzer {
|
|
38720
38706
|
result = void 0;
|
38721
38707
|
}
|
38722
38708
|
if (result === void 0) {
|
38723
|
-
result = new
|
38709
|
+
result = new Resolver7(this, node, targetTypeHint).resolve();
|
38724
38710
|
if (targetTypeHint === void 0 || !result.dependsOnTargetType) {
|
38725
38711
|
this._identifierExpressionResolutionResults.set(node, result);
|
38726
38712
|
}
|
@@ -38738,7 +38724,7 @@ var Analyzer = class _Analyzer {
|
|
38738
38724
|
getObjectExpressionMeaning(node) {
|
38739
38725
|
let result = this._objectExpressionMeanings.get(node);
|
38740
38726
|
if (result === void 0) {
|
38741
|
-
result = new
|
38727
|
+
result = new Resolver10(this, node).resolve();
|
38742
38728
|
this._objectExpressionMeanings.set(node, result);
|
38743
38729
|
}
|
38744
38730
|
return result;
|
@@ -39616,7 +39602,7 @@ var Analyzer = class _Analyzer {
|
|
39616
39602
|
if (!(member.kind === 0 /* Variable */ && isComputedVariableEntity(member))) {
|
39617
39603
|
continue;
|
39618
39604
|
}
|
39619
|
-
if (member.
|
39605
|
+
if (member.markedAbstract()) {
|
39620
39606
|
continue;
|
39621
39607
|
}
|
39622
39608
|
const backingVariableName = member.getName().toBackingVariableName();
|
@@ -39751,7 +39737,7 @@ var Analyzer = class _Analyzer {
|
|
39751
39737
|
return void 0;
|
39752
39738
|
}
|
39753
39739
|
const entity = this.entity.ofMethodDeclaration(node);
|
39754
|
-
if (!entity.
|
39740
|
+
if (!entity.markedBasic()) {
|
39755
39741
|
return void 0;
|
39756
39742
|
}
|
39757
39743
|
const container = entity.getContainer();
|
@@ -39800,7 +39786,7 @@ var Analyzer = class _Analyzer {
|
|
39800
39786
|
Debug.never(meaning);
|
39801
39787
|
}
|
39802
39788
|
const calledFunctionEntity = calledFunction.getEntity();
|
39803
|
-
if (calledFunctionEntity.subkind !== "method" || !
|
39789
|
+
if (calledFunctionEntity.subkind !== "method" || !TypeMemberEntity.isBasic(calledFunctionEntity)) {
|
39804
39790
|
diagnostics?.addDiagnostic(this.createNodeDiagnostic(
|
39805
39791
|
276 /* IncorrectBodyOfBasicAliasTypeMethod */,
|
39806
39792
|
expression
|
@@ -39857,7 +39843,7 @@ var Analyzer = class _Analyzer {
|
|
39857
39843
|
const displayService = new DisplayService(this, lctx);
|
39858
39844
|
const typesText = members.map((d) => {
|
39859
39845
|
switch (d.value.kind) {
|
39860
|
-
case "
|
39846
|
+
case "field": {
|
39861
39847
|
const declaration = new VariableDeclaration_typeMember(d.value, d.localization);
|
39862
39848
|
return displayService.displayVariableDeclaration(declaration);
|
39863
39849
|
}
|
@@ -40476,7 +40462,7 @@ var Type4 = class {
|
|
40476
40462
|
return result;
|
40477
40463
|
}
|
40478
40464
|
case "static-field-access": {
|
40479
|
-
let result = meaning.
|
40465
|
+
let result = meaning.field.value.getType();
|
40480
40466
|
const narrowedType = this.getNarrowedTypeIfNarrowableReference(node, result);
|
40481
40467
|
if (narrowedType !== void 0) {
|
40482
40468
|
result = narrowedType;
|
@@ -40485,7 +40471,7 @@ var Type4 = class {
|
|
40485
40471
|
}
|
40486
40472
|
case "instance-field-access": {
|
40487
40473
|
const declaredType = this._analyzer.includeNoneToTypeIfExpressionValidOutermostOptionalChaining(
|
40488
|
-
meaning.
|
40474
|
+
meaning.field.value.getType(),
|
40489
40475
|
node
|
40490
40476
|
);
|
40491
40477
|
const narrowedType = this.getNarrowedTypeIfNarrowableReference(node, declaredType);
|
@@ -42108,12 +42094,12 @@ var OverriddenMember = class {
|
|
42108
42094
|
constructor(_analyzer) {
|
42109
42095
|
this._analyzer = _analyzer;
|
42110
42096
|
}
|
42111
|
-
|
42097
|
+
getOverriddenFields(node) {
|
42112
42098
|
const entity = node.kind === 54 /* FieldDeclaration */ ? this._analyzer.entity.ofFieldDeclaration(node) : this._analyzer.entity.ofComputedFieldDeclaration(node);
|
42113
42099
|
const result = new Array();
|
42114
42100
|
if (this.entityCanOverride(entity)) {
|
42115
42101
|
for (const lookup of this.enumerateTypeMemberLookupsForOverriddenMember(entity, node)) {
|
42116
|
-
const overriddenMember = this.
|
42102
|
+
const overriddenMember = this.findOverriddenFieldInType(entity, lookup);
|
42117
42103
|
if (overriddenMember !== void 0) {
|
42118
42104
|
this.addTypeMemberIfUnique(result, overriddenMember);
|
42119
42105
|
}
|
@@ -42173,11 +42159,11 @@ var OverriddenMember = class {
|
|
42173
42159
|
}
|
42174
42160
|
return result;
|
42175
42161
|
}
|
42176
|
-
|
42162
|
+
findOverriddenFieldInType(variable, typeMemberLookup) {
|
42177
42163
|
return typeMemberLookup.getNamedMembersByName(new SearchName(
|
42178
42164
|
variable.getName(),
|
42179
42165
|
(variable.getName().flags & 2 /* OriginalName */) !== 0
|
42180
|
-
)).find((m) => m.value.kind === "
|
42166
|
+
)).find((m) => m.value.kind === "field" && this.checkFieldOverridesField(variable, m.value))?.value;
|
42181
42167
|
}
|
42182
42168
|
findOverriddenMethodInType(method, typeMemberLookup) {
|
42183
42169
|
return typeMemberLookup.getNamedMembersByName(new SearchName(method.getName(), (method.getName().flags & 2 /* OriginalName */) !== 0)).find((m) => m.value.kind === "method" && this.checkMethodOverridesMethod(method, m.value))?.value;
|
@@ -42191,8 +42177,8 @@ var OverriddenMember = class {
|
|
42191
42177
|
findOverriddenDereferenceOperatorInType(dereferenceOperator, typeMemberLookup) {
|
42192
42178
|
return typeMemberLookup.getDereferenceOperators().find((m) => this.checkDereferenceOperatorOverridesDereferenceOperator(dereferenceOperator, m.value))?.value;
|
42193
42179
|
}
|
42194
|
-
|
42195
|
-
return this.entityCanBeOverridden(
|
42180
|
+
checkFieldOverridesField(_fieldFromDerivedType, fieldFromBaseType) {
|
42181
|
+
return this.entityCanBeOverridden(fieldFromBaseType.getEntity());
|
42196
42182
|
}
|
42197
42183
|
checkMethodOverridesMethod(methodFromDerivedType, methodFromBaseType) {
|
42198
42184
|
if (!this.entityCanBeOverridden(methodFromBaseType.getEntity())) {
|
@@ -42281,7 +42267,7 @@ var OverriddenMember = class {
|
|
42281
42267
|
if (entity.isStatic()) {
|
42282
42268
|
return false;
|
42283
42269
|
}
|
42284
|
-
if (!entity.
|
42270
|
+
if (!entity.isOverride()) {
|
42285
42271
|
return false;
|
42286
42272
|
}
|
42287
42273
|
const container = entity.getContainer();
|
@@ -42291,14 +42277,7 @@ var OverriddenMember = class {
|
|
42291
42277
|
if (entity.isStatic()) {
|
42292
42278
|
return false;
|
42293
42279
|
}
|
42294
|
-
|
42295
|
-
return true;
|
42296
|
-
}
|
42297
|
-
const baseContainer = entity.getContainer();
|
42298
|
-
if (baseContainer.kind === "type" && baseContainer.typeEntity.typeEntityKind === 1 /* Structured */ && baseContainer.typeEntity.isAspect()) {
|
42299
|
-
return true;
|
42300
|
-
}
|
42301
|
-
return false;
|
42280
|
+
return TypeMemberEntity.isBasic(entity);
|
42302
42281
|
}
|
42303
42282
|
addTypeMemberIfUnique(members, member) {
|
42304
42283
|
for (const existingMember of members) {
|
@@ -42443,7 +42422,7 @@ var LinkedEntity = class {
|
|
42443
42422
|
}
|
42444
42423
|
const containingPackage = getPackageContainingEntity(entity);
|
42445
42424
|
const linkedPackage = this._analyzer.getLinkedMultiPlatformPackage(containingPackage, platform);
|
42446
|
-
return linkedPackage?.getLinkedTypeWithMembers(container.typeEntity)?.
|
42425
|
+
return linkedPackage?.getLinkedTypeWithMembers(container.typeEntity)?.getLinkedField(entity);
|
42447
42426
|
}
|
42448
42427
|
ofMethod(entity, platform) {
|
42449
42428
|
const container = entity.getContainer();
|
@@ -42739,11 +42718,11 @@ var LinkedTypeWithMembers = class {
|
|
42739
42718
|
get memberLookup() {
|
42740
42719
|
return this._memberLookup.getOrInsertWith(() => TypeMemberLookup.ofTypeEntity(this.analyzer, this.targetType, void 0));
|
42741
42720
|
}
|
42742
|
-
|
42721
|
+
getLinkedField(entity) {
|
42743
42722
|
if (entity.getContainer().getEntity() !== this.externalType) {
|
42744
42723
|
return void 0;
|
42745
42724
|
}
|
42746
|
-
return this.memberLookup.getNamedMembersByName(new SearchName(entity.getName(), false)).find((m) => m.value.kind === "
|
42725
|
+
return this.memberLookup.getNamedMembersByName(new SearchName(entity.getName(), false)).find((m) => m.value.kind === "field")?.value.getEntity();
|
42747
42726
|
}
|
42748
42727
|
getLinkedMethod(entity) {
|
42749
42728
|
if (entity.getContainer().getEntity() !== this.externalType) {
|
@@ -42907,7 +42886,7 @@ var OwningPlainObjectModificationCheck = class {
|
|
42907
42886
|
case 78 /* MemberAccessExpression */: {
|
42908
42887
|
const meaning = this._analyzer.resolveMemberAccessExpression(receiver).meaning;
|
42909
42888
|
if (meaning.kind === "instance-field-access") {
|
42910
|
-
const propertyType = meaning.
|
42889
|
+
const propertyType = meaning.field.value.getType();
|
42911
42890
|
if (propertyType.kind === "structured" && propertyType.getEntity().isPlainObject()) {
|
42912
42891
|
result = this.checkReceiverModifiesPlainObjectRecursively(receiver.expression);
|
42913
42892
|
}
|
@@ -43510,6 +43489,138 @@ var TypeUtils = class {
|
|
43510
43489
|
return result;
|
43511
43490
|
}
|
43512
43491
|
};
|
43492
|
+
var ConflictsCheck = class {
|
43493
|
+
constructor(_analyzer) {
|
43494
|
+
this._analyzer = _analyzer;
|
43495
|
+
this._stubParameterTypes = new Array();
|
43496
|
+
}
|
43497
|
+
/**
|
43498
|
+
* Проверяет, конфликтуют ли две функции, т.е. могут ли такие функции находиться в одной области видимости.
|
43499
|
+
* Метод не сравнивает имена.
|
43500
|
+
*
|
43501
|
+
* Отношение "функции конфликтуют" не является транзитивным, т.е. из того, что функция 1 конфликтует с функцией 2 и
|
43502
|
+
* функция 2 конфликтует с функцией 3 не следует, что функция 1 конфликтует с функцией 3.
|
43503
|
+
*
|
43504
|
+
* Пример:
|
43505
|
+
* ```artel
|
43506
|
+
* 1. функция ф<Т1>()
|
43507
|
+
* 2. функция ф<Т1, Т2>()
|
43508
|
+
* 3. функция ф<Т1, Т2 = Объект>()
|
43509
|
+
* ```
|
43510
|
+
*
|
43511
|
+
* Функции 1 и 2 не конфликтуют между собой, поскольку имеют разное количество количество параметров типа, однако
|
43512
|
+
* каждая из них конфликтует с функций 3, которая может принимать от 1 до 2 параметров типа.
|
43513
|
+
*/
|
43514
|
+
doFunctionSignaturesConflict(function1, function2) {
|
43515
|
+
const parameters1 = function1.getValueParameters();
|
43516
|
+
const parameters2 = function2.getValueParameters();
|
43517
|
+
if (parameters1.length !== parameters2.length) {
|
43518
|
+
return false;
|
43519
|
+
}
|
43520
|
+
const typeParameters1 = function1.getTypeParameters();
|
43521
|
+
let substitutionMap1;
|
43522
|
+
if (typeParameters1.length > 0) {
|
43523
|
+
substitutionMap1 = this.createSubstitutionMapWithStubTypes(typeParameters1);
|
43524
|
+
}
|
43525
|
+
const typeParameters2 = function2.getTypeParameters();
|
43526
|
+
let substitutionMap2;
|
43527
|
+
if (typeParameters2.length > 0) {
|
43528
|
+
substitutionMap2 = this.createSubstitutionMapWithStubTypes(typeParameters2);
|
43529
|
+
}
|
43530
|
+
let result = this.doParametersConflict(parameters1, parameters2, substitutionMap1, substitutionMap2);
|
43531
|
+
if (result && typeParameters1.length !== typeParameters2.length) {
|
43532
|
+
result = this.doTypeArgumentCountsIntersect(typeParameters1, typeParameters2);
|
43533
|
+
}
|
43534
|
+
return result;
|
43535
|
+
}
|
43536
|
+
/**
|
43537
|
+
* Проверяет, конфликтуют две сущности, имеющие параметры, но не имеющие параметры типа.
|
43538
|
+
*/
|
43539
|
+
doSignaturesWithoutTypeParametersConflict(entity1, entity2) {
|
43540
|
+
return this.doParametersConflict(entity1.getValueParameters(), entity2.getValueParameters());
|
43541
|
+
}
|
43542
|
+
/**
|
43543
|
+
* Проверяет, конфликтуют ли два типа, т.е. могут ли такие типы находиться в одном пакете. Метод не сравнивает имена.
|
43544
|
+
*
|
43545
|
+
* Отношение "типы конфликтуют" не является транзитивным (см. комментарий у метода
|
43546
|
+
* {@link doFunctionSignaturesConflict}).
|
43547
|
+
*/
|
43548
|
+
doPackageTypesConflict(type1, type2) {
|
43549
|
+
return this.doTypeArgumentCountsIntersect(type1.getTypeParameters(), type2.getTypeParameters());
|
43550
|
+
}
|
43551
|
+
doTypeArgumentCountsIntersect(typeParameters1, typeParameters2) {
|
43552
|
+
const requiredCount1 = getRequiredTypeParameterCount(typeParameters1);
|
43553
|
+
const requiredCount2 = getRequiredTypeParameterCount(typeParameters2);
|
43554
|
+
return requiredCount1 <= typeParameters2.length && requiredCount2 <= typeParameters1.length;
|
43555
|
+
}
|
43556
|
+
doParametersConflict(parameters1, parameters2, substitutionMap1, substitutionMap2) {
|
43557
|
+
if (parameters1.length !== parameters2.length) {
|
43558
|
+
return false;
|
43559
|
+
}
|
43560
|
+
for (let i = 0; i < parameters1.length; i++) {
|
43561
|
+
let type1 = parameters1[i].getType();
|
43562
|
+
if (substitutionMap1 !== void 0) {
|
43563
|
+
type1 = type1.applySubstitutions(substitutionMap1);
|
43564
|
+
}
|
43565
|
+
let type2 = parameters2[i].getType();
|
43566
|
+
if (substitutionMap2 !== void 0) {
|
43567
|
+
type2 = type2.applySubstitutions(substitutionMap2);
|
43568
|
+
}
|
43569
|
+
if (!type1.equals(type2)) {
|
43570
|
+
return false;
|
43571
|
+
}
|
43572
|
+
}
|
43573
|
+
return true;
|
43574
|
+
}
|
43575
|
+
createSubstitutionMapWithStubTypes(typeParameters) {
|
43576
|
+
const count = typeParameters.length;
|
43577
|
+
if (this._stubParameterTypes.length < count) {
|
43578
|
+
for (let i = this._stubParameterTypes.length; i < count; i++) {
|
43579
|
+
this._stubParameterTypes.push(this._analyzer.typeFactory.getParameterType(new StubTypeParameterEntity(), false));
|
43580
|
+
}
|
43581
|
+
}
|
43582
|
+
const substitutions = new Substitutions(
|
43583
|
+
this._analyzer,
|
43584
|
+
typeParameters,
|
43585
|
+
this._stubParameterTypes.slice(0, count)
|
43586
|
+
);
|
43587
|
+
return substitutions.map;
|
43588
|
+
}
|
43589
|
+
};
|
43590
|
+
var StubTypeParameterEntity = class {
|
43591
|
+
constructor() {
|
43592
|
+
this.kind = 2 /* Type */;
|
43593
|
+
this.typeEntityKind = 2 /* Parameter */;
|
43594
|
+
this._constraint = new Cached();
|
43595
|
+
}
|
43596
|
+
getName() {
|
43597
|
+
return new Name("\u0422");
|
43598
|
+
}
|
43599
|
+
getConstraint() {
|
43600
|
+
return this._constraint.getOrInsertWith(() => new TypeParameterConstraint(void 0));
|
43601
|
+
}
|
43602
|
+
getDefaultType() {
|
43603
|
+
return void 0;
|
43604
|
+
}
|
43605
|
+
getDefinition() {
|
43606
|
+
return { kind: 1 /* Intrinsic */ };
|
43607
|
+
}
|
43608
|
+
getArity() {
|
43609
|
+
return 0;
|
43610
|
+
}
|
43611
|
+
getTypeParameters() {
|
43612
|
+
return [];
|
43613
|
+
}
|
43614
|
+
getContainingEntity() {
|
43615
|
+
Debug.unreachable("\u041C\u0435\u0442\u043E\u0434 getContainingEntity \u043D\u0435 \u0434\u043E\u043B\u0436\u0435\u043D \u0432\u044B\u0437\u044B\u0432\u0430\u0442\u044C\u0441\u044F \u043D\u0430 \u0437\u0430\u0433\u043B\u0443\u0448\u043A\u0435 \u043F\u0430\u0440\u0430\u043C\u0435\u0442\u0440\u0430 \u0442\u0438\u043F\u0430.");
|
43616
|
+
}
|
43617
|
+
isHidden() {
|
43618
|
+
return void 0;
|
43619
|
+
}
|
43620
|
+
getTags() {
|
43621
|
+
return [];
|
43622
|
+
}
|
43623
|
+
};
|
43513
43624
|
var ExpressionDenotesFunctionCheckResult = class {
|
43514
43625
|
constructor(candidates, suitableFunctions) {
|
43515
43626
|
this.candidates = candidates;
|
@@ -44397,8 +44508,8 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44397
44508
|
node.creationKeyword
|
44398
44509
|
));
|
44399
44510
|
}
|
44400
|
-
const
|
44401
|
-
if (
|
44511
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44512
|
+
if (overrideModifier !== void 0) {
|
44402
44513
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44403
44514
|
285 /* ConstructorCannotBeDeclaredAsOverridden */,
|
44404
44515
|
node.creationKeyword
|
@@ -44412,15 +44523,15 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44412
44523
|
if (node.block !== void 0) {
|
44413
44524
|
this.checkPossibleGeneratorFunctionReturnType(entity, node.block, node.name);
|
44414
44525
|
const container = entity.getContainer();
|
44415
|
-
if (entity.
|
44526
|
+
if (entity.markedBasic() && container.kind === "type" && container.typeEntity.typeEntityKind === 4 /* Alias */) {
|
44416
44527
|
this._analyzer.checkBodyOfBasicAliasTypeMethod(node, this._diagnosticAcceptor);
|
44417
44528
|
}
|
44418
44529
|
}
|
44419
|
-
const
|
44420
|
-
if (
|
44530
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44531
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44421
44532
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44422
44533
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44423
|
-
|
44534
|
+
overrideModifier
|
44424
44535
|
));
|
44425
44536
|
}
|
44426
44537
|
if (node.typeParameterClause !== void 0) {
|
@@ -44439,11 +44550,11 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44439
44550
|
checkOperatorDeclaration(node) {
|
44440
44551
|
const entity = this._analyzer.entity.ofOperatorDeclaration(node);
|
44441
44552
|
this.checkTypeMemberBodyPresence(entity, node.block, node.name);
|
44442
|
-
const
|
44443
|
-
if (
|
44553
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44554
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44444
44555
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44445
44556
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44446
|
-
|
44557
|
+
overrideModifier
|
44447
44558
|
));
|
44448
44559
|
}
|
44449
44560
|
const staticModifier = findModifier(node, 41 /* Static */);
|
@@ -44530,22 +44641,22 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44530
44641
|
}
|
44531
44642
|
const entity = this._analyzer.entity.ofFieldDeclaration(node);
|
44532
44643
|
entity.ensureAllDiagnosticsReported?.();
|
44533
|
-
const
|
44534
|
-
if (
|
44644
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44645
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44535
44646
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44536
44647
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44537
|
-
|
44648
|
+
overrideModifier
|
44538
44649
|
));
|
44539
44650
|
}
|
44540
44651
|
}
|
44541
44652
|
checkFieldGetterDeclaration(node) {
|
44542
44653
|
const entity = this._analyzer.entity.ofComputedFieldDeclaration(node);
|
44543
44654
|
this.checkTypeMemberBodyPresence(entity, node.block, node.name);
|
44544
|
-
const
|
44545
|
-
if (
|
44655
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44656
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44546
44657
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44547
44658
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44548
|
-
|
44659
|
+
overrideModifier
|
44549
44660
|
));
|
44550
44661
|
}
|
44551
44662
|
this.checkAllCodePathsReturnOrResultVariableIsAssigned(
|
@@ -44558,22 +44669,22 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44558
44669
|
checkFieldSetterDeclaration(node) {
|
44559
44670
|
const entity = this._analyzer.entity.ofComputedFieldDeclaration(node);
|
44560
44671
|
this.checkTypeMemberBodyPresence(entity, node.block, node.name);
|
44561
|
-
const
|
44562
|
-
if (
|
44672
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44673
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44563
44674
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44564
44675
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44565
|
-
|
44676
|
+
overrideModifier
|
44566
44677
|
));
|
44567
44678
|
}
|
44568
44679
|
}
|
44569
44680
|
checkIndexedElementGetterDeclaration(node) {
|
44570
44681
|
const entity = this._analyzer.entity.ofIndexerDeclaration(node);
|
44571
44682
|
this.checkTypeMemberBodyPresence(entity, node.block, node.parameterClause);
|
44572
|
-
const
|
44573
|
-
if (
|
44683
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44684
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44574
44685
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44575
44686
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44576
|
-
|
44687
|
+
overrideModifier
|
44577
44688
|
));
|
44578
44689
|
}
|
44579
44690
|
this._analyzer.semanticContext.ofIndexedElementAccessorDeclarationParameters(node).validateNameConflicts(this._diagnosticAcceptor);
|
@@ -44587,11 +44698,11 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44587
44698
|
checkIndexedElementSetterDeclaration(node) {
|
44588
44699
|
const entity = this._analyzer.entity.ofIndexerDeclaration(node);
|
44589
44700
|
this.checkTypeMemberBodyPresence(entity, node.block, node.parameterClause);
|
44590
|
-
const
|
44591
|
-
if (
|
44701
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44702
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44592
44703
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44593
44704
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44594
|
-
|
44705
|
+
overrideModifier
|
44595
44706
|
));
|
44596
44707
|
}
|
44597
44708
|
this._analyzer.semanticContext.ofIndexedElementAccessorDeclarationParameters(node).validateNameConflicts(this._diagnosticAcceptor);
|
@@ -44599,11 +44710,11 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44599
44710
|
checkDereferencedVariableGetterDeclaration(node) {
|
44600
44711
|
const entity = this._analyzer.entity.ofDereferenceOperatorDeclaration(node);
|
44601
44712
|
this.checkTypeMemberBodyPresence(entity, node.block, node.caretToken);
|
44602
|
-
const
|
44603
|
-
if (
|
44713
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44714
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44604
44715
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44605
44716
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44606
|
-
|
44717
|
+
overrideModifier
|
44607
44718
|
));
|
44608
44719
|
}
|
44609
44720
|
this.checkAllCodePathsReturnOrResultVariableIsAssigned(
|
@@ -44616,11 +44727,11 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44616
44727
|
checkDereferencedVariableSetterDeclaration(node) {
|
44617
44728
|
const entity = this._analyzer.entity.ofDereferenceOperatorDeclaration(node);
|
44618
44729
|
this.checkTypeMemberBodyPresence(entity, node.block, node.caretToken);
|
44619
|
-
const
|
44620
|
-
if (
|
44730
|
+
const overrideModifier = findModifier(node, 39 /* Override */);
|
44731
|
+
if (overrideModifier !== void 0 && entity.getOverriddenMembers().length === 0) {
|
44621
44732
|
this.addDiagnostic(this._analyzer.createNodeDiagnostic(
|
44622
44733
|
283 /* CorrespondingBasicTypeMemberNotFound */,
|
44623
|
-
|
44734
|
+
overrideModifier
|
44624
44735
|
));
|
44625
44736
|
}
|
44626
44737
|
}
|
@@ -44798,14 +44909,14 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44798
44909
|
if (findTag(this._analyzer.wellKnownDeclarations.builtIntoPlatform, entity.getTags()) !== void 0) {
|
44799
44910
|
return 3 /* DoesNotRequireBecauseHasBuiltIntoPlatformTag */;
|
44800
44911
|
}
|
44801
|
-
if (
|
44912
|
+
if (TypeMemberEntity.isStatic(entity)) {
|
44802
44913
|
return 5 /* RequiresBecauseIsStaticMember */;
|
44803
44914
|
}
|
44804
|
-
|
44805
|
-
if (entity.isAbstract() && !isAspectTypeMember) {
|
44915
|
+
if (entity.markedAbstract()) {
|
44806
44916
|
return 1 /* DoesNotRequireBecauseIsAbstract */;
|
44807
44917
|
}
|
44808
|
-
|
44918
|
+
const isAspectTypeMember = TypeMemberEntity.isAspectTypeMember(entity);
|
44919
|
+
if (TypeMemberEntity.markedBasic(entity) && isAspectTypeMember) {
|
44809
44920
|
return 4 /* RequiresBecauseIsBasicAspectTypeMember */;
|
44810
44921
|
}
|
44811
44922
|
if (isAspectTypeMember) {
|
@@ -44813,27 +44924,6 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
44813
44924
|
}
|
44814
44925
|
return 6 /* RequiresBecauseIsRegularMember */;
|
44815
44926
|
}
|
44816
|
-
// TODO: заменить на entity.isBasic().
|
44817
|
-
isBasicEntity(entity) {
|
44818
|
-
switch (entity.kind) {
|
44819
|
-
case 0 /* Variable */:
|
44820
|
-
return entity.isBasic();
|
44821
|
-
case 1 /* Function */:
|
44822
|
-
return entity.isBasic();
|
44823
|
-
case 5 /* Indexer */:
|
44824
|
-
return entity.isBasic();
|
44825
|
-
case 6 /* DereferenceOperator */:
|
44826
|
-
return entity.isBasic();
|
44827
|
-
case 9 /* Operator */:
|
44828
|
-
return entity.isBasic();
|
44829
|
-
case 7 /* Constructor */:
|
44830
|
-
return false;
|
44831
|
-
case 8 /* Destructor */:
|
44832
|
-
return false;
|
44833
|
-
default:
|
44834
|
-
Debug.never(entity);
|
44835
|
-
}
|
44836
|
-
}
|
44837
44927
|
// TODO: учесть константы времени компиляции.
|
44838
44928
|
// private validateVariantInitializer(expression: tree.Expression): void {
|
44839
44929
|
// if (expression.kind === tree.NodeKind.TokenExpression) {
|
@@ -45134,12 +45224,12 @@ var DiagnosticCollector = class _DiagnosticCollector {
|
|
45134
45224
|
break;
|
45135
45225
|
}
|
45136
45226
|
case "static-field-access": {
|
45137
|
-
this.checkAssignmentToField(meaning.
|
45227
|
+
this.checkAssignmentToField(meaning.field.value.getEntity(), statement, node.propertyName, node);
|
45138
45228
|
this.checkOptionalChainingIsUsedOnTheLeftSideOfAssignment(statement.left);
|
45139
45229
|
break;
|
45140
45230
|
}
|
45141
45231
|
case "instance-field-access": {
|
45142
|
-
this.checkAssignmentToField(meaning.
|
45232
|
+
this.checkAssignmentToField(meaning.field.value.getEntity(), statement, node.propertyName, node);
|
45143
45233
|
this.checkOptionalChainingIsUsedOnTheLeftSideOfAssignment(statement.left);
|
45144
45234
|
break;
|
45145
45235
|
}
|
@@ -45647,8 +45737,8 @@ function modifierToModifierFlag(modifier) {
|
|
45647
45737
|
return 1024 /* Const */;
|
45648
45738
|
case 38 /* Abstract */:
|
45649
45739
|
return 128 /* Abstract */;
|
45650
|
-
case 39 /*
|
45651
|
-
return 256 /*
|
45740
|
+
case 39 /* Override */:
|
45741
|
+
return 256 /* Override */;
|
45652
45742
|
case 40 /* Async */:
|
45653
45743
|
return 512 /* Async */;
|
45654
45744
|
case 41 /* Static */:
|
@@ -45886,7 +45976,10 @@ var PackageAliasTypeDeclarationEntity = class {
|
|
45886
45976
|
this._modifierFlags = 2048 /* NotComputed */;
|
45887
45977
|
}
|
45888
45978
|
get modifierFlags() {
|
45889
|
-
|
45979
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
45980
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
45981
|
+
}
|
45982
|
+
return this._modifierFlags;
|
45890
45983
|
}
|
45891
45984
|
getName() {
|
45892
45985
|
return this._analyzer.createNameFromIdentifier(this._node.name);
|
@@ -45979,7 +46072,10 @@ var ConstructorDeclarationEntity = class {
|
|
45979
46072
|
this._modifierFlags = 2048 /* NotComputed */;
|
45980
46073
|
}
|
45981
46074
|
get modifierFlags() {
|
45982
|
-
|
46075
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46076
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
46077
|
+
}
|
46078
|
+
return this._modifierFlags;
|
45983
46079
|
}
|
45984
46080
|
getValueParameters() {
|
45985
46081
|
return this._valueParameters.getOrInsertWith(
|
@@ -45998,13 +46094,8 @@ var ConstructorDeclarationEntity = class {
|
|
45998
46094
|
isHidden() {
|
45999
46095
|
return this._analyzer.createTypeMemberHiding(this._node, this.modifierFlags);
|
46000
46096
|
}
|
46001
|
-
|
46002
|
-
|
46003
|
-
if (!result && this._node.block === void 0) {
|
46004
|
-
const container = this.getContainer();
|
46005
|
-
result = container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
46006
|
-
}
|
46007
|
-
return result;
|
46097
|
+
markedAbstract() {
|
46098
|
+
return (this.modifierFlags & 128 /* Abstract */) !== 0;
|
46008
46099
|
}
|
46009
46100
|
getTags() {
|
46010
46101
|
return this._analyzer.tags.ofTagList(this._node.tagList);
|
@@ -46014,12 +46105,12 @@ ConstructorDeclarationEntity = __decorateClass([
|
|
46014
46105
|
entityToStringDecorator
|
46015
46106
|
], ConstructorDeclarationEntity);
|
46016
46107
|
var IntrinsicConstructorEntity = class {
|
46017
|
-
constructor(_valueParameters, _containingEntity, _isDefault, _isHidden,
|
46108
|
+
constructor(_valueParameters, _containingEntity, _isDefault, _isHidden, _markedAbstract) {
|
46018
46109
|
this._valueParameters = _valueParameters;
|
46019
46110
|
this._containingEntity = _containingEntity;
|
46020
46111
|
this._isDefault = _isDefault;
|
46021
46112
|
this._isHidden = _isHidden;
|
46022
|
-
this.
|
46113
|
+
this._markedAbstract = _markedAbstract;
|
46023
46114
|
this.kind = 7 /* Constructor */;
|
46024
46115
|
}
|
46025
46116
|
getValueParameters() {
|
@@ -46037,8 +46128,8 @@ var IntrinsicConstructorEntity = class {
|
|
46037
46128
|
isHidden() {
|
46038
46129
|
return this._isHidden;
|
46039
46130
|
}
|
46040
|
-
|
46041
|
-
return this.
|
46131
|
+
markedAbstract() {
|
46132
|
+
return this._markedAbstract;
|
46042
46133
|
}
|
46043
46134
|
getTags() {
|
46044
46135
|
return [];
|
@@ -46078,7 +46169,7 @@ var DefaultConstructorEntity = class {
|
|
46078
46169
|
isHidden() {
|
46079
46170
|
return void 0;
|
46080
46171
|
}
|
46081
|
-
|
46172
|
+
markedAbstract() {
|
46082
46173
|
return false;
|
46083
46174
|
}
|
46084
46175
|
getTags() {
|
@@ -46168,7 +46259,10 @@ var DereferenceOperatorDeclarationEntity = class {
|
|
46168
46259
|
}
|
46169
46260
|
}
|
46170
46261
|
get modifierFlags() {
|
46171
|
-
|
46262
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46263
|
+
this._modifierFlags = createDeclaredModifierFlags(this._getterOrSetterDeclaration);
|
46264
|
+
}
|
46265
|
+
return this._modifierFlags;
|
46172
46266
|
}
|
46173
46267
|
getType() {
|
46174
46268
|
if (this._getterDeclaration !== void 0) {
|
@@ -46202,19 +46296,14 @@ var DereferenceOperatorDeclarationEntity = class {
|
|
46202
46296
|
const getterEntity = this.getGetter();
|
46203
46297
|
return getterEntity !== void 0 ? getterEntity.isHidden() : this.getSetter()?.isHidden();
|
46204
46298
|
}
|
46205
|
-
|
46299
|
+
markedBasic() {
|
46206
46300
|
return (this.modifierFlags & 32 /* Basic */) !== 0;
|
46207
46301
|
}
|
46208
|
-
|
46209
|
-
return (this.modifierFlags & 256 /*
|
46302
|
+
isOverride() {
|
46303
|
+
return (this.modifierFlags & 256 /* Override */) !== 0;
|
46210
46304
|
}
|
46211
|
-
|
46212
|
-
|
46213
|
-
if (!result && this._getterOrSetterDeclaration.block === void 0) {
|
46214
|
-
const container = this.getContainer();
|
46215
|
-
result = container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
46216
|
-
}
|
46217
|
-
return result;
|
46305
|
+
markedAbstract() {
|
46306
|
+
return (this.modifierFlags & 128 /* Abstract */) !== 0;
|
46218
46307
|
}
|
46219
46308
|
getTags() {
|
46220
46309
|
return this.getGetter()?.getTags() ?? [];
|
@@ -46237,7 +46326,10 @@ var DestructorDeclarationEntity = class {
|
|
46237
46326
|
this._modifierFlags = 2048 /* NotComputed */;
|
46238
46327
|
}
|
46239
46328
|
get modifierFlags() {
|
46240
|
-
|
46329
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46330
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
46331
|
+
}
|
46332
|
+
return this._modifierFlags;
|
46241
46333
|
}
|
46242
46334
|
getValueParameters() {
|
46243
46335
|
return this._valueParameters.getOrInsertWith(
|
@@ -46253,13 +46345,8 @@ var DestructorDeclarationEntity = class {
|
|
46253
46345
|
isHidden() {
|
46254
46346
|
return this._analyzer.createTypeMemberHiding(this._node, this.modifierFlags);
|
46255
46347
|
}
|
46256
|
-
|
46257
|
-
|
46258
|
-
if (!result && this._node.block === void 0) {
|
46259
|
-
const container = this.getContainer();
|
46260
|
-
result = container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
46261
|
-
}
|
46262
|
-
return result;
|
46348
|
+
markedAbstract() {
|
46349
|
+
return (this.modifierFlags & 128 /* Abstract */) !== 0;
|
46263
46350
|
}
|
46264
46351
|
getTags() {
|
46265
46352
|
return this._analyzer.tags.ofTagList(this._node.tagList);
|
@@ -46323,7 +46410,10 @@ var PackageVariableGetterDeclarationEntity = class {
|
|
46323
46410
|
this._modifierFlags = 2048 /* NotComputed */;
|
46324
46411
|
}
|
46325
46412
|
get modifierFlags() {
|
46326
|
-
|
46413
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46414
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
46415
|
+
}
|
46416
|
+
return this._modifierFlags;
|
46327
46417
|
}
|
46328
46418
|
getReturnType() {
|
46329
46419
|
return this._analyzer.entity.ofComputedPackageVariableDeclaration(this._node).getType();
|
@@ -46355,7 +46445,10 @@ var FieldGetterDeclarationEntity = class {
|
|
46355
46445
|
this._modifierFlags = 2048 /* NotComputed */;
|
46356
46446
|
}
|
46357
46447
|
get modifierFlags() {
|
46358
|
-
|
46448
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46449
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
46450
|
+
}
|
46451
|
+
return this._modifierFlags;
|
46359
46452
|
}
|
46360
46453
|
getReturnType() {
|
46361
46454
|
return this._analyzer.entity.ofComputedFieldDeclaration(this._node).getType();
|
@@ -46387,7 +46480,10 @@ var IndexedElementGetterDeclarationEntity = class {
|
|
46387
46480
|
this._modifierFlags = 2048 /* NotComputed */;
|
46388
46481
|
}
|
46389
46482
|
get modifierFlags() {
|
46390
|
-
|
46483
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46484
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
46485
|
+
}
|
46486
|
+
return this._modifierFlags;
|
46391
46487
|
}
|
46392
46488
|
getReturnType() {
|
46393
46489
|
return this._analyzer.entity.ofIndexerDeclaration(this._node).getType();
|
@@ -46419,7 +46515,10 @@ var DereferencedVariableGetterDeclarationEntity = class {
|
|
46419
46515
|
this._modifierFlags = 2048 /* NotComputed */;
|
46420
46516
|
}
|
46421
46517
|
get modifierFlags() {
|
46422
|
-
|
46518
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46519
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
46520
|
+
}
|
46521
|
+
return this._modifierFlags;
|
46423
46522
|
}
|
46424
46523
|
getReturnType() {
|
46425
46524
|
return this._analyzer.entity.ofDereferenceOperatorDeclaration(this._node).getType();
|
@@ -46496,7 +46595,10 @@ var IndexerDeclarationEntity = class {
|
|
46496
46595
|
return this._parameters.getOrInsertWith(() => this.createParameters());
|
46497
46596
|
}
|
46498
46597
|
get modifierFlags() {
|
46499
|
-
|
46598
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46599
|
+
this._modifierFlags = createDeclaredModifierFlags(this._getterOrSetterDeclaration);
|
46600
|
+
}
|
46601
|
+
return this._modifierFlags;
|
46500
46602
|
}
|
46501
46603
|
getParameter(node) {
|
46502
46604
|
const entityByNode = this.parameters.entityByNode;
|
@@ -46539,19 +46641,14 @@ var IndexerDeclarationEntity = class {
|
|
46539
46641
|
const getterEntity = this.getGetter();
|
46540
46642
|
return getterEntity !== void 0 ? getterEntity.isHidden() : this.getSetter()?.isHidden();
|
46541
46643
|
}
|
46542
|
-
|
46644
|
+
markedBasic() {
|
46543
46645
|
return (this.modifierFlags & 32 /* Basic */) !== 0;
|
46544
46646
|
}
|
46545
|
-
|
46546
|
-
return (this.modifierFlags & 256 /*
|
46647
|
+
isOverride() {
|
46648
|
+
return (this.modifierFlags & 256 /* Override */) !== 0;
|
46547
46649
|
}
|
46548
|
-
|
46549
|
-
|
46550
|
-
if (!result && this._getterOrSetterDeclaration.block === void 0) {
|
46551
|
-
const container = this.getContainer();
|
46552
|
-
result = container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
46553
|
-
}
|
46554
|
-
return result;
|
46650
|
+
markedAbstract() {
|
46651
|
+
return (this.modifierFlags & 128 /* Abstract */) !== 0;
|
46555
46652
|
}
|
46556
46653
|
getTags() {
|
46557
46654
|
return this.getGetter()?.getTags() ?? [];
|
@@ -46590,7 +46687,10 @@ var PackageFunctionDeclarationEntity = class {
|
|
46590
46687
|
this._modifierFlags = 2048 /* NotComputed */;
|
46591
46688
|
}
|
46592
46689
|
get modifierFlags() {
|
46593
|
-
|
46690
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46691
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
46692
|
+
}
|
46693
|
+
return this._modifierFlags;
|
46594
46694
|
}
|
46595
46695
|
getName() {
|
46596
46696
|
return this._analyzer.createNameFromIdentifier(this._node.name);
|
@@ -46648,7 +46748,10 @@ var MethodDeclarationEntity = class {
|
|
46648
46748
|
this._modifierFlags = 2048 /* NotComputed */;
|
46649
46749
|
}
|
46650
46750
|
get modifierFlags() {
|
46651
|
-
|
46751
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
46752
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
46753
|
+
}
|
46754
|
+
return this._modifierFlags;
|
46652
46755
|
}
|
46653
46756
|
getName() {
|
46654
46757
|
return this._analyzer.createNameFromIdentifier(this._node.name);
|
@@ -46693,19 +46796,14 @@ var MethodDeclarationEntity = class {
|
|
46693
46796
|
isStatic() {
|
46694
46797
|
return (this.modifierFlags & 64 /* Static */) !== 0;
|
46695
46798
|
}
|
46696
|
-
|
46799
|
+
markedBasic() {
|
46697
46800
|
return (this.modifierFlags & 32 /* Basic */) !== 0;
|
46698
46801
|
}
|
46699
|
-
|
46700
|
-
return (this.modifierFlags & 256 /*
|
46802
|
+
isOverride() {
|
46803
|
+
return (this.modifierFlags & 256 /* Override */) !== 0;
|
46701
46804
|
}
|
46702
|
-
|
46703
|
-
|
46704
|
-
if (!result && this._node.block === void 0) {
|
46705
|
-
const container = this.getContainer();
|
46706
|
-
result = container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
46707
|
-
}
|
46708
|
-
return result;
|
46805
|
+
markedAbstract() {
|
46806
|
+
return (this.modifierFlags & 128 /* Abstract */) !== 0;
|
46709
46807
|
}
|
46710
46808
|
isModifyingOwningPlainObject() {
|
46711
46809
|
return this._node.block !== void 0 ? this._analyzer.owningPlainObjectModificationCheck.ofDeclarationBody(this._node.block) : false;
|
@@ -46824,7 +46922,7 @@ IntrinsicPackageFunctionEntity = __decorateClass([
|
|
46824
46922
|
entityToStringDecorator
|
46825
46923
|
], IntrinsicPackageFunctionEntity);
|
46826
46924
|
var IntrinsicMethodEntity = class {
|
46827
|
-
constructor(_name, _typeParameters, _valueParameters, _returnType, _isAsync, _isHidden, _tags, _isFunctionTypeInvokeMethod, _container, _isStatic, _isBasic,
|
46925
|
+
constructor(_name, _typeParameters, _valueParameters, _returnType, _isAsync, _isHidden, _tags, _isFunctionTypeInvokeMethod, _container, _isStatic, _isBasic, _isOverride, _isAbstract, _isModifyingOwningPlainObject, _overriddenMembers) {
|
46828
46926
|
this._name = _name;
|
46829
46927
|
this._typeParameters = _typeParameters;
|
46830
46928
|
this._valueParameters = _valueParameters;
|
@@ -46836,7 +46934,7 @@ var IntrinsicMethodEntity = class {
|
|
46836
46934
|
this._container = _container;
|
46837
46935
|
this._isStatic = _isStatic;
|
46838
46936
|
this._isBasic = _isBasic;
|
46839
|
-
this.
|
46937
|
+
this._isOverride = _isOverride;
|
46840
46938
|
this._isAbstract = _isAbstract;
|
46841
46939
|
this._isModifyingOwningPlainObject = _isModifyingOwningPlainObject;
|
46842
46940
|
this._overriddenMembers = _overriddenMembers;
|
@@ -46879,13 +46977,13 @@ var IntrinsicMethodEntity = class {
|
|
46879
46977
|
isStatic() {
|
46880
46978
|
return this._isStatic;
|
46881
46979
|
}
|
46882
|
-
|
46980
|
+
markedBasic() {
|
46883
46981
|
return this._isBasic;
|
46884
46982
|
}
|
46885
|
-
|
46886
|
-
return this.
|
46983
|
+
isOverride() {
|
46984
|
+
return this._isOverride;
|
46887
46985
|
}
|
46888
|
-
|
46986
|
+
markedAbstract() {
|
46889
46987
|
return this._isAbstract;
|
46890
46988
|
}
|
46891
46989
|
isModifyingOwningPlainObject() {
|
@@ -46917,7 +47015,10 @@ var PackageFunctionTypeDeclarationEntity = class {
|
|
46917
47015
|
this._modifierFlags = 2048 /* NotComputed */;
|
46918
47016
|
}
|
46919
47017
|
get modifierFlags() {
|
46920
|
-
|
47018
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
47019
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
47020
|
+
}
|
47021
|
+
return this._modifierFlags;
|
46921
47022
|
}
|
46922
47023
|
getNaming() {
|
46923
47024
|
return new EntityNaming_named(this.getName());
|
@@ -47249,7 +47350,10 @@ var OperatorDeclarationEntity = class {
|
|
47249
47350
|
);
|
47250
47351
|
}
|
47251
47352
|
get modifierFlags() {
|
47252
|
-
|
47353
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
47354
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
47355
|
+
}
|
47356
|
+
return this._modifierFlags;
|
47253
47357
|
}
|
47254
47358
|
getOperatorKind() {
|
47255
47359
|
return this._operatorKind;
|
@@ -47272,19 +47376,14 @@ var OperatorDeclarationEntity = class {
|
|
47272
47376
|
isStatic() {
|
47273
47377
|
return (this.modifierFlags & 64 /* Static */) !== 0;
|
47274
47378
|
}
|
47275
|
-
|
47379
|
+
markedBasic() {
|
47276
47380
|
return (this.modifierFlags & 32 /* Basic */) !== 0;
|
47277
47381
|
}
|
47278
|
-
|
47279
|
-
return (this.modifierFlags & 256 /*
|
47382
|
+
isOverride() {
|
47383
|
+
return (this.modifierFlags & 256 /* Override */) !== 0;
|
47280
47384
|
}
|
47281
|
-
|
47282
|
-
|
47283
|
-
if (!result && this._node.block === void 0) {
|
47284
|
-
const container = this.getContainer();
|
47285
|
-
result = container.kind === "type" && container.typeEntity.typeEntityKind === 1 /* Structured */ && container.typeEntity.isAspect();
|
47286
|
-
}
|
47287
|
-
return result;
|
47385
|
+
markedAbstract() {
|
47386
|
+
return (this.modifierFlags & 128 /* Abstract */) !== 0;
|
47288
47387
|
}
|
47289
47388
|
isHidden() {
|
47290
47389
|
return this._analyzer.createTypeMemberHiding(this._node, this.modifierFlags);
|
@@ -47496,7 +47595,10 @@ var PackageVariableSetterDeclarationEntity = class {
|
|
47496
47595
|
this._modifierFlags = 2048 /* NotComputed */;
|
47497
47596
|
}
|
47498
47597
|
get modifierFlags() {
|
47499
|
-
|
47598
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
47599
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
47600
|
+
}
|
47601
|
+
return this._modifierFlags;
|
47500
47602
|
}
|
47501
47603
|
getDefinition() {
|
47502
47604
|
return { kind: 0 /* Source */, node: this._node };
|
@@ -47525,7 +47627,10 @@ var FieldSetterDeclarationEntity = class {
|
|
47525
47627
|
this._modifierFlags = 2048 /* NotComputed */;
|
47526
47628
|
}
|
47527
47629
|
get modifierFlags() {
|
47528
|
-
|
47630
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
47631
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
47632
|
+
}
|
47633
|
+
return this._modifierFlags;
|
47529
47634
|
}
|
47530
47635
|
getDefinition() {
|
47531
47636
|
return { kind: 0 /* Source */, node: this._node };
|
@@ -47554,7 +47659,10 @@ var IndexedElementSetterDeclarationEntity = class {
|
|
47554
47659
|
this._modifierFlags = 2048 /* NotComputed */;
|
47555
47660
|
}
|
47556
47661
|
get modifierFlags() {
|
47557
|
-
|
47662
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
47663
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
47664
|
+
}
|
47665
|
+
return this._modifierFlags;
|
47558
47666
|
}
|
47559
47667
|
getDefinition() {
|
47560
47668
|
return { kind: 0 /* Source */, node: this._node };
|
@@ -47583,7 +47691,10 @@ var DereferencedVariableSetterDeclarationEntity = class {
|
|
47583
47691
|
this._modifierFlags = 2048 /* NotComputed */;
|
47584
47692
|
}
|
47585
47693
|
get modifierFlags() {
|
47586
|
-
|
47694
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
47695
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
47696
|
+
}
|
47697
|
+
return this._modifierFlags;
|
47587
47698
|
}
|
47588
47699
|
getDefinition() {
|
47589
47700
|
return { kind: 0 /* Source */, node: this._node };
|
@@ -47844,7 +47955,10 @@ var SourcePackageStructuredTypeDeclarationData = class {
|
|
47844
47955
|
this._entity = entity;
|
47845
47956
|
}
|
47846
47957
|
get modifierFlags() {
|
47847
|
-
|
47958
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
47959
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
47960
|
+
}
|
47961
|
+
return this._modifierFlags;
|
47848
47962
|
}
|
47849
47963
|
getNaming() {
|
47850
47964
|
return new EntityNaming_named(this.getName());
|
@@ -48280,7 +48394,10 @@ var SourceTypeExtensionEntity = class {
|
|
48280
48394
|
this._node = node;
|
48281
48395
|
}
|
48282
48396
|
get modifierFlags() {
|
48283
|
-
|
48397
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
48398
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
48399
|
+
}
|
48400
|
+
return this._modifierFlags;
|
48284
48401
|
}
|
48285
48402
|
getMembers() {
|
48286
48403
|
return this._members.getOrInsertWith(() => {
|
@@ -48613,7 +48730,10 @@ var PackageVariantTypeDeclarationEntity = class {
|
|
48613
48730
|
this._modifierFlags = 2048 /* NotComputed */;
|
48614
48731
|
}
|
48615
48732
|
get modifierFlags() {
|
48616
|
-
|
48733
|
+
if (this._modifierFlags === 2048 /* NotComputed */) {
|
48734
|
+
this._modifierFlags = createDeclaredModifierFlags(this._node);
|
48735
|
+
}
|
48736
|
+
return this._modifierFlags;
|
48617
48737
|
}
|
48618
48738
|
getNaming() {
|
48619
48739
|
return new EntityNaming_named(this.getName());
|
@@ -48907,7 +49027,7 @@ function isTypeMemberEntity(entity) {
|
|
48907
49027
|
return false;
|
48908
49028
|
}
|
48909
49029
|
}
|
48910
|
-
var
|
49030
|
+
var TypeMemberEntity;
|
48911
49031
|
((TypeMemberEntity6) => {
|
48912
49032
|
function isAspectTypeMember(entity) {
|
48913
49033
|
const container = entity.getContainer();
|
@@ -48917,13 +49037,9 @@ var TypeMemberEntity2;
|
|
48917
49037
|
function isStatic(entity) {
|
48918
49038
|
switch (entity.kind) {
|
48919
49039
|
case 0 /* Variable */:
|
48920
|
-
return entity.isStatic();
|
48921
49040
|
case 1 /* Function */:
|
48922
|
-
return entity.isStatic();
|
48923
49041
|
case 5 /* Indexer */:
|
48924
|
-
return entity.isStatic();
|
48925
49042
|
case 6 /* DereferenceOperator */:
|
48926
|
-
return entity.isStatic();
|
48927
49043
|
case 9 /* Operator */:
|
48928
49044
|
return entity.isStatic();
|
48929
49045
|
case 8 /* Destructor */:
|
@@ -48934,7 +49050,43 @@ var TypeMemberEntity2;
|
|
48934
49050
|
}
|
48935
49051
|
}
|
48936
49052
|
TypeMemberEntity6.isStatic = isStatic;
|
48937
|
-
|
49053
|
+
function markedBasic(entity) {
|
49054
|
+
switch (entity.kind) {
|
49055
|
+
case 0 /* Variable */:
|
49056
|
+
case 1 /* Function */:
|
49057
|
+
case 5 /* Indexer */:
|
49058
|
+
case 6 /* DereferenceOperator */:
|
49059
|
+
case 9 /* Operator */:
|
49060
|
+
return entity.markedBasic();
|
49061
|
+
case 8 /* Destructor */:
|
49062
|
+
case 7 /* Constructor */:
|
49063
|
+
return false;
|
49064
|
+
default:
|
49065
|
+
Debug.never(entity);
|
49066
|
+
}
|
49067
|
+
}
|
49068
|
+
TypeMemberEntity6.markedBasic = markedBasic;
|
49069
|
+
function isBasic(entity) {
|
49070
|
+
switch (entity.kind) {
|
49071
|
+
case 0 /* Variable */:
|
49072
|
+
case 1 /* Function */:
|
49073
|
+
case 5 /* Indexer */:
|
49074
|
+
case 6 /* DereferenceOperator */:
|
49075
|
+
case 9 /* Operator */:
|
49076
|
+
return !isStatic(entity) && (entity.markedBasic() || entity.markedAbstract() || entity.isOverride() || isAspectTypeMember(entity));
|
49077
|
+
case 8 /* Destructor */:
|
49078
|
+
case 7 /* Constructor */:
|
49079
|
+
return false;
|
49080
|
+
default:
|
49081
|
+
Debug.never(entity);
|
49082
|
+
}
|
49083
|
+
}
|
49084
|
+
TypeMemberEntity6.isBasic = isBasic;
|
49085
|
+
function isAbstract(entity) {
|
49086
|
+
return entity.markedAbstract() || isAspectTypeMember(entity) && !markedBasic(entity) && !isStatic(entity);
|
49087
|
+
}
|
49088
|
+
TypeMemberEntity6.isAbstract = isAbstract;
|
49089
|
+
})(TypeMemberEntity || (TypeMemberEntity = {}));
|
48938
49090
|
function entityToStringDecorator(constructor) {
|
48939
49091
|
if (!("debuggerDisplay" in constructor.prototype)) {
|
48940
49092
|
Object.defineProperty(constructor.prototype, "debuggerDisplay", {
|
@@ -49441,9 +49593,9 @@ var TypeOrExtensionEntityDetails = class {
|
|
49441
49593
|
this.aliasedType = void 0;
|
49442
49594
|
this.isDefaultExport = false;
|
49443
49595
|
/**
|
49444
|
-
* Является ли имя члена типа вычисляемым (`details.hasComputedName`) может зависеть от
|
49596
|
+
* Является ли имя члена типа вычисляемым (`details.hasComputedName`) может зависеть от переопределённых членов типа.
|
49445
49597
|
* Если `areOwnComputedNamesOfMembersResolved` === `true`, поля `details.hasComputedName` членов типа хранят
|
49446
|
-
* актуальную для них самих информацию, и анализ
|
49598
|
+
* актуальную для них самих информацию, и анализ переопределённых членов типа не требуется.
|
49447
49599
|
*/
|
49448
49600
|
this.areOwnComputedNamesOfMembersResolved = false;
|
49449
49601
|
}
|
@@ -50096,7 +50248,7 @@ var OrderedArguments = class _OrderedArguments {
|
|
50096
50248
|
return new _OrderedArguments(this.values.map((p) => p.clone()), this.isLastArgumentSpreading, this.sourceLocation);
|
50097
50249
|
}
|
50098
50250
|
};
|
50099
|
-
var
|
50251
|
+
var CallExpression5 = class _CallExpression {
|
50100
50252
|
constructor(expression, isOptionalAccess, args, isAsyncFunctionCall, returnType, sourceLocation, options = CallExpressionEmitOptions.default()) {
|
50101
50253
|
this.expression = expression;
|
50102
50254
|
this.isOptionalAccess = isOptionalAccess;
|
@@ -51645,8 +51797,8 @@ var EntityMap = class {
|
|
51645
51797
|
const originalContainingEntity = entity.getContainer().getEntity();
|
51646
51798
|
result.ifTypeMemberThenContainingType = this.getTypeOrExtensionEntity(originalContainingEntity);
|
51647
51799
|
result.details.isStatic = entity.isStatic();
|
51648
|
-
result.details.isAbstract =
|
51649
|
-
result.details.isBasic =
|
51800
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(entity);
|
51801
|
+
result.details.isBasic = TypeMemberEntity.isBasic(entity);
|
51650
51802
|
result.details.overriddenMembers = entity.getOverriddenMembers().map((m) => this.getVariableEntity(m.getEntity()));
|
51651
51803
|
const proxyTag = entity.getTags().find((t) => t.kind === "type" && this._analyzer.checkTypeIsBasedOnAspect(t.type, this._analyzer.wellKnownDeclarations.fieldProxy));
|
51652
51804
|
if (proxyTag !== void 0) {
|
@@ -51657,8 +51809,6 @@ var EntityMap = class {
|
|
51657
51809
|
constructor: this.getConstructorEntity(proxyTag.constructor_.getEntity())
|
51658
51810
|
};
|
51659
51811
|
}
|
51660
|
-
result.details.isBasic = entity.isBasic();
|
51661
|
-
result.details.isAbstract = entity.isAbstract();
|
51662
51812
|
}
|
51663
51813
|
const getter = entity.getGetter();
|
51664
51814
|
if (getter !== void 0) {
|
@@ -51698,10 +51848,10 @@ var EntityMap = class {
|
|
51698
51848
|
} else if (entity.subkind === "method") {
|
51699
51849
|
result.ifTypeMemberThenContainingType = this.getTypeOrExtensionEntity(entity.getContainer().getEntity());
|
51700
51850
|
result.details.isStatic = entity.isStatic();
|
51701
|
-
result.details.isAbstract =
|
51702
|
-
result.details.isBasic =
|
51851
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(entity);
|
51852
|
+
result.details.isBasic = TypeMemberEntity.isBasic(entity);
|
51703
51853
|
result.details.overriddenMembers = entity.getOverriddenMembers().map((m) => this.getFunctionEntity(m.getEntity()));
|
51704
|
-
if (result.ifTypeMemberThenContainingType.typeOrExtensionKind === 1 /* AliasType */ && entity.
|
51854
|
+
if (result.ifTypeMemberThenContainingType.typeOrExtensionKind === 1 /* AliasType */ && entity.markedBasic()) {
|
51705
51855
|
const realBasicMethod = this._analyzer.getBasicMethodOfOriginalTypeForBasicMethodOfAliasType(entity);
|
51706
51856
|
if (realBasicMethod !== void 0) {
|
51707
51857
|
result.details.ifBasicAliasTypeMethodThenRealMethod = this.getFunctionEntity(realBasicMethod);
|
@@ -51727,8 +51877,8 @@ var EntityMap = class {
|
|
51727
51877
|
result.containingPackage = this.getContainingPackageAndAccumulateIfMember(entity, result);
|
51728
51878
|
result.ifTypeMemberThenContainingType = this.getTypeOrExtensionEntity(entity.getContainer().getEntity());
|
51729
51879
|
result.details.isStatic = entity.isStatic();
|
51730
|
-
result.details.isAbstract =
|
51731
|
-
result.details.isBasic =
|
51880
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(entity);
|
51881
|
+
result.details.isBasic = TypeMemberEntity.isBasic(entity);
|
51732
51882
|
result.name = EmitPhaseName.ofOperator(result.containingPackage.locale, entity.getOperatorKind());
|
51733
51883
|
result.details.isBuiltInOperator = findTag(
|
51734
51884
|
this._analyzer.wellKnownDeclarations.builtIntoPlatform,
|
@@ -51800,8 +51950,8 @@ var EntityMap = class {
|
|
51800
51950
|
this.getNameText(owningEntity.getName(), entity.getTags())
|
51801
51951
|
);
|
51802
51952
|
result.details.isStatic = owningEntity.isStatic();
|
51803
|
-
result.details.isAbstract =
|
51804
|
-
result.details.isBasic =
|
51953
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(owningEntity);
|
51954
|
+
result.details.isBasic = TypeMemberEntity.isBasic(owningEntity);
|
51805
51955
|
result.details.overriddenMembers = owningEntity.getOverriddenMembers().map((m) => this.getVariableEntity(m.getEntity()).getter).filter((g) => g !== void 0);
|
51806
51956
|
} else {
|
51807
51957
|
Debug.never(owningEntity);
|
@@ -51813,8 +51963,8 @@ var EntityMap = class {
|
|
51813
51963
|
owningEntity.getContainer().getEntity()
|
51814
51964
|
);
|
51815
51965
|
result.details.isStatic = owningEntity.isStatic();
|
51816
|
-
result.details.isAbstract =
|
51817
|
-
result.details.isBasic =
|
51966
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(owningEntity);
|
51967
|
+
result.details.isBasic = TypeMemberEntity.isBasic(owningEntity);
|
51818
51968
|
result.name = EmitPhaseName.ofIndexedElementGetter(result.containingPackage.locale);
|
51819
51969
|
result.details.overriddenMembers = owningEntity.getOverriddenMembers().map((i) => i.getEntity().getGetter()).filter((g) => g !== void 0).map((g) => this.getGetterEntity(g));
|
51820
51970
|
break;
|
@@ -51824,8 +51974,8 @@ var EntityMap = class {
|
|
51824
51974
|
owningEntity.getContainer().getEntity()
|
51825
51975
|
);
|
51826
51976
|
result.details.isStatic = owningEntity.isStatic();
|
51827
|
-
result.details.isAbstract =
|
51828
|
-
result.details.isBasic =
|
51977
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(owningEntity);
|
51978
|
+
result.details.isBasic = TypeMemberEntity.isBasic(owningEntity);
|
51829
51979
|
result.name = EmitPhaseName.ofDereferencedVariableGetter(result.containingPackage.locale);
|
51830
51980
|
result.details.overriddenMembers = owningEntity.getOverriddenMembers().map((i) => i.getEntity().getGetter()).filter((g) => g !== void 0).map((g) => this.getGetterEntity(g));
|
51831
51981
|
break;
|
@@ -51863,8 +52013,8 @@ var EntityMap = class {
|
|
51863
52013
|
this.getNameText(owningEntity.getName(), entity.getTags())
|
51864
52014
|
);
|
51865
52015
|
result.details.isStatic = owningEntity.isStatic();
|
51866
|
-
result.details.isAbstract =
|
51867
|
-
result.details.isBasic =
|
52016
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(owningEntity);
|
52017
|
+
result.details.isBasic = TypeMemberEntity.isBasic(owningEntity);
|
51868
52018
|
result.details.overriddenMembers = owningEntity.getOverriddenMembers().map((m) => this.getVariableEntity(m.getEntity()).setter).filter((s) => s !== void 0);
|
51869
52019
|
} else {
|
51870
52020
|
Debug.never(owningEntity);
|
@@ -51876,8 +52026,8 @@ var EntityMap = class {
|
|
51876
52026
|
owningEntity.getContainer().getEntity()
|
51877
52027
|
);
|
51878
52028
|
result.details.isStatic = owningEntity.isStatic();
|
51879
|
-
result.details.isAbstract =
|
51880
|
-
result.details.isBasic =
|
52029
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(owningEntity);
|
52030
|
+
result.details.isBasic = TypeMemberEntity.isBasic(owningEntity);
|
51881
52031
|
result.name = EmitPhaseName.ofIndexedElementSetter(result.containingPackage.locale);
|
51882
52032
|
result.details.overriddenMembers = owningEntity.getOverriddenMembers().map((i) => i.getEntity().getSetter()).filter((g) => g !== void 0).map((s) => this.getSetterEntity(s));
|
51883
52033
|
break;
|
@@ -51887,8 +52037,8 @@ var EntityMap = class {
|
|
51887
52037
|
owningEntity.getContainer().getEntity()
|
51888
52038
|
);
|
51889
52039
|
result.details.isStatic = owningEntity.isStatic();
|
51890
|
-
result.details.isAbstract =
|
51891
|
-
result.details.isBasic =
|
52040
|
+
result.details.isAbstract = TypeMemberEntity.isAbstract(owningEntity);
|
52041
|
+
result.details.isBasic = TypeMemberEntity.isBasic(owningEntity);
|
51892
52042
|
result.name = EmitPhaseName.ofDereferencedVariableSetter(result.containingPackage.locale);
|
51893
52043
|
result.details.overriddenMembers = owningEntity.getOverriddenMembers().map((i) => i.getEntity().getSetter()).filter((g) => g !== void 0).map((s) => this.getSetterEntity(s));
|
51894
52044
|
break;
|
@@ -54035,7 +54185,7 @@ var GeneralLoweringContext = class {
|
|
54035
54185
|
}
|
54036
54186
|
descriptorArgument = new JsObjectLiteral(descriptorProperties, void 0);
|
54037
54187
|
}
|
54038
|
-
return new
|
54188
|
+
return new CallExpression5(
|
54039
54189
|
definePropertyAccess,
|
54040
54190
|
false,
|
54041
54191
|
new OrderedArguments([object, keyExpression, descriptorArgument], false),
|
@@ -54057,7 +54207,7 @@ var GeneralLoweringContext = class {
|
|
54057
54207
|
this.ectx.standardTypes.func,
|
54058
54208
|
void 0
|
54059
54209
|
);
|
54060
|
-
return new
|
54210
|
+
return new CallExpression5(
|
54061
54211
|
getOwnPropertyDescriptorAccess,
|
54062
54212
|
false,
|
54063
54213
|
new OrderedArguments([object, keyExpression], false),
|
@@ -54150,7 +54300,7 @@ var HelperFunctions = class {
|
|
54150
54300
|
createHelperFunctionCall(entity, args) {
|
54151
54301
|
const functionAccess = new FunctionAccessExpression(AccessedFunction5.fromEntity(entity), true, void 0);
|
54152
54302
|
const orderedArguments = new OrderedArguments(args, false);
|
54153
|
-
const callExpression2 = new
|
54303
|
+
const callExpression2 = new CallExpression5(
|
54154
54304
|
functionAccess,
|
54155
54305
|
false,
|
54156
54306
|
orderedArguments,
|
@@ -54343,7 +54493,7 @@ var TypeExtensionBasicMembersLowering = class {
|
|
54343
54493
|
packageEntity
|
54344
54494
|
);
|
54345
54495
|
keyEntity.isPackageMember = true;
|
54346
|
-
const keyInitializer = new
|
54496
|
+
const keyInitializer = new CallExpression5(
|
54347
54497
|
new TypeAccessExpression(this._ctx.ectx.jsSymbolType, void 0),
|
54348
54498
|
false,
|
54349
54499
|
new OrderedArguments([], false),
|
@@ -54421,7 +54571,7 @@ var AspectsLowering = class {
|
|
54421
54571
|
for (const declaration of pkg.ir.declarations) {
|
54422
54572
|
if (declaration.kind === 24 /* PackageTypeDeclaration */ && this._ctx.ectx.isRefOrPlainObjectTypeEntity(declaration.entity)) {
|
54423
54573
|
this.addRedirectingMembersForImplementedAspectMembersToPrototype(declaration);
|
54424
|
-
statements.push(...this.
|
54574
|
+
statements.push(...this.addInheritedNotOverriddenAspectMembersToPrototype(declaration));
|
54425
54575
|
}
|
54426
54576
|
}
|
54427
54577
|
if (statements.length > 0) {
|
@@ -54439,7 +54589,7 @@ var AspectsLowering = class {
|
|
54439
54589
|
packageEntity
|
54440
54590
|
);
|
54441
54591
|
keyEntity.isPackageMember = true;
|
54442
|
-
const keyInitializer = new
|
54592
|
+
const keyInitializer = new CallExpression5(
|
54443
54593
|
new TypeAccessExpression(this._ctx.ectx.jsSymbolType, void 0),
|
54444
54594
|
false,
|
54445
54595
|
new OrderedArguments([], false),
|
@@ -54545,7 +54695,7 @@ var AspectsLowering = class {
|
|
54545
54695
|
void 0
|
54546
54696
|
);
|
54547
54697
|
const args = new OrderedArguments(parameterEntities.map((e) => VariableAccessExpression.get(e)), false);
|
54548
|
-
const methodCall = new
|
54698
|
+
const methodCall = new CallExpression5(
|
54549
54699
|
methodAccess,
|
54550
54700
|
false,
|
54551
54701
|
args,
|
@@ -54646,14 +54796,14 @@ var AspectsLowering = class {
|
|
54646
54796
|
return new FieldSetterDeclaration3(setterEntity, [], body, parameterEntity, void 0);
|
54647
54797
|
}
|
54648
54798
|
getNotAbstractAspectMembersToAddToDerivedType(entity) {
|
54649
|
-
const
|
54799
|
+
const overriddenMembers = Query.from(entity.members).map((m) => this.getAllOverriddenAspectMembers(m)).filter((m) => m !== void 0).flatMap((m) => m).uniqueToSet();
|
54650
54800
|
const result = /* @__PURE__ */ new Set();
|
54651
54801
|
for (const aspect of enumerateOwnAspectsRecursively(entity)) {
|
54652
54802
|
if (!aspect.containingPackage.details.isSource) {
|
54653
54803
|
continue;
|
54654
54804
|
}
|
54655
54805
|
for (const member of aspect.members) {
|
54656
|
-
if (!
|
54806
|
+
if (!overriddenMembers.has(member) && !member.details.isAbstract && !member.details.isStatic) {
|
54657
54807
|
result.add(member);
|
54658
54808
|
}
|
54659
54809
|
}
|
@@ -54666,7 +54816,7 @@ var AspectsLowering = class {
|
|
54666
54816
|
}
|
54667
54817
|
}
|
54668
54818
|
}
|
54669
|
-
|
54819
|
+
addInheritedNotOverriddenAspectMembersToPrototype(declaration) {
|
54670
54820
|
const membersFromAspects = this.getNotAbstractAspectMembersToAddToDerivedType(declaration.entity);
|
54671
54821
|
if (membersFromAspects.length === 0) {
|
54672
54822
|
return [];
|
@@ -54681,7 +54831,7 @@ var AspectsLowering = class {
|
|
54681
54831
|
Logger.error(`\u0427\u043B\u0435\u043D \u0430\u0441\u043F\u0435\u043A\u0442\u0430 ${containingType.name}.${member.name} \u0434\u043E\u043B\u0436\u0435\u043D \u0438\u043C\u0435\u0442\u044C \u0432\u044B\u0447\u0438\u0441\u043B\u044F\u0435\u043C\u043E\u0435 \u0438\u043C\u044F.`);
|
54682
54832
|
continue;
|
54683
54833
|
}
|
54684
|
-
const statement = this.
|
54834
|
+
const statement = this.addNotOverriddenAspectMemberToPrototype(member, declaration.entity);
|
54685
54835
|
result.push(statement);
|
54686
54836
|
}
|
54687
54837
|
if (variableDeclarations.length > 0) {
|
@@ -54692,7 +54842,7 @@ var AspectsLowering = class {
|
|
54692
54842
|
}
|
54693
54843
|
// Object.defineProperty(TargetType.prototype, key,
|
54694
54844
|
// Object.getOwnPropertyDescriptor(AspectType.prototype, 'entityName'))
|
54695
|
-
|
54845
|
+
addNotOverriddenAspectMemberToPrototype(entity, targetType) {
|
54696
54846
|
const containingType = entity.ifTypeMemberThenContainingType;
|
54697
54847
|
Debug.assertNotNull(containingType);
|
54698
54848
|
const computedNameInfo = entity.details.hasComputedName;
|
@@ -55022,7 +55172,7 @@ var AliasTypeAndExtensionMembersAccessLowering = class extends ExecutableCodeLow
|
|
55022
55172
|
);
|
55023
55173
|
const args = this._ctx.getOrderedArguments(node.args);
|
55024
55174
|
const options = new CallExpressionEmitOptions().setIsAliasOrExtensionMethodCallLowered(true);
|
55025
|
-
return new
|
55175
|
+
return new CallExpression5(
|
55026
55176
|
methodAccess,
|
55027
55177
|
false,
|
55028
55178
|
args,
|
@@ -55092,7 +55242,7 @@ var AliasTypeAndExtensionMembersAccessLowering = class extends ExecutableCodeLow
|
|
55092
55242
|
void 0
|
55093
55243
|
);
|
55094
55244
|
const options = new CallExpressionEmitOptions().setIsAliasOrExtensionMethodCallLowered(true);
|
55095
|
-
return new
|
55245
|
+
return new CallExpression5(
|
55096
55246
|
methodAccess,
|
55097
55247
|
false,
|
55098
55248
|
new OrderedArguments(newArguments, args.isLastArgumentSpreading),
|
@@ -55267,7 +55417,7 @@ var PlainObjectConstructorCallsLowering = class extends ExecutableCodeLowering {
|
|
55267
55417
|
void 0,
|
55268
55418
|
void 0
|
55269
55419
|
);
|
55270
|
-
return new
|
55420
|
+
return new CallExpression5(methodAccess, false, node.args, false, node.returnType, void 0);
|
55271
55421
|
}
|
55272
55422
|
};
|
55273
55423
|
var OverloadedConstructorsLowering = class {
|
@@ -55649,7 +55799,7 @@ var CompoundDeclarationsAndOperatorsAccessLowering = class extends ExecutableCod
|
|
55649
55799
|
void 0
|
55650
55800
|
);
|
55651
55801
|
const args = new OrderedArguments([], false);
|
55652
|
-
return new
|
55802
|
+
return new CallExpression5(packageFunctionAccess, false, args, false, node.variable.type, node.sourceLocation);
|
55653
55803
|
}
|
55654
55804
|
lowerComputedPackageVariableSetAccessExpression(left, operatorKind, right, operator) {
|
55655
55805
|
let value;
|
@@ -55675,7 +55825,7 @@ var CompoundDeclarationsAndOperatorsAccessLowering = class extends ExecutableCod
|
|
55675
55825
|
void 0
|
55676
55826
|
);
|
55677
55827
|
const args = new OrderedArguments([value], false);
|
55678
|
-
const callExpression2 = new
|
55828
|
+
const callExpression2 = new CallExpression5(
|
55679
55829
|
packageFunctionAccess,
|
55680
55830
|
false,
|
55681
55831
|
args,
|
@@ -55706,7 +55856,7 @@ var IndexedAccessExpressionLowering = class extends ExecutableCodeLowering {
|
|
55706
55856
|
void 0,
|
55707
55857
|
void 0
|
55708
55858
|
);
|
55709
|
-
return new
|
55859
|
+
return new CallExpression5(
|
55710
55860
|
methodAccess,
|
55711
55861
|
false,
|
55712
55862
|
node.args,
|
@@ -55746,7 +55896,7 @@ var IndexedAccessExpressionLowering = class extends ExecutableCodeLowering {
|
|
55746
55896
|
const originalArguments = this._ctx.getOrderedArguments(node.left.args);
|
55747
55897
|
const argumentValues = Query.from(originalArguments.values).chain([node.right]).toArray();
|
55748
55898
|
const args = new OrderedArguments(argumentValues, originalArguments.isLastArgumentSpreading);
|
55749
|
-
const callExpression2 = new
|
55899
|
+
const callExpression2 = new CallExpression5(
|
55750
55900
|
methodAccess,
|
55751
55901
|
false,
|
55752
55902
|
args,
|
@@ -55806,7 +55956,7 @@ var IndexedAccessExpressionLowering = class extends ExecutableCodeLowering {
|
|
55806
55956
|
);
|
55807
55957
|
const argumentValues = Query.from(argumentTempAssignments).chain([newValue]).toArray();
|
55808
55958
|
const methodArguments = new OrderedArguments(argumentValues, false);
|
55809
|
-
const callExpression2 = new
|
55959
|
+
const callExpression2 = new CallExpression5(
|
55810
55960
|
methodAccess,
|
55811
55961
|
false,
|
55812
55962
|
methodArguments,
|
@@ -55839,7 +55989,7 @@ var DereferenceExpressionLowering = class extends ExecutableCodeLowering {
|
|
55839
55989
|
void 0
|
55840
55990
|
);
|
55841
55991
|
const args = new OrderedArguments([], false);
|
55842
|
-
return new
|
55992
|
+
return new CallExpression5(
|
55843
55993
|
methodAccess,
|
55844
55994
|
false,
|
55845
55995
|
args,
|
@@ -55877,7 +56027,7 @@ var DereferenceExpressionLowering = class extends ExecutableCodeLowering {
|
|
55877
56027
|
void 0
|
55878
56028
|
);
|
55879
56029
|
const args = new OrderedArguments([node.right], false);
|
55880
|
-
const callExpression2 = new
|
56030
|
+
const callExpression2 = new CallExpression5(
|
55881
56031
|
methodAccess,
|
55882
56032
|
false,
|
55883
56033
|
args,
|
@@ -55927,7 +56077,7 @@ var DereferenceExpressionLowering = class extends ExecutableCodeLowering {
|
|
55927
56077
|
void 0
|
55928
56078
|
);
|
55929
56079
|
const args = new OrderedArguments([newValue], false);
|
55930
|
-
const callExpression2 = new
|
56080
|
+
const callExpression2 = new CallExpression5(
|
55931
56081
|
methodAccess,
|
55932
56082
|
false,
|
55933
56083
|
args,
|
@@ -55990,7 +56140,7 @@ var FunctionObjectLowering = class _FunctionObjectLowering extends ExecutableCod
|
|
55990
56140
|
);
|
55991
56141
|
argsParameter.details.isVariadicParameter = true;
|
55992
56142
|
const args = new OrderedArguments([VariableAccessExpression.get(argsParameter)], true);
|
55993
|
-
const methodCall = new
|
56143
|
+
const methodCall = new CallExpression5(methodAccess, false, args, false, node.method.returnType, void 0);
|
55994
56144
|
const returnStatement2 = new ReturnStatement3(methodCall, void 0);
|
55995
56145
|
const parameter = new ValueParameterDeclaration(argsParameter, void 0, true, void 0);
|
55996
56146
|
const functionLiteral = new FunctionLiteral3(
|
@@ -56510,7 +56660,7 @@ var OperatorsUsageLowering = class extends ExecutableCodeLowering {
|
|
56510
56660
|
}
|
56511
56661
|
lowerUnaryOperatorUsage(expression, operator, sourceLocation) {
|
56512
56662
|
const methodAccess = new MethodAccessExpression(expression, false, operator, true, void 0, void 0);
|
56513
|
-
return new
|
56663
|
+
return new CallExpression5(
|
56514
56664
|
methodAccess,
|
56515
56665
|
false,
|
56516
56666
|
new OrderedArguments([], false),
|
@@ -56522,7 +56672,7 @@ var OperatorsUsageLowering = class extends ExecutableCodeLowering {
|
|
56522
56672
|
lowerBinaryOperatorUsage(left, right, operator, sourceLocation) {
|
56523
56673
|
const methodAccess = new MethodAccessExpression(left, false, operator, true, void 0, void 0);
|
56524
56674
|
const args = new OrderedArguments([right], false);
|
56525
|
-
return new
|
56675
|
+
return new CallExpression5(
|
56526
56676
|
methodAccess,
|
56527
56677
|
false,
|
56528
56678
|
args,
|
@@ -56713,7 +56863,7 @@ var ProxiedVariableAccessLowering = class extends ExecutableCodeLowering {
|
|
56713
56863
|
this.createVariableDescriptor(proxiedVariableEntity),
|
56714
56864
|
this.createAccessLocation(node)
|
56715
56865
|
], false);
|
56716
|
-
const writeMethodCall = new
|
56866
|
+
const writeMethodCall = new CallExpression5(
|
56717
56867
|
writeMethodAccess,
|
56718
56868
|
false,
|
56719
56869
|
writeMethodArguments,
|
@@ -56751,7 +56901,7 @@ var ProxiedVariableAccessLowering = class extends ExecutableCodeLowering {
|
|
56751
56901
|
this.createVariableDescriptor(proxiedVariableEntity),
|
56752
56902
|
this.createAccessLocation(node)
|
56753
56903
|
], false);
|
56754
|
-
const readMethodCall = new
|
56904
|
+
const readMethodCall = new CallExpression5(
|
56755
56905
|
readMethodAccess,
|
56756
56906
|
false,
|
56757
56907
|
readMethodArguments,
|
@@ -57949,7 +58099,7 @@ var IrBuilder = class {
|
|
57949
58099
|
}
|
57950
58100
|
buildFieldDeclaration(declaration) {
|
57951
58101
|
const originalEntity = this._analyzer.entity.ofFieldDeclaration(declaration);
|
57952
|
-
if (
|
58102
|
+
if (TypeMemberEntity.isAbstract(originalEntity)) {
|
57953
58103
|
return void 0;
|
57954
58104
|
}
|
57955
58105
|
const entity = this._entityMap.getVariableEntity(originalEntity);
|
@@ -58345,7 +58495,7 @@ var IrBuilder = class {
|
|
58345
58495
|
void 0,
|
58346
58496
|
void 0
|
58347
58497
|
);
|
58348
|
-
return new
|
58498
|
+
return new CallExpression5(
|
58349
58499
|
methodAccess,
|
58350
58500
|
false,
|
58351
58501
|
new OrderedArguments([], false),
|
@@ -58540,7 +58690,7 @@ var IrBuilder = class {
|
|
58540
58690
|
const args = this.buildArgumentList(expression.argumentList, parameters);
|
58541
58691
|
const isAsyncFunctionCall = meaning.func.value.getEntity().isAsync();
|
58542
58692
|
const returnType = this._entityMap.getType(meaning.func.value.getReturnType());
|
58543
|
-
return new
|
58693
|
+
return new CallExpression5(
|
58544
58694
|
receiver,
|
58545
58695
|
false,
|
58546
58696
|
args,
|
@@ -58573,7 +58723,7 @@ var IrBuilder = class {
|
|
58573
58723
|
const args = this.buildArgumentList(expression.argumentList, parameters);
|
58574
58724
|
const isAsyncFunctionCall = false;
|
58575
58725
|
const returnType = this._entityMap.getType(meaning.operator.value.getReturnType());
|
58576
|
-
return new
|
58726
|
+
return new CallExpression5(
|
58577
58727
|
receiver,
|
58578
58728
|
false,
|
58579
58729
|
args,
|
@@ -58589,7 +58739,7 @@ var IrBuilder = class {
|
|
58589
58739
|
const args = this.buildArgumentList(expression.argumentList, parameters);
|
58590
58740
|
const isAsyncFunctionCall = meaning.type.isAsync();
|
58591
58741
|
const returnType = this._entityMap.getType(meaning.type.getReturnType());
|
58592
|
-
return new
|
58742
|
+
return new CallExpression5(
|
58593
58743
|
irExpression,
|
58594
58744
|
isOptionalAccess,
|
58595
58745
|
args,
|
@@ -58807,8 +58957,8 @@ var IrBuilder = class {
|
|
58807
58957
|
case "static-field-access": {
|
58808
58958
|
const typeEntity = this.getEntityFromType(meaning.type);
|
58809
58959
|
const typeAccess = new TypeAccessExpression(typeEntity, void 0);
|
58810
|
-
const entity = this._entityMap.getVariableEntity(meaning.
|
58811
|
-
const type = this._entityMap.getType(meaning.
|
58960
|
+
const entity = this._entityMap.getVariableEntity(meaning.field.value.getEntity());
|
58961
|
+
const type = this._entityMap.getType(meaning.field.value.getType());
|
58812
58962
|
return new FieldAccessExpression(
|
58813
58963
|
typeAccess,
|
58814
58964
|
false,
|
@@ -58839,11 +58989,11 @@ var IrBuilder = class {
|
|
58839
58989
|
);
|
58840
58990
|
}
|
58841
58991
|
case "instance-field-access": {
|
58842
|
-
const originalEntity = meaning.
|
58992
|
+
const originalEntity = meaning.field.value.getEntity();
|
58843
58993
|
const expressionIr = this.buildExpression(expression.expression);
|
58844
58994
|
const isOptionalAccess = expression.expression.kind === 64 /* AssumptionExpression */;
|
58845
58995
|
const entity = this._entityMap.getVariableEntity(originalEntity);
|
58846
|
-
const type = this._entityMap.getType(meaning.
|
58996
|
+
const type = this._entityMap.getType(meaning.field.value.getType());
|
58847
58997
|
return new FieldAccessExpression(
|
58848
58998
|
expressionIr,
|
58849
58999
|
isOptionalAccess,
|
@@ -59260,7 +59410,7 @@ var IrBuilder = class {
|
|
59260
59410
|
true,
|
59261
59411
|
this.getSourceLocation(tag.name)
|
59262
59412
|
);
|
59263
|
-
const functionCall = new
|
59413
|
+
const functionCall = new CallExpression5(
|
59264
59414
|
functionAccess,
|
59265
59415
|
false,
|
59266
59416
|
args,
|
@@ -60877,7 +61027,7 @@ var Emitter = class _Emitter {
|
|
60877
61027
|
}
|
60878
61028
|
createMainFunction(packageConstructors, packageEntryPoints, containingPackage) {
|
60879
61029
|
const functionCallStatements = Query.from(packageConstructors).chain(packageEntryPoints).map((o) => {
|
60880
|
-
const expression = new
|
61030
|
+
const expression = new CallExpression5(
|
60881
61031
|
new FunctionAccessExpression(AccessedFunction5.fromEntity(o.entity), true, void 0),
|
60882
61032
|
false,
|
60883
61033
|
new OrderedArguments([], false),
|
@@ -60902,7 +61052,7 @@ var Emitter = class _Emitter {
|
|
60902
61052
|
return new PackageFunctionDeclaration3(modifiers, [], body, entity, false, void 0);
|
60903
61053
|
}
|
60904
61054
|
createMainFunctionCall(mainFunction) {
|
60905
|
-
const functionCall = new
|
61055
|
+
const functionCall = new CallExpression5(
|
60906
61056
|
new FunctionAccessExpression(AccessedFunction5.fromEntity(mainFunction.entity), true, void 0),
|
60907
61057
|
false,
|
60908
61058
|
new OrderedArguments([], false),
|
@@ -62101,7 +62251,7 @@ export {
|
|
62101
62251
|
isPackageMemberEntity,
|
62102
62252
|
isEntityWithTags,
|
62103
62253
|
isTypeMemberEntity,
|
62104
|
-
|
62254
|
+
TypeMemberEntity,
|
62105
62255
|
entityToStringDecorator,
|
62106
62256
|
TagType,
|
62107
62257
|
TagFunction,
|
@@ -62148,7 +62298,6 @@ export {
|
|
62148
62298
|
AnalyzedPackageImport,
|
62149
62299
|
AnalyzedPackageImports,
|
62150
62300
|
PackageImportInfo,
|
62151
|
-
TypeUtils,
|
62152
62301
|
ExpressionDenotesFunctionCheckResult,
|
62153
62302
|
ExpressionDenotesOperatorCheckResult,
|
62154
62303
|
DeclaredTypeMemberEntities,
|