Skip to content

Commit b2f4af4

Browse files
committed
Fix that works with both LKG and built compilers
1 parent f0bf72f commit b2f4af4

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/compiler/checker.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33378,7 +33378,8 @@ namespace ts {
3337833378

3337933379
// Modifiers are never allowed on properties except for 'async' on a method declaration
3338033380
if (prop.modifiers) {
33381-
for (const mod of prop.modifiers) {
33381+
const modifiers = prop.modifiers;
33382+
for (const mod of modifiers) {
3338233383
if (mod.kind !== SyntaxKind.AsyncKeyword || prop.kind !== SyntaxKind.MethodDeclaration) {
3338333384
grammarErrorOnNode(mod, Diagnostics._0_modifier_cannot_be_used_here, getTextOfNode(mod));
3338433385
}

0 commit comments

Comments
 (0)