@@ -5073,14 +5073,14 @@ export interface TypeChecker {
50735073 // TODO: GH#18217 `xToDeclaration` calls are frequently asserted as defined.
50745074 /** Note that the resulting nodes cannot be checked. */
50755075 typeToTypeNode ( type : Type , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined ) : TypeNode | undefined ;
5076- /** @internal */ typeToTypeNode ( type : Type , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , tracker ?: SymbolTracker ) : TypeNode | undefined ; // eslint-disable-line @typescript-eslint/unified-signatures
5077- /** @internal */ typePredicateToTypePredicateNode ( typePredicate : TypePredicate , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , tracker ?: SymbolTracker ) : TypePredicateNode | undefined ;
5076+ /** @internal */ typeToTypeNode ( type : Type , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , internalFlags ?: InternalNodeBuilderFlags | undefined , tracker ?: SymbolTracker ) : TypeNode | undefined ; // eslint-disable-line @typescript-eslint/unified-signatures
5077+ /** @internal */ typePredicateToTypePredicateNode ( typePredicate : TypePredicate , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , internalFlags ?: InternalNodeBuilderFlags | undefined , tracker ?: SymbolTracker ) : TypePredicateNode | undefined ;
50785078 /** Note that the resulting nodes cannot be checked. */
50795079 signatureToSignatureDeclaration ( signature : Signature , kind : SyntaxKind , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined ) : SignatureDeclaration & { typeArguments ?: NodeArray < TypeNode > ; } | undefined ;
5080- /** @internal */ signatureToSignatureDeclaration ( signature : Signature , kind : SyntaxKind , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , tracker ?: SymbolTracker ) : SignatureDeclaration & { typeArguments ?: NodeArray < TypeNode > ; } | undefined ; // eslint-disable-line @typescript-eslint/unified-signatures
5080+ /** @internal */ signatureToSignatureDeclaration ( signature : Signature , kind : SyntaxKind , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , internalFlags ?: InternalNodeBuilderFlags | undefined , tracker ?: SymbolTracker ) : SignatureDeclaration & { typeArguments ?: NodeArray < TypeNode > ; } | undefined ; // eslint-disable-line @typescript-eslint/unified-signatures
50815081 /** Note that the resulting nodes cannot be checked. */
50825082 indexInfoToIndexSignatureDeclaration ( indexInfo : IndexInfo , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined ) : IndexSignatureDeclaration | undefined ;
5083- /** @internal */ indexInfoToIndexSignatureDeclaration ( indexInfo : IndexInfo , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , tracker ?: SymbolTracker ) : IndexSignatureDeclaration | undefined ; // eslint-disable-line @typescript-eslint/unified-signatures
5083+ /** @internal */ indexInfoToIndexSignatureDeclaration ( indexInfo : IndexInfo , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , internalFlags ?: InternalNodeBuilderFlags | undefined , tracker ?: SymbolTracker ) : IndexSignatureDeclaration | undefined ; // eslint-disable-line @typescript-eslint/unified-signatures
50845084 /** Note that the resulting nodes cannot be checked. */
50855085 symbolToEntityName ( symbol : Symbol , meaning : SymbolFlags , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined ) : EntityName | undefined ;
50865086 /** Note that the resulting nodes cannot be checked. */
@@ -5090,7 +5090,7 @@ export interface TypeChecker {
50905090 *
50915091 * @internal
50925092 */
5093- symbolToNode ( symbol : Symbol , meaning : SymbolFlags , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined ) : Node | undefined ;
5093+ symbolToNode ( symbol : Symbol , meaning : SymbolFlags , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined , internalFlags : InternalNodeBuilderFlags | undefined ) : Node | undefined ;
50945094 /** Note that the resulting nodes cannot be checked. */
50955095 symbolToTypeParameterDeclarations ( symbol : Symbol , enclosingDeclaration : Node | undefined , flags : NodeBuilderFlags | undefined ) : NodeArray < TypeParameterDeclaration > | undefined ;
50965096 /** Note that the resulting nodes cannot be checked. */
@@ -5459,12 +5459,9 @@ export const enum NodeBuilderFlags {
54595459 AllowEmptyTuple = 1 << 19 ,
54605460 AllowUniqueESSymbolType = 1 << 20 ,
54615461 AllowEmptyIndexInfoType = 1 << 21 ,
5462- /** @internal */ WriteComputedProps = 1 << 30 , // { [E.A]: 1 }
5463- /** @internal */ NoSyntacticPrinter = 1 << 31 ,
54645462 // Errors (cont.)
54655463 AllowNodeModulesRelativePaths = 1 << 26 ,
5466- /** @internal */ DoNotIncludeSymbolChain = 1 << 27 , // Skip looking up and printing an accessible symbol chain
5467- /** @internal */ AllowUnresolvedNames = 1 << 32 ,
5464+
54685465
54695466 IgnoreErrors = AllowThisInObjectLiteral | AllowQualifiedNameInPlaceOfIdentifier | AllowAnonymousIdentifier | AllowEmptyUnionOrIntersection | AllowEmptyTuple | AllowEmptyIndexInfoType | AllowNodeModulesRelativePaths ,
54705467
@@ -5474,6 +5471,16 @@ export const enum NodeBuilderFlags {
54745471 InInitialEntityName = 1 << 24 , // Set when writing the LHS of an entity name or entity name expression
54755472}
54765473
5474+ /** @internal */
5475+ // dprint-ignore
5476+ export const enum InternalNodeBuilderFlags {
5477+ None = 0 ,
5478+ WriteComputedProps = 1 << 0 , // { [E.A]: 1 }
5479+ NoSyntacticPrinter = 1 << 1 ,
5480+ DoNotIncludeSymbolChain = 1 << 2 , // Skip looking up and printing an accessible symbol chain
5481+ AllowUnresolvedNames = 1 << 3 ,
5482+ }
5483+
54775484// Ensure the shared flags between this and `NodeBuilderFlags` stay in alignment
54785485// dprint-ignore
54795486export const enum TypeFormatFlags {
@@ -5810,9 +5817,9 @@ export interface EmitResolver {
58105817 requiresAddingImplicitUndefined ( node : ParameterDeclaration ) : boolean ;
58115818 isExpandoFunctionDeclaration ( node : FunctionDeclaration | VariableDeclaration ) : boolean ;
58125819 getPropertiesOfContainerFunction ( node : Declaration ) : Symbol [ ] ;
5813- createTypeOfDeclaration ( declaration : AccessorDeclaration | VariableLikeDeclaration | PropertyAccessExpression | ElementAccessExpression | BinaryExpression , enclosingDeclaration : Node , flags : NodeBuilderFlags , tracker : SymbolTracker ) : TypeNode | undefined ;
5814- createReturnTypeOfSignatureDeclaration ( signatureDeclaration : SignatureDeclaration , enclosingDeclaration : Node , flags : NodeBuilderFlags , tracker : SymbolTracker ) : TypeNode | undefined ;
5815- createTypeOfExpression ( expr : Expression , enclosingDeclaration : Node , flags : NodeBuilderFlags , tracker : SymbolTracker ) : TypeNode | undefined ;
5820+ createTypeOfDeclaration ( declaration : AccessorDeclaration | VariableLikeDeclaration | PropertyAccessExpression | ElementAccessExpression | BinaryExpression , enclosingDeclaration : Node , flags : NodeBuilderFlags , internalFlags : InternalNodeBuilderFlags , tracker : SymbolTracker ) : TypeNode | undefined ;
5821+ createReturnTypeOfSignatureDeclaration ( signatureDeclaration : SignatureDeclaration , enclosingDeclaration : Node , flags : NodeBuilderFlags , internalFlags : InternalNodeBuilderFlags , tracker : SymbolTracker ) : TypeNode | undefined ;
5822+ createTypeOfExpression ( expr : Expression , enclosingDeclaration : Node , flags : NodeBuilderFlags , internalFlags : InternalNodeBuilderFlags , tracker : SymbolTracker ) : TypeNode | undefined ;
58165823 createLiteralConstValue ( node : VariableDeclaration | PropertyDeclaration | PropertySignature | ParameterDeclaration , tracker : SymbolTracker ) : Expression ;
58175824 isSymbolAccessible ( symbol : Symbol , enclosingDeclaration : Node | undefined , meaning : SymbolFlags | undefined , shouldComputeAliasToMarkVisible : boolean ) : SymbolAccessibilityResult ;
58185825 isEntityNameVisible ( entityName : EntityNameOrEntityNameExpression , enclosingDeclaration : Node ) : SymbolVisibilityResult ;
@@ -5829,7 +5836,7 @@ export interface EmitResolver {
58295836 getJsxFactoryEntity ( location ?: Node ) : EntityName | undefined ;
58305837 getJsxFragmentFactoryEntity ( location ?: Node ) : EntityName | undefined ;
58315838 isBindingCapturedByNode ( node : Node , decl : VariableDeclaration | BindingElement ) : boolean ;
5832- getDeclarationStatementsForSourceFile ( node : SourceFile , flags : NodeBuilderFlags , tracker : SymbolTracker ) : Statement [ ] | undefined ;
5839+ getDeclarationStatementsForSourceFile ( node : SourceFile , flags : NodeBuilderFlags , internalFlags : InternalNodeBuilderFlags , tracker : SymbolTracker ) : Statement [ ] | undefined ;
58335840 isImportRequiredByAugmentation ( decl : ImportDeclaration ) : boolean ;
58345841 isDefinitelyReferenceToGlobalSymbolObject ( node : Node ) : boolean ;
58355842}
0 commit comments