mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-11 06:02:53 -05:00
Properly preserve CheckFlags.Readonly when widening properties
This commit is contained in:
@@ -14630,7 +14630,7 @@ namespace ts {
|
||||
}
|
||||
|
||||
function createSymbolWithType(source: Symbol, type: Type | undefined) {
|
||||
const symbol = createSymbol(source.flags, source.escapedName);
|
||||
const symbol = createSymbol(source.flags, source.escapedName, getCheckFlags(source) & CheckFlags.Readonly);
|
||||
symbol.declarations = source.declarations;
|
||||
symbol.parent = source.parent;
|
||||
symbol.type = type;
|
||||
|
||||
Reference in New Issue
Block a user