mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-20 22:51:17 -05:00
Merge pull request #34496 from microsoft/fix34272
Properly attach alias symbol to `readonly T[]` types
This commit is contained in:
@@ -12438,7 +12438,7 @@ namespace ts {
|
||||
|
||||
function getAliasSymbolForTypeNode(node: TypeNode) {
|
||||
let host = node.parent;
|
||||
while (isParenthesizedTypeNode(host)) {
|
||||
while (isParenthesizedTypeNode(host) || isTypeOperatorNode(host) && host.operator === SyntaxKind.ReadonlyKeyword) {
|
||||
host = host.parent;
|
||||
}
|
||||
return isTypeAlias(host) ? getSymbolOfNode(host) : undefined;
|
||||
|
||||
Reference in New Issue
Block a user