@@ -1502,19 +1502,23 @@ namespace ts {
1502
1502
: node ;
1503
1503
}
1504
1504
1505
- export function createTypeAliasDeclaration ( name : string | Identifier , typeParameters : TypeParameterDeclaration [ ] | undefined , type : TypeNode ) {
1505
+ export function createTypeAliasDeclaration ( decorators : Decorator [ ] | undefined , modifiers : Modifier [ ] | undefined , name : string | Identifier , typeParameters : TypeParameterDeclaration [ ] | undefined , type : TypeNode ) {
1506
1506
const node = < TypeAliasDeclaration > createSynthesizedNode ( SyntaxKind . TypeAliasDeclaration ) ;
1507
+ node . decorators = asNodeArray ( decorators ) ;
1508
+ node . modifiers = asNodeArray ( modifiers ) ;
1507
1509
node . name = asName ( name ) ;
1508
1510
node . typeParameters = asNodeArray ( typeParameters ) ;
1509
1511
node . type = type ;
1510
1512
return node ;
1511
1513
}
1512
1514
1513
- export function updateTypeAliasDeclaration ( node : TypeAliasDeclaration , name : Identifier , typeParameters : TypeParameterDeclaration [ ] | undefined , type : TypeNode ) {
1514
- return node . name !== name
1515
+ export function updateTypeAliasDeclaration ( node : TypeAliasDeclaration , decorators : Decorator [ ] | undefined , modifiers : Modifier [ ] | undefined , name : Identifier , typeParameters : TypeParameterDeclaration [ ] | undefined , type : TypeNode ) {
1516
+ return node . decorators !== decorators
1517
+ || node . modifiers !== modifiers
1518
+ || node . name !== name
1515
1519
|| node . typeParameters !== typeParameters
1516
1520
|| node . type !== type
1517
- ? updateNode ( createTypeAliasDeclaration ( name , typeParameters , type ) , node )
1521
+ ? updateNode ( createTypeAliasDeclaration ( decorators , modifiers , name , typeParameters , type ) , node )
1518
1522
: node ;
1519
1523
}
1520
1524
0 commit comments