You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (isAutoAccessorPropertyDeclaration(node) && checkGrammarForInvalidQuestionMark(node.questionToken, Diagnostics.An_accessor_property_cannot_be_declared_optional)) {
45159
+
return true;
45160
+
}
45158
45161
}
45159
45162
else if (node.parent.kind === SyntaxKind.InterfaceDeclaration) {
45160
45163
if (checkGrammarForInvalidDynamicName(node.name, Diagnostics.A_computed_property_name_in_an_interface_must_refer_to_an_expression_whose_type_is_a_literal_type_or_a_unique_symbol_type)) {
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(11,5): error TS1275: 'accessor' modifier can only appear on a property declaration.
11
11
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(12,5): error TS1275: 'accessor' modifier can only appear on a property declaration.
12
12
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(13,5): error TS1275: 'accessor' modifier can only appear on a property declaration.
13
-
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(17,14): error TS1029: 'override' modifier must precede 'accessor' modifier.
14
-
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(21,5): error TS1070: 'accessor' modifier cannot appear on a type member.
15
-
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(24,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
13
+
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(14,15): error TS1276: An 'accessor' property cannot be declared optional.
14
+
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(18,14): error TS1029: 'override' modifier must precede 'accessor' modifier.
15
+
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(22,5): error TS1070: 'accessor' modifier cannot appear on a type member.
16
16
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(25,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
17
17
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(26,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
18
18
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(27,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(30,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
22
22
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(31,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
23
23
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(32,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
24
-
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(32,25): error TS2792: Cannot find module 'x'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?
25
24
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(33,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
25
+
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(33,25): error TS2792: Cannot find module 'x'. Did you mean to set the 'moduleResolution' option to 'node', or to add aliases to the 'paths' option?
26
26
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(34,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
27
27
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(35,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
28
+
tests/cases/conformance/classes/propertyMemberDeclarations/accessorFieldDisallowedModifiers.ts(36,1): error TS1275: 'accessor' modifier can only appear on a property declaration.
0 commit comments