Skip to content

Commit 3a1fb1b

Browse files
committed
Properly preserve CheckFlags.Readonly when widening properties
1 parent d023427 commit 3a1fb1b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/compiler/checker.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14630,7 +14630,7 @@ namespace ts {
1463014630
}
1463114631

1463214632
function createSymbolWithType(source: Symbol, type: Type | undefined) {
14633-
const symbol = createSymbol(source.flags, source.escapedName);
14633+
const symbol = createSymbol(source.flags, source.escapedName, getCheckFlags(source) & CheckFlags.Readonly);
1463414634
symbol.declarations = source.declarations;
1463514635
symbol.parent = source.parent;
1463614636
symbol.type = type;

0 commit comments

Comments
 (0)