@@ -124,28 +124,28 @@ declare module "typescript" {
124
124
WhileKeyword = 99 ,
125
125
WithKeyword = 100 ,
126
126
AsKeyword = 101 ,
127
- FromKeyword = 102 ,
128
- ImplementsKeyword = 103 ,
129
- InterfaceKeyword = 104 ,
130
- LetKeyword = 105 ,
131
- PackageKeyword = 106 ,
132
- PrivateKeyword = 107 ,
133
- ProtectedKeyword = 108 ,
134
- PublicKeyword = 109 ,
135
- StaticKeyword = 110 ,
136
- YieldKeyword = 111 ,
137
- AnyKeyword = 112 ,
138
- BooleanKeyword = 113 ,
139
- ConstructorKeyword = 114 ,
140
- DeclareKeyword = 115 ,
141
- GetKeyword = 116 ,
142
- ModuleKeyword = 117 ,
143
- RequireKeyword = 118 ,
144
- NumberKeyword = 119 ,
145
- SetKeyword = 120 ,
146
- StringKeyword = 121 ,
147
- SymbolKeyword = 122 ,
148
- TypeKeyword = 123 ,
127
+ ImplementsKeyword = 102 ,
128
+ InterfaceKeyword = 103 ,
129
+ LetKeyword = 104 ,
130
+ PackageKeyword = 105 ,
131
+ PrivateKeyword = 106 ,
132
+ ProtectedKeyword = 107 ,
133
+ PublicKeyword = 108 ,
134
+ StaticKeyword = 109 ,
135
+ YieldKeyword = 110 ,
136
+ AnyKeyword = 111 ,
137
+ BooleanKeyword = 112 ,
138
+ ConstructorKeyword = 113 ,
139
+ DeclareKeyword = 114 ,
140
+ GetKeyword = 115 ,
141
+ ModuleKeyword = 116 ,
142
+ RequireKeyword = 117 ,
143
+ NumberKeyword = 118 ,
144
+ SetKeyword = 119 ,
145
+ StringKeyword = 120 ,
146
+ SymbolKeyword = 121 ,
147
+ TypeKeyword = 122 ,
148
+ FromKeyword = 123 ,
149
149
OfKeyword = 124 ,
150
150
QualifiedName = 125 ,
151
151
ComputedPropertyName = 126 ,
@@ -251,8 +251,8 @@ declare module "typescript" {
251
251
LastReservedWord = 100 ,
252
252
FirstKeyword = 65 ,
253
253
LastKeyword = 124 ,
254
- FirstFutureReservedWord = 103 ,
255
- LastFutureReservedWord = 111 ,
254
+ FirstFutureReservedWord = 102 ,
255
+ LastFutureReservedWord = 110 ,
256
256
FirstTypeNode = 139 ,
257
257
LastTypeNode = 147 ,
258
258
FirstPunctuation = 14 ,
@@ -276,15 +276,16 @@ declare module "typescript" {
276
276
Private = 32 ,
277
277
Protected = 64 ,
278
278
Static = 128 ,
279
- MultiLine = 256 ,
280
- Synthetic = 512 ,
281
- DeclarationFile = 1024 ,
282
- Let = 2048 ,
283
- Const = 4096 ,
284
- OctalLiteral = 8192 ,
285
- Modifier = 243 ,
279
+ Default = 256 ,
280
+ MultiLine = 512 ,
281
+ Synthetic = 1024 ,
282
+ DeclarationFile = 2048 ,
283
+ Let = 4096 ,
284
+ Const = 8192 ,
285
+ OctalLiteral = 16384 ,
286
+ Modifier = 499 ,
286
287
AccessibilityModifier = 112 ,
287
- BlockScoped = 6144 ,
288
+ BlockScoped = 12288 ,
288
289
}
289
290
const enum ParserContextFlags {
290
291
StrictMode = 1 ,
@@ -412,7 +413,7 @@ declare module "typescript" {
412
413
body ?: Block | Expression ;
413
414
}
414
415
interface FunctionDeclaration extends FunctionLikeDeclaration , Statement {
415
- name : Identifier ;
416
+ name ? : Identifier ;
416
417
body ?: Block ;
417
418
}
418
419
interface MethodDeclaration extends FunctionLikeDeclaration , ClassElement , ObjectLiteralElement {
@@ -505,7 +506,9 @@ declare module "typescript" {
505
506
}
506
507
interface ConditionalExpression extends Expression {
507
508
condition : Expression ;
509
+ questionToken : Node ;
508
510
whenTrue : Expression ;
511
+ colonToken : Node ;
509
512
whenFalse : Expression ;
510
513
}
511
514
interface FunctionExpression extends PrimaryExpression , FunctionLikeDeclaration {
@@ -515,6 +518,7 @@ declare module "typescript" {
515
518
interface LiteralExpression extends PrimaryExpression {
516
519
text : string ;
517
520
isUnterminated ?: boolean ;
521
+ hasExtendedUnicodeEscape ?: boolean ;
518
522
}
519
523
interface StringLiteralExpression extends LiteralExpression {
520
524
_stringLiteralExpressionBrand : any ;
@@ -541,6 +545,7 @@ declare module "typescript" {
541
545
}
542
546
interface PropertyAccessExpression extends MemberExpression {
543
547
expression : LeftHandSideExpression ;
548
+ dotToken : Node ;
544
549
name : Identifier ;
545
550
}
546
551
interface ElementAccessExpression extends MemberExpression {
@@ -636,16 +641,15 @@ declare module "typescript" {
636
641
catchClause ?: CatchClause ;
637
642
finallyBlock ?: Block ;
638
643
}
639
- interface CatchClause extends Declaration {
640
- name : Identifier ;
641
- type ?: TypeNode ;
644
+ interface CatchClause extends Node {
645
+ variableDeclaration : VariableDeclaration ;
642
646
block : Block ;
643
647
}
644
648
interface ModuleElement extends Node {
645
649
_moduleElementBrand : any ;
646
650
}
647
651
interface ClassDeclaration extends Declaration , ModuleElement {
648
- name : Identifier ;
652
+ name ? : Identifier ;
649
653
typeParameters ?: NodeArray < TypeParameterDeclaration > ;
650
654
heritageClauses ?: NodeArray < HeritageClause > ;
651
655
members : NodeArray < ClassElement > ;
@@ -675,10 +679,7 @@ declare module "typescript" {
675
679
name : Identifier ;
676
680
members : NodeArray < EnumMember > ;
677
681
}
678
- interface ExportContainer {
679
- exportStars ?: ExportDeclaration [ ] ;
680
- }
681
- interface ModuleDeclaration extends Declaration , ModuleElement , ExportContainer {
682
+ interface ModuleDeclaration extends Declaration , ModuleElement {
682
683
name : Identifier | LiteralExpression ;
683
684
body : ModuleBlock | ModuleDeclaration ;
684
685
}
@@ -703,7 +704,7 @@ declare module "typescript" {
703
704
interface NamespaceImport extends Declaration {
704
705
name : Identifier ;
705
706
}
706
- interface ExportDeclaration extends Statement , ModuleElement {
707
+ interface ExportDeclaration extends Declaration , ModuleElement {
707
708
exportClause ?: NamedExports ;
708
709
moduleSpecifier ?: Expression ;
709
710
}
@@ -718,16 +719,17 @@ declare module "typescript" {
718
719
}
719
720
type ImportSpecifier = ImportOrExportSpecifier ;
720
721
type ExportSpecifier = ImportOrExportSpecifier ;
721
- interface ExportAssignment extends Statement , ModuleElement {
722
- exportName : Identifier ;
722
+ interface ExportAssignment extends Declaration , ModuleElement {
723
+ isExportEquals ?: boolean ;
724
+ expression : Expression ;
723
725
}
724
726
interface FileReference extends TextRange {
725
727
fileName : string ;
726
728
}
727
729
interface CommentRange extends TextRange {
728
730
hasTrailingNewLine ?: boolean ;
729
731
}
730
- interface SourceFile extends Declaration , ExportContainer {
732
+ interface SourceFile extends Declaration {
731
733
statements : NodeArray < ModuleElement > ;
732
734
endOfFileToken : Node ;
733
735
fileName : string ;
@@ -832,6 +834,7 @@ declare module "typescript" {
832
834
getConstantValue ( node : EnumMember | PropertyAccessExpression | ElementAccessExpression ) : number ;
833
835
isValidPropertyAccess ( node : PropertyAccessExpression | QualifiedName , propertyName : string ) : boolean ;
834
836
getAliasedSymbol ( symbol : Symbol ) : Symbol ;
837
+ getExportsOfExternalModule ( node : ImportDeclaration ) : Symbol [ ] ;
835
838
}
836
839
interface SymbolDisplayBuilder {
837
840
buildTypeDisplay ( type : Type , writer : SymbolWriter , enclosingDeclaration ?: Node , flags ?: TypeFormatFlags ) : void ;
@@ -889,10 +892,10 @@ declare module "typescript" {
889
892
errorModuleName ?: string ;
890
893
}
891
894
interface EmitResolver {
892
- getGeneratedNameForNode ( node : ModuleDeclaration | EnumDeclaration | ImportDeclaration | ExportDeclaration ) : string ;
895
+ getGeneratedNameForNode ( node : Node ) : string ;
893
896
getExpressionNameSubstitution ( node : Identifier ) : string ;
894
- getExportAssignmentName ( node : SourceFile ) : string ;
895
- isReferencedImportDeclaration ( node : Node ) : boolean ;
897
+ hasExportDefaultValue ( node : SourceFile ) : boolean ;
898
+ isReferencedAliasDeclaration ( node : Node ) : boolean ;
896
899
isTopLevelValueImportEqualsWithEntityName ( node : ImportEqualsDeclaration ) : boolean ;
897
900
getNodeCheckFlags ( node : Node ) : NodeCheckFlags ;
898
901
isDeclarationVisible ( node : Declaration ) : boolean ;
@@ -903,6 +906,7 @@ declare module "typescript" {
903
906
isEntityNameVisible ( entityName : EntityName , enclosingDeclaration : Node ) : SymbolVisibilityResult ;
904
907
getConstantValue ( node : EnumMember | PropertyAccessExpression | ElementAccessExpression ) : number ;
905
908
isUnknownIdentifier ( location : Node , name : string ) : boolean ;
909
+ getBlockScopedVariableId ( node : Identifier ) : number ;
906
910
}
907
911
const enum SymbolFlags {
908
912
FunctionScopedVariable = 1 ,
@@ -928,13 +932,14 @@ declare module "typescript" {
928
932
ExportValue = 1048576 ,
929
933
ExportType = 2097152 ,
930
934
ExportNamespace = 4194304 ,
931
- Import = 8388608 ,
935
+ Alias = 8388608 ,
932
936
Instantiated = 16777216 ,
933
937
Merged = 33554432 ,
934
938
Transient = 67108864 ,
935
939
Prototype = 134217728 ,
936
940
UnionProperty = 268435456 ,
937
941
Optional = 536870912 ,
942
+ ExportStar = 1073741824 ,
938
943
Enum = 384 ,
939
944
Variable = 3 ,
940
945
Value = 107455 ,
@@ -959,7 +964,7 @@ declare module "typescript" {
959
964
SetAccessorExcludes = 74687 ,
960
965
TypeParameterExcludes = 530912 ,
961
966
TypeAliasExcludes = 793056 ,
962
- ImportExcludes = 8388608 ,
967
+ AliasExcludes = 8388608 ,
963
968
ModuleMember = 8914931 ,
964
969
ExportHasLocal = 944 ,
965
970
HasLocals = 255504 ,
@@ -988,10 +993,9 @@ declare module "typescript" {
988
993
declaredType ?: Type ;
989
994
mapper ?: TypeMapper ;
990
995
referenced ?: boolean ;
991
- exportAssignmentChecked ?: boolean ;
992
- exportAssignmentSymbol ?: Symbol ;
993
996
unionType ?: UnionType ;
994
997
resolvedExports ?: SymbolTable ;
998
+ exportsChecked ?: boolean ;
995
999
}
996
1000
interface TransientSymbol extends Symbol , SymbolLinks {
997
1001
}
@@ -1007,6 +1011,7 @@ declare module "typescript" {
1007
1011
SuperStatic = 32 ,
1008
1012
ContextChecked = 64 ,
1009
1013
EnumValuesComputed = 128 ,
1014
+ BlockScopedBindingInLoop = 256 ,
1010
1015
}
1011
1016
interface NodeLinks {
1012
1017
resolvedType ?: Type ;
@@ -1383,6 +1388,7 @@ declare module "typescript" {
1383
1388
getTokenPos ( ) : number ;
1384
1389
getTokenText ( ) : string ;
1385
1390
getTokenValue ( ) : string ;
1391
+ hasExtendedUnicodeEscape ( ) : boolean ;
1386
1392
hasPrecedingLineBreak ( ) : boolean ;
1387
1393
isIdentifier ( ) : boolean ;
1388
1394
isReservedWord ( ) : boolean ;
@@ -1479,9 +1485,6 @@ declare module "typescript" {
1479
1485
getDocumentationComment ( ) : SymbolDisplayPart [ ] ;
1480
1486
}
1481
1487
interface SourceFile {
1482
- version : string ;
1483
- scriptSnapshot : IScriptSnapshot ;
1484
- nameTable : Map < string > ;
1485
1488
getNamedDeclarations ( ) : Declaration [ ] ;
1486
1489
getLineAndCharacterOfPosition ( pos : number ) : LineAndCharacter ;
1487
1490
getLineStarts ( ) : number [ ] ;
@@ -1835,25 +1838,17 @@ declare module "typescript" {
1835
1838
acquireDocument ( fileName : string , compilationSettings : CompilerOptions , scriptSnapshot : IScriptSnapshot , version : string ) : SourceFile ;
1836
1839
/**
1837
1840
* Request an updated version of an already existing SourceFile with a given fileName
1838
- * and compilationSettings. The update will intern call updateLanguageServiceSourceFile
1841
+ * and compilationSettings. The update will in-turn call updateLanguageServiceSourceFile
1839
1842
* to get an updated SourceFile.
1840
1843
*
1841
- * Note: It is not allowed to call update on a SourceFile that was not acquired from this
1842
- * registry originally.
1843
- *
1844
- * @param sourceFile The original sourceFile object to update
1845
1844
* @param fileName The name of the file requested
1846
1845
* @param compilationSettings Some compilation settings like target affects the
1847
1846
* shape of a the resulting SourceFile. This allows the DocumentRegistry to store
1848
1847
* multiple copies of the same file for different compilation settings.
1849
- * @parm scriptSnapshot Text of the file. Only used if the file was not found
1850
- * in the registry and a new one was created.
1851
- * @parm version Current version of the file. Only used if the file was not found
1852
- * in the registry and a new one was created.
1853
- * @parm textChangeRange Change ranges since the last snapshot. Only used if the file
1854
- * was not found in the registry and a new one was created.
1848
+ * @param scriptSnapshot Text of the file.
1849
+ * @param version Current version of the file.
1855
1850
*/
1856
- updateDocument ( sourceFile : SourceFile , fileName : string , compilationSettings : CompilerOptions , scriptSnapshot : IScriptSnapshot , version : string , textChangeRange : TextChangeRange ) : SourceFile ;
1851
+ updateDocument ( fileName : string , compilationSettings : CompilerOptions , scriptSnapshot : IScriptSnapshot , version : string ) : SourceFile ;
1857
1852
/**
1858
1853
* Informs the DocumentRegistry that a file is not needed any longer.
1859
1854
*
0 commit comments