diff --git a/internal/ast/diagnostic.go b/internal/ast/diagnostic.go index 7757501881..b8a597fbec 100644 --- a/internal/ast/diagnostic.go +++ b/internal/ast/diagnostic.go @@ -7,16 +7,20 @@ import ( "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnostics" + "github.com/microsoft/typescript-go/internal/locale" ) // Diagnostic type Diagnostic struct { - file *SourceFile - loc core.TextRange - code int32 - category diagnostics.Category - message string + file *SourceFile + loc core.TextRange + code int32 + category diagnostics.Category + // Original message; may be nil. + message *diagnostics.Message + messageKey diagnostics.Key + messageArgs []string messageChain []*Diagnostic relatedInformation []*Diagnostic reportsUnnecessary bool @@ -31,7 +35,8 @@ func (d *Diagnostic) Len() int { return d.loc.Len() } func (d *Diagnostic) Loc() core.TextRange { return d.loc } func (d *Diagnostic) Code() int32 { return d.code } func (d *Diagnostic) Category() diagnostics.Category { return d.category } -func (d *Diagnostic) Message() string { return d.message } +func (d *Diagnostic) MessageKey() diagnostics.Key { return d.messageKey } +func (d *Diagnostic) MessageArgs() []string { return d.messageArgs } func (d *Diagnostic) MessageChain() []*Diagnostic { return d.messageChain } func (d *Diagnostic) RelatedInformation() []*Diagnostic { return d.relatedInformation } func (d *Diagnostic) ReportsUnnecessary() bool { return d.reportsUnnecessary } @@ -72,12 +77,22 @@ func (d *Diagnostic) Clone() *Diagnostic { return &result } -func NewDiagnosticWith( +func (d *Diagnostic) Localize(locale locale.Locale) string { + return diagnostics.Localize(locale, d.message, d.messageKey, d.messageArgs...) +} + +// For debugging only. +func (d *Diagnostic) String() string { + return diagnostics.Localize(locale.Default, d.message, d.messageKey, d.messageArgs...) +} + +func NewDiagnosticFromSerialized( file *SourceFile, loc core.TextRange, code int32, category diagnostics.Category, - message string, + messageKey diagnostics.Key, + messageArgs []string, messageChain []*Diagnostic, relatedInformation []*Diagnostic, reportsUnnecessary bool, @@ -89,7 +104,8 @@ func NewDiagnosticWith( loc: loc, code: code, category: category, - message: message, + messageKey: messageKey, + messageArgs: messageArgs, messageChain: messageChain, relatedInformation: relatedInformation, reportsUnnecessary: reportsUnnecessary, @@ -104,7 +120,9 @@ func NewDiagnostic(file *SourceFile, loc core.TextRange, message *diagnostics.Me loc: loc, code: message.Code(), category: message.Category(), - message: message.Format(args...), + message: message, + messageKey: message.Key(), + messageArgs: diagnostics.StringifyArgs(args), reportsUnnecessary: message.ReportsUnnecessary(), reportsDeprecated: message.ReportsDeprecated(), } @@ -185,13 +203,13 @@ func EqualDiagnosticsNoRelatedInfo(d1, d2 *Diagnostic) bool { return getDiagnosticPath(d1) == getDiagnosticPath(d2) && d1.Loc() == d2.Loc() && d1.Code() == d2.Code() && - d1.Message() == d2.Message() && + slices.Equal(d1.MessageArgs(), d2.MessageArgs()) && slices.EqualFunc(d1.MessageChain(), d2.MessageChain(), equalMessageChain) } func equalMessageChain(c1, c2 *Diagnostic) bool { return c1.Code() == c2.Code() && - c1.Message() == c2.Message() && + slices.Equal(c1.MessageArgs(), c2.MessageArgs()) && slices.EqualFunc(c1.MessageChain(), c2.MessageChain(), equalMessageChain) } @@ -211,7 +229,7 @@ func compareMessageChainSize(c1, c2 []*Diagnostic) int { func compareMessageChainContent(c1, c2 []*Diagnostic) int { for i := range c1 { - c := strings.Compare(c1[i].Message(), c2[i].Message()) + c := slices.Compare(c1[i].MessageArgs(), c2[i].MessageArgs()) if c != 0 { return c } @@ -256,7 +274,7 @@ func CompareDiagnostics(d1, d2 *Diagnostic) int { if c != 0 { return c } - c = strings.Compare(d1.Message(), d2.Message()) + c = slices.Compare(d1.MessageArgs(), d2.MessageArgs()) if c != 0 { return c } diff --git a/internal/bundled/generate.go b/internal/bundled/generate.go index c39032bcd9..28b64e3a15 100644 --- a/internal/bundled/generate.go +++ b/internal/bundled/generate.go @@ -14,6 +14,7 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/core" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/parser" "github.com/microsoft/typescript-go/internal/repo" "github.com/microsoft/typescript-go/internal/tspath" @@ -150,7 +151,7 @@ func readLibs() []lib { if len(diags) > 0 { for _, diag := range diags { - log.Printf("%s", diag.Message()) + log.Printf("%s", diag.Localize(locale.Default)) } log.Fatalf("failed to parse libs.json") } diff --git a/internal/checker/jsx.go b/internal/checker/jsx.go index 9ab6699ea1..8abf107c9d 100644 --- a/internal/checker/jsx.go +++ b/internal/checker/jsx.go @@ -297,7 +297,7 @@ func (c *Checker) elaborateJsxComponents(node *ast.Node, source *Type, target *T if !ast.IsJsxSpreadAttribute(prop) && !isHyphenatedJsxName(prop.Name().Text()) { nameType := c.getStringLiteralType(prop.Name().Text()) if nameType != nil && nameType.flags&TypeFlagsNever == 0 { - reportedError = c.elaborateElement(source, target, relation, prop.Name(), prop.Initializer(), nameType, nil, diagnosticOutput) || reportedError + reportedError = c.elaborateElement(source, target, relation, prop.Name(), prop.Initializer(), nameType, nil, nil, diagnosticOutput) || reportedError } } } @@ -326,13 +326,14 @@ func (c *Checker) elaborateJsxComponents(node *ast.Node, source *Type, target *T nonArrayLikeTargetParts = c.filterType(childrenTargetType, func(t *Type) bool { return !c.isArrayOrTupleLikeType(t) }) } var invalidTextDiagnostic *diagnostics.Message - getInvalidTextualChildDiagnostic := func() *diagnostics.Message { + var invalidTextDiagnosticArgs []any + getInvalidTextualChildDiagnostic := func() (*diagnostics.Message, []any) { if invalidTextDiagnostic == nil { tagNameText := scanner.GetTextOfNode(node.Parent.TagName()) - diagnostic := diagnostics.X_0_components_don_t_accept_text_as_child_elements_Text_in_JSX_has_the_type_string_but_the_expected_type_of_1_is_2 - invalidTextDiagnostic = diagnostics.FormatMessage(diagnostic, tagNameText, childrenPropName, c.TypeToString(childrenTargetType)) + invalidTextDiagnostic = diagnostics.X_0_components_don_t_accept_text_as_child_elements_Text_in_JSX_has_the_type_string_but_the_expected_type_of_1_is_2 + invalidTextDiagnosticArgs = []any{tagNameText, childrenPropName, c.TypeToString(childrenTargetType)} } - return invalidTextDiagnostic + return invalidTextDiagnostic, invalidTextDiagnosticArgs } if moreThanOneRealChildren { if arrayLikeTargetParts != c.neverType { @@ -350,7 +351,7 @@ func (c *Checker) elaborateJsxComponents(node *ast.Node, source *Type, target *T child := validChildren[0] e := c.getElaborationElementForJsxChild(child, childrenNameType, getInvalidTextualChildDiagnostic) if e.errorNode != nil { - reportedError = c.elaborateElement(source, target, relation, e.errorNode, e.innerExpression, e.nameType, e.errorMessage, diagnosticOutput) || reportedError + reportedError = c.elaborateElement(source, target, relation, e.errorNode, e.innerExpression, e.nameType, nil, e.createDiagnostic, diagnosticOutput) || reportedError } } else if !c.isTypeRelatedTo(c.getIndexedAccessType(source, childrenNameType), childrenTargetType, relation) { // arity mismatch @@ -364,13 +365,13 @@ func (c *Checker) elaborateJsxComponents(node *ast.Node, source *Type, target *T } type JsxElaborationElement struct { - errorNode *ast.Node - innerExpression *ast.Node - nameType *Type - errorMessage *diagnostics.Message + errorNode *ast.Node + innerExpression *ast.Node + nameType *Type + createDiagnostic func(prop *ast.Node) *ast.Diagnostic // Optional: creates a custom diagnostic for this element } -func (c *Checker) generateJsxChildren(node *ast.Node, getInvalidTextDiagnostic func() *diagnostics.Message) iter.Seq[JsxElaborationElement] { +func (c *Checker) generateJsxChildren(node *ast.Node, getInvalidTextDiagnostic func() (*diagnostics.Message, []any)) iter.Seq[JsxElaborationElement] { return func(yield func(JsxElaborationElement) bool) { memberOffset := 0 for i, child := range node.Children().Nodes { @@ -387,7 +388,7 @@ func (c *Checker) generateJsxChildren(node *ast.Node, getInvalidTextDiagnostic f } } -func (c *Checker) getElaborationElementForJsxChild(child *ast.Node, nameType *Type, getInvalidTextDiagnostic func() *diagnostics.Message) JsxElaborationElement { +func (c *Checker) getElaborationElementForJsxChild(child *ast.Node, nameType *Type, getInvalidTextDiagnostic func() (*diagnostics.Message, []any)) JsxElaborationElement { switch child.Kind { case ast.KindJsxExpression: // child is of the type of the expression @@ -398,7 +399,15 @@ func (c *Checker) getElaborationElementForJsxChild(child *ast.Node, nameType *Ty return JsxElaborationElement{} } // child is a string - return JsxElaborationElement{errorNode: child, innerExpression: nil, nameType: nameType, errorMessage: getInvalidTextDiagnostic()} + return JsxElaborationElement{ + errorNode: child, + innerExpression: nil, + nameType: nameType, + createDiagnostic: func(prop *ast.Node) *ast.Diagnostic { + errorMessage, errorArgs := getInvalidTextDiagnostic() + return NewDiagnosticForNode(prop, errorMessage, errorArgs...) + }, + } case ast.KindJsxElement, ast.KindJsxSelfClosingElement, ast.KindJsxFragment: // child is of type JSX.Element return JsxElaborationElement{errorNode: child, innerExpression: child, nameType: nameType} @@ -448,7 +457,10 @@ func (c *Checker) elaborateIterableOrArrayLikeTargetElementwise(iterator iter.Se if next != nil { specificSource = c.checkExpressionForMutableLocationWithContextualType(next, sourcePropType) } - if c.exactOptionalPropertyTypes && c.isExactOptionalPropertyMismatch(specificSource, targetPropType) { + if e.createDiagnostic != nil { + // Use the custom diagnostic factory if provided (e.g., for JSX text children with dynamic error messages) + c.reportDiagnostic(e.createDiagnostic(prop), diagnosticOutput) + } else if c.exactOptionalPropertyTypes && c.isExactOptionalPropertyMismatch(specificSource, targetPropType) { diag := createDiagnosticForNode(prop, diagnostics.Type_0_is_not_assignable_to_type_1_with_exactOptionalPropertyTypes_Colon_true_Consider_adding_undefined_to_the_type_of_the_target, c.TypeToString(specificSource), c.TypeToString(targetPropType)) c.reportDiagnostic(diag, diagnosticOutput) } else { @@ -456,10 +468,10 @@ func (c *Checker) elaborateIterableOrArrayLikeTargetElementwise(iterator iter.Se sourceIsOptional := propName != ast.InternalSymbolNameMissing && core.OrElse(c.getPropertyOfType(source, propName), c.unknownSymbol).Flags&ast.SymbolFlagsOptional != 0 targetPropType = c.removeMissingType(targetPropType, targetIsOptional) sourcePropType = c.removeMissingType(sourcePropType, targetIsOptional && sourceIsOptional) - result := c.checkTypeRelatedToEx(specificSource, targetPropType, relation, prop, e.errorMessage, diagnosticOutput) + result := c.checkTypeRelatedToEx(specificSource, targetPropType, relation, prop, nil, diagnosticOutput) if result && specificSource != sourcePropType { // If for whatever reason the expression type doesn't yield an error, make sure we still issue an error on the sourcePropType - c.checkTypeRelatedToEx(sourcePropType, targetPropType, relation, prop, e.errorMessage, diagnosticOutput) + c.checkTypeRelatedToEx(sourcePropType, targetPropType, relation, prop, nil, diagnosticOutput) } } } diff --git a/internal/checker/relater.go b/internal/checker/relater.go index 199eb76ad9..db83af0745 100644 --- a/internal/checker/relater.go +++ b/internal/checker/relater.go @@ -503,10 +503,10 @@ func (c *Checker) elaborateObjectLiteral(node *ast.Node, source *Type, target *T } switch prop.Kind { case ast.KindSetAccessor, ast.KindGetAccessor, ast.KindMethodDeclaration, ast.KindShorthandPropertyAssignment: - reportedError = c.elaborateElement(source, target, relation, prop.Name(), nil, nameType, nil, diagnosticOutput) || reportedError + reportedError = c.elaborateElement(source, target, relation, prop.Name(), nil, nameType, nil, nil, diagnosticOutput) || reportedError case ast.KindPropertyAssignment: message := core.IfElse(ast.IsComputedNonLiteralName(prop.Name()), diagnostics.Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1, nil) - reportedError = c.elaborateElement(source, target, relation, prop.Name(), prop.Initializer(), nameType, message, diagnosticOutput) || reportedError + reportedError = c.elaborateElement(source, target, relation, prop.Name(), prop.Initializer(), nameType, message, nil, diagnosticOutput) || reportedError } } return reportedError @@ -531,12 +531,12 @@ func (c *Checker) elaborateArrayLiteral(node *ast.Node, source *Type, target *Ty } nameType := c.getNumberLiteralType(jsnum.Number(i)) checkNode := c.getEffectiveCheckNode(element) - reportedError = c.elaborateElement(source, target, relation, checkNode, checkNode, nameType, nil, diagnosticOutput) || reportedError + reportedError = c.elaborateElement(source, target, relation, checkNode, checkNode, nameType, nil, nil, diagnosticOutput) || reportedError } return reportedError } -func (c *Checker) elaborateElement(source *Type, target *Type, relation *Relation, prop *ast.Node, next *ast.Node, nameType *Type, errorMessage *diagnostics.Message, diagnosticOutput *[]*ast.Diagnostic) bool { +func (c *Checker) elaborateElement(source *Type, target *Type, relation *Relation, prop *ast.Node, next *ast.Node, nameType *Type, errorMessage *diagnostics.Message, diagnosticFactory func(prop *ast.Node) *ast.Diagnostic, diagnosticOutput *[]*ast.Diagnostic) bool { targetPropType := c.getBestMatchIndexedAccessTypeOrUndefined(source, target, nameType) if targetPropType == nil || targetPropType.flags&TypeFlagsIndexedAccess != 0 { // Don't elaborate on indexes on generic variables @@ -557,7 +557,10 @@ func (c *Checker) elaborateElement(source *Type, target *Type, relation *Relatio if next != nil { specificSource = c.checkExpressionForMutableLocationWithContextualType(next, sourcePropType) } - if c.exactOptionalPropertyTypes && c.isExactOptionalPropertyMismatch(specificSource, targetPropType) { + if diagnosticFactory != nil { + // Use the custom diagnostic factory if provided (e.g., for JSX text children with dynamic error messages) + diags = append(diags, diagnosticFactory(prop)) + } else if c.exactOptionalPropertyTypes && c.isExactOptionalPropertyMismatch(specificSource, targetPropType) { diags = append(diags, createDiagnosticForNode(prop, diagnostics.Type_0_is_not_assignable_to_type_1_with_exactOptionalPropertyTypes_Colon_true_Consider_adding_undefined_to_the_type_of_the_target, c.TypeToString(specificSource), c.TypeToString(targetPropType))) } else { propName := c.getPropertyNameFromIndex(nameType, nil /*accessNode*/) diff --git a/internal/compiler/fileloader.go b/internal/compiler/fileloader.go index e1e84650d3..ef866d1921 100644 --- a/internal/compiler/fileloader.go +++ b/internal/compiler/fileloader.go @@ -18,7 +18,7 @@ import ( type libResolution struct { libraryName string resolution *module.ResolvedModule - trace []string + trace []module.DiagAndArgs } type LibFile struct { @@ -231,7 +231,7 @@ func processAllProgramFiles( module.ModeAwareCacheKey{Name: value.libraryName, Mode: core.ModuleKindCommonJS}: value.resolution, } for _, trace := range value.trace { - opts.Host.Trace(trace) + opts.Host.Trace(trace.Message, trace.Args...) } } @@ -286,7 +286,7 @@ func (p *fileLoader) addAutomaticTypeDirectiveTasks() { func (p *fileLoader) resolveAutomaticTypeDirectives(containingFileName string) ( toParse []resolvedRef, typeResolutionsInFile module.ModeAwareCache[*module.ResolvedTypeReferenceDirective], - typeResolutionsTrace []string, + typeResolutionsTrace []module.DiagAndArgs, ) { automaticTypeDirectiveNames := module.GetAutomaticTypeDirectiveNames(p.opts.Config.CompilerOptions(), p.opts.Host) if len(automaticTypeDirectiveNames) != 0 { @@ -449,7 +449,7 @@ func (p *fileLoader) resolveTypeReferenceDirectives(t *parseTask) { meta := t.metadata typeResolutionsInFile := make(module.ModeAwareCache[*module.ResolvedTypeReferenceDirective], len(file.TypeReferenceDirectives)) - var typeResolutionsTrace []string + var typeResolutionsTrace []module.DiagAndArgs for index, ref := range file.TypeReferenceDirectives { redirect, fileName := p.projectReferenceFileMapper.getRedirectForResolution(file) resolutionMode := getModeForTypeReferenceDirectiveInFile(ref, file, meta, module.GetCompilerOptionsWithRedirect(p.opts.Config.CompilerOptions(), redirect)) @@ -527,7 +527,7 @@ func (p *fileLoader) resolveImportsAndModuleAugmentations(t *parseTask) { if len(moduleNames) != 0 { resolutionsInFile := make(module.ModeAwareCache[*module.ResolvedModule], len(moduleNames)) - var resolutionsTrace []string + var resolutionsTrace []module.DiagAndArgs for index, entry := range moduleNames { moduleName := entry.Text() diff --git a/internal/compiler/filesparser.go b/internal/compiler/filesparser.go index abf767ed34..554ca47327 100644 --- a/internal/compiler/filesparser.go +++ b/internal/compiler/filesparser.go @@ -25,9 +25,9 @@ type parseTask struct { metadata ast.SourceFileMetaData resolutionsInFile module.ModeAwareCache[*module.ResolvedModule] - resolutionsTrace []string + resolutionsTrace []module.DiagAndArgs typeResolutionsInFile module.ModeAwareCache[*module.ResolvedTypeReferenceDirective] - typeResolutionsTrace []string + typeResolutionsTrace []module.DiagAndArgs resolutionDiagnostics []*ast.Diagnostic importHelpersImportSpecifier *ast.Node jsxRuntimeImportSpecifier *jsxRuntimeImportSpecifier @@ -255,10 +255,10 @@ func (w *filesParser) collectWorker(loader *fileLoader, tasks []*parseTask, iter continue } for _, trace := range task.typeResolutionsTrace { - loader.opts.Host.Trace(trace) + loader.opts.Host.Trace(trace.Message, trace.Args...) } for _, trace := range task.resolutionsTrace { - loader.opts.Host.Trace(trace) + loader.opts.Host.Trace(trace.Message, trace.Args...) } if subTasks := task.subTasks; len(subTasks) > 0 { w.collectWorker(loader, subTasks, iterate, seen) diff --git a/internal/compiler/host.go b/internal/compiler/host.go index 68f3cf620a..72936acc65 100644 --- a/internal/compiler/host.go +++ b/internal/compiler/host.go @@ -3,6 +3,7 @@ package compiler import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/core" + "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/parser" "github.com/microsoft/typescript-go/internal/tsoptions" "github.com/microsoft/typescript-go/internal/tspath" @@ -14,7 +15,7 @@ type CompilerHost interface { FS() vfs.FS DefaultLibraryPath() string GetCurrentDirectory() string - Trace(msg string) + Trace(msg *diagnostics.Message, args ...any) GetSourceFile(opts ast.SourceFileParseOptions) *ast.SourceFile GetResolvedProjectReference(fileName string, path tspath.Path) *tsoptions.ParsedCommandLine } @@ -26,7 +27,7 @@ type compilerHost struct { fs vfs.FS defaultLibraryPath string extendedConfigCache tsoptions.ExtendedConfigCache - trace func(msg string) + trace func(msg *diagnostics.Message, args ...any) } func NewCachedFSCompilerHost( @@ -34,7 +35,7 @@ func NewCachedFSCompilerHost( fs vfs.FS, defaultLibraryPath string, extendedConfigCache tsoptions.ExtendedConfigCache, - trace func(msg string), + trace func(msg *diagnostics.Message, args ...any), ) CompilerHost { return NewCompilerHost(currentDirectory, cachedvfs.From(fs), defaultLibraryPath, extendedConfigCache, trace) } @@ -44,10 +45,10 @@ func NewCompilerHost( fs vfs.FS, defaultLibraryPath string, extendedConfigCache tsoptions.ExtendedConfigCache, - trace func(msg string), + trace func(msg *diagnostics.Message, args ...any), ) CompilerHost { if trace == nil { - trace = func(msg string) {} + trace = func(msg *diagnostics.Message, args ...any) {} } return &compilerHost{ currentDirectory: currentDirectory, @@ -70,8 +71,8 @@ func (h *compilerHost) GetCurrentDirectory() string { return h.currentDirectory } -func (h *compilerHost) Trace(msg string) { - h.trace(msg) +func (h *compilerHost) Trace(msg *diagnostics.Message, args ...any) { + h.trace(msg, args...) } func (h *compilerHost) GetSourceFile(opts ast.SourceFileParseOptions) *ast.SourceFile { diff --git a/internal/compiler/program.go b/internal/compiler/program.go index c8f631114a..f773a45e59 100644 --- a/internal/compiler/program.go +++ b/internal/compiler/program.go @@ -17,6 +17,7 @@ import ( "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnostics" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/module" "github.com/microsoft/typescript-go/internal/modulespecifiers" "github.com/microsoft/typescript-go/internal/outputpaths" @@ -1568,17 +1569,17 @@ func (p *Program) IsMissingPath(path tspath.Path) bool { }) } -func (p *Program) ExplainFiles(w io.Writer) { +func (p *Program) ExplainFiles(w io.Writer, locale locale.Locale) { toRelativeFileName := func(fileName string) string { return tspath.GetRelativePathFromDirectory(p.GetCurrentDirectory(), fileName, p.comparePathsOptions) } for _, file := range p.GetSourceFiles() { fmt.Fprintln(w, toRelativeFileName(file.FileName())) for _, reason := range p.includeProcessor.fileIncludeReasons[file.Path()] { - fmt.Fprintln(w, " ", reason.toDiagnostic(p, true).Message()) + fmt.Fprintln(w, " ", reason.toDiagnostic(p, true).Localize(locale)) } for _, diag := range p.includeProcessor.explainRedirectAndImpliedFormat(p, file, toRelativeFileName) { - fmt.Fprintln(w, " ", diag.Message()) + fmt.Fprintln(w, " ", diag.Localize(locale)) } } } diff --git a/internal/core/context.go b/internal/core/context.go index ddd019208f..394fcf4561 100644 --- a/internal/core/context.go +++ b/internal/core/context.go @@ -2,15 +2,12 @@ package core import ( "context" - - "golang.org/x/text/language" ) type key int const ( requestIDKey key = iota - localeKey ) func WithRequestID(ctx context.Context, id string) context.Context { @@ -23,14 +20,3 @@ func GetRequestID(ctx context.Context) string { } return "" } - -func WithLocale(ctx context.Context, locale language.Tag) context.Context { - return context.WithValue(ctx, localeKey, locale) -} - -func GetLocale(ctx context.Context) language.Tag { - if locale, ok := ctx.Value(localeKey).(language.Tag); ok { - return locale - } - return language.Und -} diff --git a/internal/diagnostics/diagnostics.go b/internal/diagnostics/diagnostics.go index df6e05de49..aaf238680b 100644 --- a/internal/diagnostics/diagnostics.go +++ b/internal/diagnostics/diagnostics.go @@ -1,11 +1,19 @@ // Package diagnostics contains generated localizable diagnostic messages. package diagnostics -import "github.com/microsoft/typescript-go/internal/stringutil" +import ( + "fmt" + "regexp" + "strconv" + "sync" -//go:generate go run generate.go -output ./diagnostics_generated.go + "github.com/microsoft/typescript-go/internal/locale" + "golang.org/x/text/language" +) + +//go:generate go run generate.go -diagnostics ./diagnostics_generated.go -loc ./loc_generated.go -locdir ./loc //go:generate go tool golang.org/x/tools/cmd/stringer -type=Category -output=stringer_generated.go -//go:generate go tool mvdan.cc/gofumpt -w diagnostics_generated.go stringer_generated.go +//go:generate go tool mvdan.cc/gofumpt -w diagnostics_generated.go loc_generated.go stringer_generated.go type Category int32 @@ -30,10 +38,12 @@ func (category Category) Name() string { panic("Unhandled diagnostic category") } +type Key string + type Message struct { code int32 category Category - key string + key Key text string reportsUnnecessary bool elidedInCompatibilityPyramid bool @@ -42,22 +52,92 @@ type Message struct { func (m *Message) Code() int32 { return m.code } func (m *Message) Category() Category { return m.category } -func (m *Message) Key() string { return m.key } -func (m *Message) Message() string { return m.text } +func (m *Message) Key() Key { return m.key } func (m *Message) ReportsUnnecessary() bool { return m.reportsUnnecessary } func (m *Message) ElidedInCompatibilityPyramid() bool { return m.elidedInCompatibilityPyramid } func (m *Message) ReportsDeprecated() bool { return m.reportsDeprecated } -func (m *Message) Format(args ...any) string { - text := m.Message() - if len(args) != 0 { - text = stringutil.Format(text, args) +// For debugging only. +func (m *Message) String() string { + return m.text +} + +func (m *Message) Localize(locale locale.Locale, args ...any) string { + return Localize(locale, m, "", StringifyArgs(args)...) +} + +func Localize(locale locale.Locale, message *Message, key Key, args ...string) string { + if message == nil { + message = keyToMessage(key) + } + if message == nil { + panic("Unknown diagnostic message: " + string(key)) } - return text + + text := message.text + if localized, ok := getLocalizedMessages(language.Tag(locale))[message.key]; ok { + text = localized + } + + return Format(text, args) } -func FormatMessage(m *Message, args ...any) *Message { - result := *m - result.text = stringutil.Format(m.text, args) - return &result +var localizedMessagesCache sync.Map // map[language.Tag]map[Key]string + +func getLocalizedMessages(loc language.Tag) map[Key]string { + if loc == language.Und { + return nil + } + + // Check cache first + if cached, ok := localizedMessagesCache.Load(loc); ok { + if cached == nil { + return nil + } + return cached.(map[Key]string) + } + + var messages map[Key]string + + _, index, confidence := matcher.Match(loc) + if confidence >= language.Low && index >= 0 && index < len(localeFuncs) { + if fn := localeFuncs[index]; fn != nil { + messages = fn() + } + } + + localizedMessagesCache.Store(loc, messages) + return messages +} + +var placeholderRegexp = regexp.MustCompile(`{(\d+)}`) + +func Format(text string, args []string) string { + if len(args) == 0 { + return text + } + + return placeholderRegexp.ReplaceAllStringFunc(text, func(match string) string { + index, err := strconv.ParseInt(match[1:len(match)-1], 10, 0) + if err != nil || int(index) >= len(args) { + panic("Invalid formatting placeholder") + } + return args[int(index)] + }) +} + +func StringifyArgs(args []any) []string { + if len(args) == 0 { + return nil + } + + result := make([]string, len(args)) + for i, arg := range args { + if s, ok := arg.(string); ok { + result[i] = s + } else { + result[i] = fmt.Sprintf("%v", arg) + } + } + return result } diff --git a/internal/diagnostics/diagnostics_generated.go b/internal/diagnostics/diagnostics_generated.go index 7cfec6d219..50df22ce10 100644 --- a/internal/diagnostics/diagnostics_generated.go +++ b/internal/diagnostics/diagnostics_generated.go @@ -2436,7 +2436,7 @@ var Unterminated_quoted_string_in_response_file_0 = &Message{code: 6045, categor var Argument_for_0_option_must_be_Colon_1 = &Message{code: 6046, category: CategoryError, key: "Argument_for_0_option_must_be_Colon_1_6046", text: "Argument for '{0}' option must be: {1}."} -var Locale_must_be_of_the_form_language_or_language_territory_For_example_0_or_1 = &Message{code: 6048, category: CategoryError, key: "Locale_must_be_of_the_form_language_or_language_territory_For_example_0_or_1_6048", text: "Locale must be of the form or -. For example '{0}' or '{1}'."} +var Locale_must_be_an_IETF_BCP_47_language_tag_Examples_Colon_0_1 = &Message{code: 6048, category: CategoryError, key: "Locale_must_be_an_IETF_BCP_47_language_tag_Examples_Colon_0_1_6048", text: "Locale must be an IETF BCP 47 language tag. Examples: '{0}', '{1}'."} var Unable_to_open_file_0 = &Message{code: 6050, category: CategoryError, key: "Unable_to_open_file_0_6050", text: "Unable to open file '{0}'."} @@ -4257,3 +4257,4266 @@ var Generate_pprof_CPU_Slashmemory_profiles_to_the_given_directory = &Message{co var Set_the_number_of_checkers_per_project = &Message{code: 100003, category: CategoryMessage, key: "Set_the_number_of_checkers_per_project_100003", text: "Set the number of checkers per project."} var X_4_unless_singleThreaded_is_passed = &Message{code: 100004, category: CategoryMessage, key: "4_unless_singleThreaded_is_passed_100004", text: "4, unless --singleThreaded is passed."} + +func keyToMessage(key Key) *Message { + switch key { + case "Unterminated_string_literal_1002": + return Unterminated_string_literal + case "Identifier_expected_1003": + return Identifier_expected + case "_0_expected_1005": + return X_0_expected + case "A_file_cannot_have_a_reference_to_itself_1006": + return A_file_cannot_have_a_reference_to_itself + case "The_parser_expected_to_find_a_1_to_match_the_0_token_here_1007": + return The_parser_expected_to_find_a_1_to_match_the_0_token_here + case "Trailing_comma_not_allowed_1009": + return Trailing_comma_not_allowed + case "Asterisk_Slash_expected_1010": + return Asterisk_Slash_expected + case "An_element_access_expression_should_take_an_argument_1011": + return An_element_access_expression_should_take_an_argument + case "Unexpected_token_1012": + return Unexpected_token + case "A_rest_parameter_or_binding_pattern_may_not_have_a_trailing_comma_1013": + return A_rest_parameter_or_binding_pattern_may_not_have_a_trailing_comma + case "A_rest_parameter_must_be_last_in_a_parameter_list_1014": + return A_rest_parameter_must_be_last_in_a_parameter_list + case "Parameter_cannot_have_question_mark_and_initializer_1015": + return Parameter_cannot_have_question_mark_and_initializer + case "A_required_parameter_cannot_follow_an_optional_parameter_1016": + return A_required_parameter_cannot_follow_an_optional_parameter + case "An_index_signature_cannot_have_a_rest_parameter_1017": + return An_index_signature_cannot_have_a_rest_parameter + case "An_index_signature_parameter_cannot_have_an_accessibility_modifier_1018": + return An_index_signature_parameter_cannot_have_an_accessibility_modifier + case "An_index_signature_parameter_cannot_have_a_question_mark_1019": + return An_index_signature_parameter_cannot_have_a_question_mark + case "An_index_signature_parameter_cannot_have_an_initializer_1020": + return An_index_signature_parameter_cannot_have_an_initializer + case "An_index_signature_must_have_a_type_annotation_1021": + return An_index_signature_must_have_a_type_annotation + case "An_index_signature_parameter_must_have_a_type_annotation_1022": + return An_index_signature_parameter_must_have_a_type_annotation + case "readonly_modifier_can_only_appear_on_a_property_declaration_or_index_signature_1024": + return X_readonly_modifier_can_only_appear_on_a_property_declaration_or_index_signature + case "An_index_signature_cannot_have_a_trailing_comma_1025": + return An_index_signature_cannot_have_a_trailing_comma + case "Accessibility_modifier_already_seen_1028": + return Accessibility_modifier_already_seen + case "_0_modifier_must_precede_1_modifier_1029": + return X_0_modifier_must_precede_1_modifier + case "_0_modifier_already_seen_1030": + return X_0_modifier_already_seen + case "_0_modifier_cannot_appear_on_class_elements_of_this_kind_1031": + return X_0_modifier_cannot_appear_on_class_elements_of_this_kind + case "super_must_be_followed_by_an_argument_list_or_member_access_1034": + return X_super_must_be_followed_by_an_argument_list_or_member_access + case "Only_ambient_modules_can_use_quoted_names_1035": + return Only_ambient_modules_can_use_quoted_names + case "Statements_are_not_allowed_in_ambient_contexts_1036": + return Statements_are_not_allowed_in_ambient_contexts + case "A_declare_modifier_cannot_be_used_in_an_already_ambient_context_1038": + return A_declare_modifier_cannot_be_used_in_an_already_ambient_context + case "Initializers_are_not_allowed_in_ambient_contexts_1039": + return Initializers_are_not_allowed_in_ambient_contexts + case "_0_modifier_cannot_be_used_in_an_ambient_context_1040": + return X_0_modifier_cannot_be_used_in_an_ambient_context + case "_0_modifier_cannot_be_used_here_1042": + return X_0_modifier_cannot_be_used_here + case "_0_modifier_cannot_appear_on_a_module_or_namespace_element_1044": + return X_0_modifier_cannot_appear_on_a_module_or_namespace_element + case "Top_level_declarations_in_d_ts_files_must_start_with_either_a_declare_or_export_modifier_1046": + return Top_level_declarations_in_d_ts_files_must_start_with_either_a_declare_or_export_modifier + case "A_rest_parameter_cannot_be_optional_1047": + return A_rest_parameter_cannot_be_optional + case "A_rest_parameter_cannot_have_an_initializer_1048": + return A_rest_parameter_cannot_have_an_initializer + case "A_set_accessor_must_have_exactly_one_parameter_1049": + return A_set_accessor_must_have_exactly_one_parameter + case "A_set_accessor_cannot_have_an_optional_parameter_1051": + return A_set_accessor_cannot_have_an_optional_parameter + case "A_set_accessor_parameter_cannot_have_an_initializer_1052": + return A_set_accessor_parameter_cannot_have_an_initializer + case "A_set_accessor_cannot_have_rest_parameter_1053": + return A_set_accessor_cannot_have_rest_parameter + case "A_get_accessor_cannot_have_parameters_1054": + return A_get_accessor_cannot_have_parameters + case "Type_0_is_not_a_valid_async_function_return_type_in_ES5_because_it_does_not_refer_to_a_Promise_compa_1055": + return Type_0_is_not_a_valid_async_function_return_type_in_ES5_because_it_does_not_refer_to_a_Promise_compatible_constructor_value + case "Accessors_are_only_available_when_targeting_ECMAScript_5_and_higher_1056": + return Accessors_are_only_available_when_targeting_ECMAScript_5_and_higher + case "The_return_type_of_an_async_function_must_either_be_a_valid_promise_or_must_not_contain_a_callable_t_1058": + return The_return_type_of_an_async_function_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member + case "A_promise_must_have_a_then_method_1059": + return A_promise_must_have_a_then_method + case "The_first_parameter_of_the_then_method_of_a_promise_must_be_a_callback_1060": + return The_first_parameter_of_the_then_method_of_a_promise_must_be_a_callback + case "Enum_member_must_have_initializer_1061": + return Enum_member_must_have_initializer + case "Type_is_referenced_directly_or_indirectly_in_the_fulfillment_callback_of_its_own_then_method_1062": + return Type_is_referenced_directly_or_indirectly_in_the_fulfillment_callback_of_its_own_then_method + case "An_export_assignment_cannot_be_used_in_a_namespace_1063": + return An_export_assignment_cannot_be_used_in_a_namespace + case "The_return_type_of_an_async_function_or_method_must_be_the_global_Promise_T_type_Did_you_mean_to_wri_1064": + return The_return_type_of_an_async_function_or_method_must_be_the_global_Promise_T_type_Did_you_mean_to_write_Promise_0 + case "The_return_type_of_an_async_function_or_method_must_be_the_global_Promise_T_type_1065": + return The_return_type_of_an_async_function_or_method_must_be_the_global_Promise_T_type + case "In_ambient_enum_declarations_member_initializer_must_be_constant_expression_1066": + return In_ambient_enum_declarations_member_initializer_must_be_constant_expression + case "Unexpected_token_A_constructor_method_accessor_or_property_was_expected_1068": + return Unexpected_token_A_constructor_method_accessor_or_property_was_expected + case "Unexpected_token_A_type_parameter_name_was_expected_without_curly_braces_1069": + return Unexpected_token_A_type_parameter_name_was_expected_without_curly_braces + case "_0_modifier_cannot_appear_on_a_type_member_1070": + return X_0_modifier_cannot_appear_on_a_type_member + case "_0_modifier_cannot_appear_on_an_index_signature_1071": + return X_0_modifier_cannot_appear_on_an_index_signature + case "A_0_modifier_cannot_be_used_with_an_import_declaration_1079": + return A_0_modifier_cannot_be_used_with_an_import_declaration + case "Invalid_reference_directive_syntax_1084": + return Invalid_reference_directive_syntax + case "_0_modifier_cannot_appear_on_a_constructor_declaration_1089": + return X_0_modifier_cannot_appear_on_a_constructor_declaration + case "_0_modifier_cannot_appear_on_a_parameter_1090": + return X_0_modifier_cannot_appear_on_a_parameter + case "Only_a_single_variable_declaration_is_allowed_in_a_for_in_statement_1091": + return Only_a_single_variable_declaration_is_allowed_in_a_for_in_statement + case "Type_parameters_cannot_appear_on_a_constructor_declaration_1092": + return Type_parameters_cannot_appear_on_a_constructor_declaration + case "Type_annotation_cannot_appear_on_a_constructor_declaration_1093": + return Type_annotation_cannot_appear_on_a_constructor_declaration + case "An_accessor_cannot_have_type_parameters_1094": + return An_accessor_cannot_have_type_parameters + case "A_set_accessor_cannot_have_a_return_type_annotation_1095": + return A_set_accessor_cannot_have_a_return_type_annotation + case "An_index_signature_must_have_exactly_one_parameter_1096": + return An_index_signature_must_have_exactly_one_parameter + case "_0_list_cannot_be_empty_1097": + return X_0_list_cannot_be_empty + case "Type_parameter_list_cannot_be_empty_1098": + return Type_parameter_list_cannot_be_empty + case "Type_argument_list_cannot_be_empty_1099": + return Type_argument_list_cannot_be_empty + case "Invalid_use_of_0_in_strict_mode_1100": + return Invalid_use_of_0_in_strict_mode + case "with_statements_are_not_allowed_in_strict_mode_1101": + return X_with_statements_are_not_allowed_in_strict_mode + case "delete_cannot_be_called_on_an_identifier_in_strict_mode_1102": + return X_delete_cannot_be_called_on_an_identifier_in_strict_mode + case "for_await_loops_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules_1103": + return X_for_await_loops_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules + case "A_continue_statement_can_only_be_used_within_an_enclosing_iteration_statement_1104": + return A_continue_statement_can_only_be_used_within_an_enclosing_iteration_statement + case "A_break_statement_can_only_be_used_within_an_enclosing_iteration_or_switch_statement_1105": + return A_break_statement_can_only_be_used_within_an_enclosing_iteration_or_switch_statement + case "The_left_hand_side_of_a_for_of_statement_may_not_be_async_1106": + return The_left_hand_side_of_a_for_of_statement_may_not_be_async + case "Jump_target_cannot_cross_function_boundary_1107": + return Jump_target_cannot_cross_function_boundary + case "A_return_statement_can_only_be_used_within_a_function_body_1108": + return A_return_statement_can_only_be_used_within_a_function_body + case "Expression_expected_1109": + return Expression_expected + case "Type_expected_1110": + return Type_expected + case "Private_field_0_must_be_declared_in_an_enclosing_class_1111": + return Private_field_0_must_be_declared_in_an_enclosing_class + case "A_default_clause_cannot_appear_more_than_once_in_a_switch_statement_1113": + return A_default_clause_cannot_appear_more_than_once_in_a_switch_statement + case "Duplicate_label_0_1114": + return Duplicate_label_0 + case "A_continue_statement_can_only_jump_to_a_label_of_an_enclosing_iteration_statement_1115": + return A_continue_statement_can_only_jump_to_a_label_of_an_enclosing_iteration_statement + case "A_break_statement_can_only_jump_to_a_label_of_an_enclosing_statement_1116": + return A_break_statement_can_only_jump_to_a_label_of_an_enclosing_statement + case "An_object_literal_cannot_have_multiple_properties_with_the_same_name_1117": + return An_object_literal_cannot_have_multiple_properties_with_the_same_name + case "An_object_literal_cannot_have_multiple_get_Slashset_accessors_with_the_same_name_1118": + return An_object_literal_cannot_have_multiple_get_Slashset_accessors_with_the_same_name + case "An_object_literal_cannot_have_property_and_accessor_with_the_same_name_1119": + return An_object_literal_cannot_have_property_and_accessor_with_the_same_name + case "An_export_assignment_cannot_have_modifiers_1120": + return An_export_assignment_cannot_have_modifiers + case "Octal_literals_are_not_allowed_Use_the_syntax_0_1121": + return Octal_literals_are_not_allowed_Use_the_syntax_0 + case "Variable_declaration_list_cannot_be_empty_1123": + return Variable_declaration_list_cannot_be_empty + case "Digit_expected_1124": + return Digit_expected + case "Hexadecimal_digit_expected_1125": + return Hexadecimal_digit_expected + case "Unexpected_end_of_text_1126": + return Unexpected_end_of_text + case "Invalid_character_1127": + return Invalid_character + case "Declaration_or_statement_expected_1128": + return Declaration_or_statement_expected + case "Statement_expected_1129": + return Statement_expected + case "case_or_default_expected_1130": + return X_case_or_default_expected + case "Property_or_signature_expected_1131": + return Property_or_signature_expected + case "Enum_member_expected_1132": + return Enum_member_expected + case "Variable_declaration_expected_1134": + return Variable_declaration_expected + case "Argument_expression_expected_1135": + return Argument_expression_expected + case "Property_assignment_expected_1136": + return Property_assignment_expected + case "Expression_or_comma_expected_1137": + return Expression_or_comma_expected + case "Parameter_declaration_expected_1138": + return Parameter_declaration_expected + case "Type_parameter_declaration_expected_1139": + return Type_parameter_declaration_expected + case "Type_argument_expected_1140": + return Type_argument_expected + case "String_literal_expected_1141": + return String_literal_expected + case "Line_break_not_permitted_here_1142": + return Line_break_not_permitted_here + case "or_expected_1144": + return X_or_expected + case "or_JSX_element_expected_1145": + return X_or_JSX_element_expected + case "Declaration_expected_1146": + return Declaration_expected + case "Import_declarations_in_a_namespace_cannot_reference_a_module_1147": + return Import_declarations_in_a_namespace_cannot_reference_a_module + case "Cannot_use_imports_exports_or_module_augmentations_when_module_is_none_1148": + return Cannot_use_imports_exports_or_module_augmentations_when_module_is_none + case "File_name_0_differs_from_already_included_file_name_1_only_in_casing_1149": + return File_name_0_differs_from_already_included_file_name_1_only_in_casing + case "_0_declarations_must_be_initialized_1155": + return X_0_declarations_must_be_initialized + case "_0_declarations_can_only_be_declared_inside_a_block_1156": + return X_0_declarations_can_only_be_declared_inside_a_block + case "Unterminated_template_literal_1160": + return Unterminated_template_literal + case "Unterminated_regular_expression_literal_1161": + return Unterminated_regular_expression_literal + case "An_object_member_cannot_be_declared_optional_1162": + return An_object_member_cannot_be_declared_optional + case "A_yield_expression_is_only_allowed_in_a_generator_body_1163": + return A_yield_expression_is_only_allowed_in_a_generator_body + case "Computed_property_names_are_not_allowed_in_enums_1164": + return Computed_property_names_are_not_allowed_in_enums + case "A_computed_property_name_in_an_ambient_context_must_refer_to_an_expression_whose_type_is_a_literal_t_1165": + return A_computed_property_name_in_an_ambient_context_must_refer_to_an_expression_whose_type_is_a_literal_type_or_a_unique_symbol_type + case "A_computed_property_name_in_a_class_property_declaration_must_have_a_simple_literal_type_or_a_unique_1166": + return A_computed_property_name_in_a_class_property_declaration_must_have_a_simple_literal_type_or_a_unique_symbol_type + case "A_computed_property_name_in_a_method_overload_must_refer_to_an_expression_whose_type_is_a_literal_ty_1168": + return A_computed_property_name_in_a_method_overload_must_refer_to_an_expression_whose_type_is_a_literal_type_or_a_unique_symbol_type + case "A_computed_property_name_in_an_interface_must_refer_to_an_expression_whose_type_is_a_literal_type_or_1169": + return A_computed_property_name_in_an_interface_must_refer_to_an_expression_whose_type_is_a_literal_type_or_a_unique_symbol_type + case "A_computed_property_name_in_a_type_literal_must_refer_to_an_expression_whose_type_is_a_literal_type__1170": + return A_computed_property_name_in_a_type_literal_must_refer_to_an_expression_whose_type_is_a_literal_type_or_a_unique_symbol_type + case "A_comma_expression_is_not_allowed_in_a_computed_property_name_1171": + return A_comma_expression_is_not_allowed_in_a_computed_property_name + case "extends_clause_already_seen_1172": + return X_extends_clause_already_seen + case "extends_clause_must_precede_implements_clause_1173": + return X_extends_clause_must_precede_implements_clause + case "Classes_can_only_extend_a_single_class_1174": + return Classes_can_only_extend_a_single_class + case "implements_clause_already_seen_1175": + return X_implements_clause_already_seen + case "Interface_declaration_cannot_have_implements_clause_1176": + return Interface_declaration_cannot_have_implements_clause + case "Binary_digit_expected_1177": + return Binary_digit_expected + case "Octal_digit_expected_1178": + return Octal_digit_expected + case "Unexpected_token_expected_1179": + return Unexpected_token_expected + case "Property_destructuring_pattern_expected_1180": + return Property_destructuring_pattern_expected + case "Array_element_destructuring_pattern_expected_1181": + return Array_element_destructuring_pattern_expected + case "A_destructuring_declaration_must_have_an_initializer_1182": + return A_destructuring_declaration_must_have_an_initializer + case "An_implementation_cannot_be_declared_in_ambient_contexts_1183": + return An_implementation_cannot_be_declared_in_ambient_contexts + case "Modifiers_cannot_appear_here_1184": + return Modifiers_cannot_appear_here + case "Merge_conflict_marker_encountered_1185": + return Merge_conflict_marker_encountered + case "A_rest_element_cannot_have_an_initializer_1186": + return A_rest_element_cannot_have_an_initializer + case "A_parameter_property_may_not_be_declared_using_a_binding_pattern_1187": + return A_parameter_property_may_not_be_declared_using_a_binding_pattern + case "Only_a_single_variable_declaration_is_allowed_in_a_for_of_statement_1188": + return Only_a_single_variable_declaration_is_allowed_in_a_for_of_statement + case "The_variable_declaration_of_a_for_in_statement_cannot_have_an_initializer_1189": + return The_variable_declaration_of_a_for_in_statement_cannot_have_an_initializer + case "The_variable_declaration_of_a_for_of_statement_cannot_have_an_initializer_1190": + return The_variable_declaration_of_a_for_of_statement_cannot_have_an_initializer + case "An_import_declaration_cannot_have_modifiers_1191": + return An_import_declaration_cannot_have_modifiers + case "Module_0_has_no_default_export_1192": + return Module_0_has_no_default_export + case "An_export_declaration_cannot_have_modifiers_1193": + return An_export_declaration_cannot_have_modifiers + case "Export_declarations_are_not_permitted_in_a_namespace_1194": + return Export_declarations_are_not_permitted_in_a_namespace + case "export_Asterisk_does_not_re_export_a_default_1195": + return X_export_Asterisk_does_not_re_export_a_default + case "Catch_clause_variable_type_annotation_must_be_any_or_unknown_if_specified_1196": + return Catch_clause_variable_type_annotation_must_be_any_or_unknown_if_specified + case "Catch_clause_variable_cannot_have_an_initializer_1197": + return Catch_clause_variable_cannot_have_an_initializer + case "An_extended_Unicode_escape_value_must_be_between_0x0_and_0x10FFFF_inclusive_1198": + return An_extended_Unicode_escape_value_must_be_between_0x0_and_0x10FFFF_inclusive + case "Unterminated_Unicode_escape_sequence_1199": + return Unterminated_Unicode_escape_sequence + case "Line_terminator_not_permitted_before_arrow_1200": + return Line_terminator_not_permitted_before_arrow + case "Import_assignment_cannot_be_used_when_targeting_ECMAScript_modules_Consider_using_import_Asterisk_as_1202": + return Import_assignment_cannot_be_used_when_targeting_ECMAScript_modules_Consider_using_import_Asterisk_as_ns_from_mod_import_a_from_mod_import_d_from_mod_or_another_module_format_instead + case "Export_assignment_cannot_be_used_when_targeting_ECMAScript_modules_Consider_using_export_default_or__1203": + return Export_assignment_cannot_be_used_when_targeting_ECMAScript_modules_Consider_using_export_default_or_another_module_format_instead + case "Re_exporting_a_type_when_0_is_enabled_requires_using_export_type_1205": + return Re_exporting_a_type_when_0_is_enabled_requires_using_export_type + case "Decorators_are_not_valid_here_1206": + return Decorators_are_not_valid_here + case "Decorators_cannot_be_applied_to_multiple_get_Slashset_accessors_of_the_same_name_1207": + return Decorators_cannot_be_applied_to_multiple_get_Slashset_accessors_of_the_same_name + case "Invalid_optional_chain_from_new_expression_Did_you_mean_to_call_0_1209": + return Invalid_optional_chain_from_new_expression_Did_you_mean_to_call_0 + case "Code_contained_in_a_class_is_evaluated_in_JavaScript_s_strict_mode_which_does_not_allow_this_use_of__1210": + return Code_contained_in_a_class_is_evaluated_in_JavaScript_s_strict_mode_which_does_not_allow_this_use_of_0_For_more_information_see_https_Colon_Slash_Slashdeveloper_mozilla_org_Slashen_US_Slashdocs_SlashWeb_SlashJavaScript_SlashReference_SlashStrict_mode + case "A_class_declaration_without_the_default_modifier_must_have_a_name_1211": + return A_class_declaration_without_the_default_modifier_must_have_a_name + case "Identifier_expected_0_is_a_reserved_word_in_strict_mode_1212": + return Identifier_expected_0_is_a_reserved_word_in_strict_mode + case "Identifier_expected_0_is_a_reserved_word_in_strict_mode_Class_definitions_are_automatically_in_stric_1213": + return Identifier_expected_0_is_a_reserved_word_in_strict_mode_Class_definitions_are_automatically_in_strict_mode + case "Identifier_expected_0_is_a_reserved_word_in_strict_mode_Modules_are_automatically_in_strict_mode_1214": + return Identifier_expected_0_is_a_reserved_word_in_strict_mode_Modules_are_automatically_in_strict_mode + case "Invalid_use_of_0_Modules_are_automatically_in_strict_mode_1215": + return Invalid_use_of_0_Modules_are_automatically_in_strict_mode + case "Identifier_expected_esModule_is_reserved_as_an_exported_marker_when_transforming_ECMAScript_modules_1216": + return Identifier_expected_esModule_is_reserved_as_an_exported_marker_when_transforming_ECMAScript_modules + case "Export_assignment_is_not_supported_when_module_flag_is_system_1218": + return Export_assignment_is_not_supported_when_module_flag_is_system + case "Generators_are_not_allowed_in_an_ambient_context_1221": + return Generators_are_not_allowed_in_an_ambient_context + case "An_overload_signature_cannot_be_declared_as_a_generator_1222": + return An_overload_signature_cannot_be_declared_as_a_generator + case "_0_tag_already_specified_1223": + return X_0_tag_already_specified + case "Signature_0_must_be_a_type_predicate_1224": + return Signature_0_must_be_a_type_predicate + case "Cannot_find_parameter_0_1225": + return Cannot_find_parameter_0 + case "Type_predicate_0_is_not_assignable_to_1_1226": + return Type_predicate_0_is_not_assignable_to_1 + case "Parameter_0_is_not_in_the_same_position_as_parameter_1_1227": + return Parameter_0_is_not_in_the_same_position_as_parameter_1 + case "A_type_predicate_is_only_allowed_in_return_type_position_for_functions_and_methods_1228": + return A_type_predicate_is_only_allowed_in_return_type_position_for_functions_and_methods + case "A_type_predicate_cannot_reference_a_rest_parameter_1229": + return A_type_predicate_cannot_reference_a_rest_parameter + case "A_type_predicate_cannot_reference_element_0_in_a_binding_pattern_1230": + return A_type_predicate_cannot_reference_element_0_in_a_binding_pattern + case "An_export_assignment_must_be_at_the_top_level_of_a_file_or_module_declaration_1231": + return An_export_assignment_must_be_at_the_top_level_of_a_file_or_module_declaration + case "An_import_declaration_can_only_be_used_at_the_top_level_of_a_namespace_or_module_1232": + return An_import_declaration_can_only_be_used_at_the_top_level_of_a_namespace_or_module + case "An_export_declaration_can_only_be_used_at_the_top_level_of_a_namespace_or_module_1233": + return An_export_declaration_can_only_be_used_at_the_top_level_of_a_namespace_or_module + case "An_ambient_module_declaration_is_only_allowed_at_the_top_level_in_a_file_1234": + return An_ambient_module_declaration_is_only_allowed_at_the_top_level_in_a_file + case "A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module_1235": + return A_namespace_declaration_is_only_allowed_at_the_top_level_of_a_namespace_or_module + case "The_return_type_of_a_property_decorator_function_must_be_either_void_or_any_1236": + return The_return_type_of_a_property_decorator_function_must_be_either_void_or_any + case "The_return_type_of_a_parameter_decorator_function_must_be_either_void_or_any_1237": + return The_return_type_of_a_parameter_decorator_function_must_be_either_void_or_any + case "Unable_to_resolve_signature_of_class_decorator_when_called_as_an_expression_1238": + return Unable_to_resolve_signature_of_class_decorator_when_called_as_an_expression + case "Unable_to_resolve_signature_of_parameter_decorator_when_called_as_an_expression_1239": + return Unable_to_resolve_signature_of_parameter_decorator_when_called_as_an_expression + case "Unable_to_resolve_signature_of_property_decorator_when_called_as_an_expression_1240": + return Unable_to_resolve_signature_of_property_decorator_when_called_as_an_expression + case "Unable_to_resolve_signature_of_method_decorator_when_called_as_an_expression_1241": + return Unable_to_resolve_signature_of_method_decorator_when_called_as_an_expression + case "abstract_modifier_can_only_appear_on_a_class_method_or_property_declaration_1242": + return X_abstract_modifier_can_only_appear_on_a_class_method_or_property_declaration + case "_0_modifier_cannot_be_used_with_1_modifier_1243": + return X_0_modifier_cannot_be_used_with_1_modifier + case "Abstract_methods_can_only_appear_within_an_abstract_class_1244": + return Abstract_methods_can_only_appear_within_an_abstract_class + case "Method_0_cannot_have_an_implementation_because_it_is_marked_abstract_1245": + return Method_0_cannot_have_an_implementation_because_it_is_marked_abstract + case "An_interface_property_cannot_have_an_initializer_1246": + return An_interface_property_cannot_have_an_initializer + case "A_type_literal_property_cannot_have_an_initializer_1247": + return A_type_literal_property_cannot_have_an_initializer + case "A_class_member_cannot_have_the_0_keyword_1248": + return A_class_member_cannot_have_the_0_keyword + case "A_decorator_can_only_decorate_a_method_implementation_not_an_overload_1249": + return A_decorator_can_only_decorate_a_method_implementation_not_an_overload + case "Function_declarations_are_not_allowed_inside_blocks_in_strict_mode_when_targeting_ES5_1250": + return Function_declarations_are_not_allowed_inside_blocks_in_strict_mode_when_targeting_ES5 + case "Function_declarations_are_not_allowed_inside_blocks_in_strict_mode_when_targeting_ES5_Class_definiti_1251": + return Function_declarations_are_not_allowed_inside_blocks_in_strict_mode_when_targeting_ES5_Class_definitions_are_automatically_in_strict_mode + case "Function_declarations_are_not_allowed_inside_blocks_in_strict_mode_when_targeting_ES5_Modules_are_au_1252": + return Function_declarations_are_not_allowed_inside_blocks_in_strict_mode_when_targeting_ES5_Modules_are_automatically_in_strict_mode + case "Abstract_properties_can_only_appear_within_an_abstract_class_1253": + return Abstract_properties_can_only_appear_within_an_abstract_class + case "A_const_initializer_in_an_ambient_context_must_be_a_string_or_numeric_literal_or_literal_enum_refere_1254": + return A_const_initializer_in_an_ambient_context_must_be_a_string_or_numeric_literal_or_literal_enum_reference + case "A_definite_assignment_assertion_is_not_permitted_in_this_context_1255": + return A_definite_assignment_assertion_is_not_permitted_in_this_context + case "A_required_element_cannot_follow_an_optional_element_1257": + return A_required_element_cannot_follow_an_optional_element + case "A_default_export_must_be_at_the_top_level_of_a_file_or_module_declaration_1258": + return A_default_export_must_be_at_the_top_level_of_a_file_or_module_declaration + case "Module_0_can_only_be_default_imported_using_the_1_flag_1259": + return Module_0_can_only_be_default_imported_using_the_1_flag + case "Keywords_cannot_contain_escape_characters_1260": + return Keywords_cannot_contain_escape_characters + case "Already_included_file_name_0_differs_from_file_name_1_only_in_casing_1261": + return Already_included_file_name_0_differs_from_file_name_1_only_in_casing + case "Identifier_expected_0_is_a_reserved_word_at_the_top_level_of_a_module_1262": + return Identifier_expected_0_is_a_reserved_word_at_the_top_level_of_a_module + case "Declarations_with_initializers_cannot_also_have_definite_assignment_assertions_1263": + return Declarations_with_initializers_cannot_also_have_definite_assignment_assertions + case "Declarations_with_definite_assignment_assertions_must_also_have_type_annotations_1264": + return Declarations_with_definite_assignment_assertions_must_also_have_type_annotations + case "A_rest_element_cannot_follow_another_rest_element_1265": + return A_rest_element_cannot_follow_another_rest_element + case "An_optional_element_cannot_follow_a_rest_element_1266": + return An_optional_element_cannot_follow_a_rest_element + case "Property_0_cannot_have_an_initializer_because_it_is_marked_abstract_1267": + return Property_0_cannot_have_an_initializer_because_it_is_marked_abstract + case "An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type_1268": + return An_index_signature_parameter_type_must_be_string_number_symbol_or_a_template_literal_type + case "Cannot_use_export_import_on_a_type_or_type_only_namespace_when_0_is_enabled_1269": + return Cannot_use_export_import_on_a_type_or_type_only_namespace_when_0_is_enabled + case "Decorator_function_return_type_0_is_not_assignable_to_type_1_1270": + return Decorator_function_return_type_0_is_not_assignable_to_type_1 + case "Decorator_function_return_type_is_0_but_is_expected_to_be_void_or_any_1271": + return Decorator_function_return_type_is_0_but_is_expected_to_be_void_or_any + case "A_type_referenced_in_a_decorated_signature_must_be_imported_with_import_type_or_a_namespace_import_w_1272": + return A_type_referenced_in_a_decorated_signature_must_be_imported_with_import_type_or_a_namespace_import_when_isolatedModules_and_emitDecoratorMetadata_are_enabled + case "_0_modifier_cannot_appear_on_a_type_parameter_1273": + return X_0_modifier_cannot_appear_on_a_type_parameter + case "_0_modifier_can_only_appear_on_a_type_parameter_of_a_class_interface_or_type_alias_1274": + return X_0_modifier_can_only_appear_on_a_type_parameter_of_a_class_interface_or_type_alias + case "accessor_modifier_can_only_appear_on_a_property_declaration_1275": + return X_accessor_modifier_can_only_appear_on_a_property_declaration + case "An_accessor_property_cannot_be_declared_optional_1276": + return An_accessor_property_cannot_be_declared_optional + case "_0_modifier_can_only_appear_on_a_type_parameter_of_a_function_method_or_class_1277": + return X_0_modifier_can_only_appear_on_a_type_parameter_of_a_function_method_or_class + case "The_runtime_will_invoke_the_decorator_with_1_arguments_but_the_decorator_expects_0_1278": + return The_runtime_will_invoke_the_decorator_with_1_arguments_but_the_decorator_expects_0 + case "The_runtime_will_invoke_the_decorator_with_1_arguments_but_the_decorator_expects_at_least_0_1279": + return The_runtime_will_invoke_the_decorator_with_1_arguments_but_the_decorator_expects_at_least_0 + case "Namespaces_are_not_allowed_in_global_script_files_when_0_is_enabled_If_this_file_is_not_intended_to__1280": + return Namespaces_are_not_allowed_in_global_script_files_when_0_is_enabled_If_this_file_is_not_intended_to_be_a_global_script_set_moduleDetection_to_force_or_add_an_empty_export_statement + case "Cannot_access_0_from_another_file_without_qualification_when_1_is_enabled_Use_2_instead_1281": + return Cannot_access_0_from_another_file_without_qualification_when_1_is_enabled_Use_2_instead + case "An_export_declaration_must_reference_a_value_when_verbatimModuleSyntax_is_enabled_but_0_only_refers__1282": + return An_export_declaration_must_reference_a_value_when_verbatimModuleSyntax_is_enabled_but_0_only_refers_to_a_type + case "An_export_declaration_must_reference_a_real_value_when_verbatimModuleSyntax_is_enabled_but_0_resolve_1283": + return An_export_declaration_must_reference_a_real_value_when_verbatimModuleSyntax_is_enabled_but_0_resolves_to_a_type_only_declaration + case "An_export_default_must_reference_a_value_when_verbatimModuleSyntax_is_enabled_but_0_only_refers_to_a_1284": + return An_export_default_must_reference_a_value_when_verbatimModuleSyntax_is_enabled_but_0_only_refers_to_a_type + case "An_export_default_must_reference_a_real_value_when_verbatimModuleSyntax_is_enabled_but_0_resolves_to_1285": + return An_export_default_must_reference_a_real_value_when_verbatimModuleSyntax_is_enabled_but_0_resolves_to_a_type_only_declaration + case "ECMAScript_imports_and_exports_cannot_be_written_in_a_CommonJS_file_under_verbatimModuleSyntax_1286": + return ECMAScript_imports_and_exports_cannot_be_written_in_a_CommonJS_file_under_verbatimModuleSyntax + case "A_top_level_export_modifier_cannot_be_used_on_value_declarations_in_a_CommonJS_module_when_verbatimM_1287": + return A_top_level_export_modifier_cannot_be_used_on_value_declarations_in_a_CommonJS_module_when_verbatimModuleSyntax_is_enabled + case "An_import_alias_cannot_resolve_to_a_type_or_type_only_declaration_when_verbatimModuleSyntax_is_enabl_1288": + return An_import_alias_cannot_resolve_to_a_type_or_type_only_declaration_when_verbatimModuleSyntax_is_enabled + case "_0_resolves_to_a_type_only_declaration_and_must_be_marked_type_only_in_this_file_before_re_exporting_1289": + return X_0_resolves_to_a_type_only_declaration_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enabled_Consider_using_import_type_where_0_is_imported + case "_0_resolves_to_a_type_only_declaration_and_must_be_marked_type_only_in_this_file_before_re_exporting_1290": + return X_0_resolves_to_a_type_only_declaration_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enabled_Consider_using_export_type_0_as_default + case "_0_resolves_to_a_type_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enable_1291": + return X_0_resolves_to_a_type_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enabled_Consider_using_import_type_where_0_is_imported + case "_0_resolves_to_a_type_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enable_1292": + return X_0_resolves_to_a_type_and_must_be_marked_type_only_in_this_file_before_re_exporting_when_1_is_enabled_Consider_using_export_type_0_as_default + case "ECMAScript_module_syntax_is_not_allowed_in_a_CommonJS_module_when_module_is_set_to_preserve_1293": + return ECMAScript_module_syntax_is_not_allowed_in_a_CommonJS_module_when_module_is_set_to_preserve + case "This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled_1294": + return This_syntax_is_not_allowed_when_erasableSyntaxOnly_is_enabled + case "ECMAScript_imports_and_exports_cannot_be_written_in_a_CommonJS_file_under_verbatimModuleSyntax_Adjus_1295": + return ECMAScript_imports_and_exports_cannot_be_written_in_a_CommonJS_file_under_verbatimModuleSyntax_Adjust_the_type_field_in_the_nearest_package_json_to_make_this_file_an_ECMAScript_module_or_adjust_your_verbatimModuleSyntax_module_and_moduleResolution_settings_in_TypeScript + case "with_statements_are_not_allowed_in_an_async_function_block_1300": + return X_with_statements_are_not_allowed_in_an_async_function_block + case "await_expressions_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules_1308": + return X_await_expressions_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules + case "The_current_file_is_a_CommonJS_module_and_cannot_use_await_at_the_top_level_1309": + return The_current_file_is_a_CommonJS_module_and_cannot_use_await_at_the_top_level + case "Did_you_mean_to_use_a_Colon_An_can_only_follow_a_property_name_when_the_containing_object_literal_is_1312": + return Did_you_mean_to_use_a_Colon_An_can_only_follow_a_property_name_when_the_containing_object_literal_is_part_of_a_destructuring_pattern + case "The_body_of_an_if_statement_cannot_be_the_empty_statement_1313": + return The_body_of_an_if_statement_cannot_be_the_empty_statement + case "Global_module_exports_may_only_appear_in_module_files_1314": + return Global_module_exports_may_only_appear_in_module_files + case "Global_module_exports_may_only_appear_in_declaration_files_1315": + return Global_module_exports_may_only_appear_in_declaration_files + case "Global_module_exports_may_only_appear_at_top_level_1316": + return Global_module_exports_may_only_appear_at_top_level + case "A_parameter_property_cannot_be_declared_using_a_rest_parameter_1317": + return A_parameter_property_cannot_be_declared_using_a_rest_parameter + case "An_abstract_accessor_cannot_have_an_implementation_1318": + return An_abstract_accessor_cannot_have_an_implementation + case "A_default_export_can_only_be_used_in_an_ECMAScript_style_module_1319": + return A_default_export_can_only_be_used_in_an_ECMAScript_style_module + case "Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member_1320": + return Type_of_await_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member + case "Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_cal_1321": + return Type_of_yield_operand_in_an_async_generator_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member + case "Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_con_1322": + return Type_of_iterated_elements_of_a_yield_Asterisk_operand_must_either_be_a_valid_promise_or_must_not_contain_a_callable_then_member + case "Dynamic_imports_are_only_supported_when_the_module_flag_is_set_to_es2020_es2022_esnext_commonjs_amd__1323": + return Dynamic_imports_are_only_supported_when_the_module_flag_is_set_to_es2020_es2022_esnext_commonjs_amd_system_umd_node16_node18_node20_or_nodenext + case "Dynamic_imports_only_support_a_second_argument_when_the_module_option_is_set_to_esnext_node16_node18_1324": + return Dynamic_imports_only_support_a_second_argument_when_the_module_option_is_set_to_esnext_node16_node18_node20_nodenext_or_preserve + case "Argument_of_dynamic_import_cannot_be_spread_element_1325": + return Argument_of_dynamic_import_cannot_be_spread_element + case "This_use_of_import_is_invalid_import_calls_can_be_written_but_they_must_have_parentheses_and_cannot__1326": + return This_use_of_import_is_invalid_import_calls_can_be_written_but_they_must_have_parentheses_and_cannot_have_type_arguments + case "String_literal_with_double_quotes_expected_1327": + return String_literal_with_double_quotes_expected + case "Property_value_can_only_be_string_literal_numeric_literal_true_false_null_object_literal_or_array_li_1328": + return Property_value_can_only_be_string_literal_numeric_literal_true_false_null_object_literal_or_array_literal + case "_0_accepts_too_few_arguments_to_be_used_as_a_decorator_here_Did_you_mean_to_call_it_first_and_write__1329": + return X_0_accepts_too_few_arguments_to_be_used_as_a_decorator_here_Did_you_mean_to_call_it_first_and_write_0 + case "A_property_of_an_interface_or_type_literal_whose_type_is_a_unique_symbol_type_must_be_readonly_1330": + return A_property_of_an_interface_or_type_literal_whose_type_is_a_unique_symbol_type_must_be_readonly + case "A_property_of_a_class_whose_type_is_a_unique_symbol_type_must_be_both_static_and_readonly_1331": + return A_property_of_a_class_whose_type_is_a_unique_symbol_type_must_be_both_static_and_readonly + case "A_variable_whose_type_is_a_unique_symbol_type_must_be_const_1332": + return A_variable_whose_type_is_a_unique_symbol_type_must_be_const + case "unique_symbol_types_may_not_be_used_on_a_variable_declaration_with_a_binding_name_1333": + return X_unique_symbol_types_may_not_be_used_on_a_variable_declaration_with_a_binding_name + case "unique_symbol_types_are_only_allowed_on_variables_in_a_variable_statement_1334": + return X_unique_symbol_types_are_only_allowed_on_variables_in_a_variable_statement + case "unique_symbol_types_are_not_allowed_here_1335": + return X_unique_symbol_types_are_not_allowed_here + case "An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_o_1337": + return An_index_signature_parameter_type_cannot_be_a_literal_type_or_generic_type_Consider_using_a_mapped_object_type_instead + case "infer_declarations_are_only_permitted_in_the_extends_clause_of_a_conditional_type_1338": + return X_infer_declarations_are_only_permitted_in_the_extends_clause_of_a_conditional_type + case "Module_0_does_not_refer_to_a_value_but_is_used_as_a_value_here_1339": + return Module_0_does_not_refer_to_a_value_but_is_used_as_a_value_here + case "Module_0_does_not_refer_to_a_type_but_is_used_as_a_type_here_Did_you_mean_typeof_import_0_1340": + return Module_0_does_not_refer_to_a_type_but_is_used_as_a_type_here_Did_you_mean_typeof_import_0 + case "Class_constructor_may_not_be_an_accessor_1341": + return Class_constructor_may_not_be_an_accessor + case "The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system__1343": + return The_import_meta_meta_property_is_only_allowed_when_the_module_option_is_es2020_es2022_esnext_system_node16_node18_node20_or_nodenext + case "A_label_is_not_allowed_here_1344": + return A_label_is_not_allowed_here + case "An_expression_of_type_void_cannot_be_tested_for_truthiness_1345": + return An_expression_of_type_void_cannot_be_tested_for_truthiness + case "This_parameter_is_not_allowed_with_use_strict_directive_1346": + return This_parameter_is_not_allowed_with_use_strict_directive + case "use_strict_directive_cannot_be_used_with_non_simple_parameter_list_1347": + return X_use_strict_directive_cannot_be_used_with_non_simple_parameter_list + case "Non_simple_parameter_declared_here_1348": + return Non_simple_parameter_declared_here + case "use_strict_directive_used_here_1349": + return X_use_strict_directive_used_here + case "Print_the_final_configuration_instead_of_building_1350": + return Print_the_final_configuration_instead_of_building + case "An_identifier_or_keyword_cannot_immediately_follow_a_numeric_literal_1351": + return An_identifier_or_keyword_cannot_immediately_follow_a_numeric_literal + case "A_bigint_literal_cannot_use_exponential_notation_1352": + return A_bigint_literal_cannot_use_exponential_notation + case "A_bigint_literal_must_be_an_integer_1353": + return A_bigint_literal_must_be_an_integer + case "readonly_type_modifier_is_only_permitted_on_array_and_tuple_literal_types_1354": + return X_readonly_type_modifier_is_only_permitted_on_array_and_tuple_literal_types + case "A_const_assertions_can_only_be_applied_to_references_to_enum_members_or_string_number_boolean_array__1355": + return A_const_assertions_can_only_be_applied_to_references_to_enum_members_or_string_number_boolean_array_or_object_literals + case "Did_you_mean_to_mark_this_function_as_async_1356": + return Did_you_mean_to_mark_this_function_as_async + case "An_enum_member_name_must_be_followed_by_a_or_1357": + return An_enum_member_name_must_be_followed_by_a_or + case "Tagged_template_expressions_are_not_permitted_in_an_optional_chain_1358": + return Tagged_template_expressions_are_not_permitted_in_an_optional_chain + case "Identifier_expected_0_is_a_reserved_word_that_cannot_be_used_here_1359": + return Identifier_expected_0_is_a_reserved_word_that_cannot_be_used_here + case "Type_0_does_not_satisfy_the_expected_type_1_1360": + return Type_0_does_not_satisfy_the_expected_type_1 + case "_0_cannot_be_used_as_a_value_because_it_was_imported_using_import_type_1361": + return X_0_cannot_be_used_as_a_value_because_it_was_imported_using_import_type + case "_0_cannot_be_used_as_a_value_because_it_was_exported_using_export_type_1362": + return X_0_cannot_be_used_as_a_value_because_it_was_exported_using_export_type + case "A_type_only_import_can_specify_a_default_import_or_named_bindings_but_not_both_1363": + return A_type_only_import_can_specify_a_default_import_or_named_bindings_but_not_both + case "Convert_to_type_only_export_1364": + return Convert_to_type_only_export + case "Convert_all_re_exported_types_to_type_only_exports_1365": + return Convert_all_re_exported_types_to_type_only_exports + case "Split_into_two_separate_import_declarations_1366": + return Split_into_two_separate_import_declarations + case "Split_all_invalid_type_only_imports_1367": + return Split_all_invalid_type_only_imports + case "Class_constructor_may_not_be_a_generator_1368": + return Class_constructor_may_not_be_a_generator + case "Did_you_mean_0_1369": + return Did_you_mean_0 + case "await_expressions_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_fi_1375": + return X_await_expressions_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_file_has_no_imports_or_exports_Consider_adding_an_empty_export_to_make_this_file_a_module + case "_0_was_imported_here_1376": + return X_0_was_imported_here + case "_0_was_exported_here_1377": + return X_0_was_exported_here + case "Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_n_1378": + return Top_level_await_expressions_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_node20_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher + case "An_import_alias_cannot_reference_a_declaration_that_was_exported_using_export_type_1379": + return An_import_alias_cannot_reference_a_declaration_that_was_exported_using_export_type + case "An_import_alias_cannot_reference_a_declaration_that_was_imported_using_import_type_1380": + return An_import_alias_cannot_reference_a_declaration_that_was_imported_using_import_type + case "Unexpected_token_Did_you_mean_or_rbrace_1381": + return Unexpected_token_Did_you_mean_or_rbrace + case "Unexpected_token_Did_you_mean_or_gt_1382": + return Unexpected_token_Did_you_mean_or_gt + case "Function_type_notation_must_be_parenthesized_when_used_in_a_union_type_1385": + return Function_type_notation_must_be_parenthesized_when_used_in_a_union_type + case "Constructor_type_notation_must_be_parenthesized_when_used_in_a_union_type_1386": + return Constructor_type_notation_must_be_parenthesized_when_used_in_a_union_type + case "Function_type_notation_must_be_parenthesized_when_used_in_an_intersection_type_1387": + return Function_type_notation_must_be_parenthesized_when_used_in_an_intersection_type + case "Constructor_type_notation_must_be_parenthesized_when_used_in_an_intersection_type_1388": + return Constructor_type_notation_must_be_parenthesized_when_used_in_an_intersection_type + case "_0_is_not_allowed_as_a_variable_declaration_name_1389": + return X_0_is_not_allowed_as_a_variable_declaration_name + case "_0_is_not_allowed_as_a_parameter_name_1390": + return X_0_is_not_allowed_as_a_parameter_name + case "An_import_alias_cannot_use_import_type_1392": + return An_import_alias_cannot_use_import_type + case "Imported_via_0_from_file_1_1393": + return Imported_via_0_from_file_1 + case "Imported_via_0_from_file_1_with_packageId_2_1394": + return Imported_via_0_from_file_1_with_packageId_2 + case "Imported_via_0_from_file_1_to_import_importHelpers_as_specified_in_compilerOptions_1395": + return Imported_via_0_from_file_1_to_import_importHelpers_as_specified_in_compilerOptions + case "Imported_via_0_from_file_1_with_packageId_2_to_import_importHelpers_as_specified_in_compilerOptions_1396": + return Imported_via_0_from_file_1_with_packageId_2_to_import_importHelpers_as_specified_in_compilerOptions + case "Imported_via_0_from_file_1_to_import_jsx_and_jsxs_factory_functions_1397": + return Imported_via_0_from_file_1_to_import_jsx_and_jsxs_factory_functions + case "Imported_via_0_from_file_1_with_packageId_2_to_import_jsx_and_jsxs_factory_functions_1398": + return Imported_via_0_from_file_1_with_packageId_2_to_import_jsx_and_jsxs_factory_functions + case "File_is_included_via_import_here_1399": + return File_is_included_via_import_here + case "Referenced_via_0_from_file_1_1400": + return Referenced_via_0_from_file_1 + case "File_is_included_via_reference_here_1401": + return File_is_included_via_reference_here + case "Type_library_referenced_via_0_from_file_1_1402": + return Type_library_referenced_via_0_from_file_1 + case "Type_library_referenced_via_0_from_file_1_with_packageId_2_1403": + return Type_library_referenced_via_0_from_file_1_with_packageId_2 + case "File_is_included_via_type_library_reference_here_1404": + return File_is_included_via_type_library_reference_here + case "Library_referenced_via_0_from_file_1_1405": + return Library_referenced_via_0_from_file_1 + case "File_is_included_via_library_reference_here_1406": + return File_is_included_via_library_reference_here + case "Matched_by_include_pattern_0_in_1_1407": + return Matched_by_include_pattern_0_in_1 + case "File_is_matched_by_include_pattern_specified_here_1408": + return File_is_matched_by_include_pattern_specified_here + case "Part_of_files_list_in_tsconfig_json_1409": + return Part_of_files_list_in_tsconfig_json + case "File_is_matched_by_files_list_specified_here_1410": + return File_is_matched_by_files_list_specified_here + case "Output_from_referenced_project_0_included_because_1_specified_1411": + return Output_from_referenced_project_0_included_because_1_specified + case "Output_from_referenced_project_0_included_because_module_is_specified_as_none_1412": + return Output_from_referenced_project_0_included_because_module_is_specified_as_none + case "File_is_output_from_referenced_project_specified_here_1413": + return File_is_output_from_referenced_project_specified_here + case "Source_from_referenced_project_0_included_because_1_specified_1414": + return Source_from_referenced_project_0_included_because_1_specified + case "Source_from_referenced_project_0_included_because_module_is_specified_as_none_1415": + return Source_from_referenced_project_0_included_because_module_is_specified_as_none + case "File_is_source_from_referenced_project_specified_here_1416": + return File_is_source_from_referenced_project_specified_here + case "Entry_point_of_type_library_0_specified_in_compilerOptions_1417": + return Entry_point_of_type_library_0_specified_in_compilerOptions + case "Entry_point_of_type_library_0_specified_in_compilerOptions_with_packageId_1_1418": + return Entry_point_of_type_library_0_specified_in_compilerOptions_with_packageId_1 + case "File_is_entry_point_of_type_library_specified_here_1419": + return File_is_entry_point_of_type_library_specified_here + case "Entry_point_for_implicit_type_library_0_1420": + return Entry_point_for_implicit_type_library_0 + case "Entry_point_for_implicit_type_library_0_with_packageId_1_1421": + return Entry_point_for_implicit_type_library_0_with_packageId_1 + case "Library_0_specified_in_compilerOptions_1422": + return Library_0_specified_in_compilerOptions + case "File_is_library_specified_here_1423": + return File_is_library_specified_here + case "Default_library_1424": + return Default_library + case "Default_library_for_target_0_1425": + return Default_library_for_target_0 + case "File_is_default_library_for_target_specified_here_1426": + return File_is_default_library_for_target_specified_here + case "Root_file_specified_for_compilation_1427": + return Root_file_specified_for_compilation + case "File_is_output_of_project_reference_source_0_1428": + return File_is_output_of_project_reference_source_0 + case "File_redirects_to_file_0_1429": + return File_redirects_to_file_0 + case "The_file_is_in_the_program_because_Colon_1430": + return The_file_is_in_the_program_because_Colon + case "for_await_loops_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_file_1431": + return X_for_await_loops_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_file_has_no_imports_or_exports_Consider_adding_an_empty_export_to_make_this_file_a_module + case "Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_nod_1432": + return Top_level_for_await_loops_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_node20_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher + case "Neither_decorators_nor_modifiers_may_be_applied_to_this_parameters_1433": + return Neither_decorators_nor_modifiers_may_be_applied_to_this_parameters + case "Unexpected_keyword_or_identifier_1434": + return Unexpected_keyword_or_identifier + case "Unknown_keyword_or_identifier_Did_you_mean_0_1435": + return Unknown_keyword_or_identifier_Did_you_mean_0 + case "Decorators_must_precede_the_name_and_all_keywords_of_property_declarations_1436": + return Decorators_must_precede_the_name_and_all_keywords_of_property_declarations + case "Namespace_must_be_given_a_name_1437": + return Namespace_must_be_given_a_name + case "Interface_must_be_given_a_name_1438": + return Interface_must_be_given_a_name + case "Type_alias_must_be_given_a_name_1439": + return Type_alias_must_be_given_a_name + case "Variable_declaration_not_allowed_at_this_location_1440": + return Variable_declaration_not_allowed_at_this_location + case "Cannot_start_a_function_call_in_a_type_annotation_1441": + return Cannot_start_a_function_call_in_a_type_annotation + case "Expected_for_property_initializer_1442": + return Expected_for_property_initializer + case "Module_declaration_names_may_only_use_or_quoted_strings_1443": + return Module_declaration_names_may_only_use_or_quoted_strings + case "_0_resolves_to_a_type_only_declaration_and_must_be_re_exported_using_a_type_only_re_export_when_1_is_1448": + return X_0_resolves_to_a_type_only_declaration_and_must_be_re_exported_using_a_type_only_re_export_when_1_is_enabled + case "Preserve_unused_imported_values_in_the_JavaScript_output_that_would_otherwise_be_removed_1449": + return Preserve_unused_imported_values_in_the_JavaScript_output_that_would_otherwise_be_removed + case "Dynamic_imports_can_only_accept_a_module_specifier_and_an_optional_set_of_attributes_as_arguments_1450": + return Dynamic_imports_can_only_accept_a_module_specifier_and_an_optional_set_of_attributes_as_arguments + case "Private_identifiers_are_only_allowed_in_class_bodies_and_may_only_be_used_as_part_of_a_class_member__1451": + return Private_identifiers_are_only_allowed_in_class_bodies_and_may_only_be_used_as_part_of_a_class_member_declaration_property_access_or_on_the_left_hand_side_of_an_in_expression + case "resolution_mode_should_be_either_require_or_import_1453": + return X_resolution_mode_should_be_either_require_or_import + case "resolution_mode_can_only_be_set_for_type_only_imports_1454": + return X_resolution_mode_can_only_be_set_for_type_only_imports + case "resolution_mode_is_the_only_valid_key_for_type_import_assertions_1455": + return X_resolution_mode_is_the_only_valid_key_for_type_import_assertions + case "Type_import_assertions_should_have_exactly_one_key_resolution_mode_with_value_import_or_require_1456": + return Type_import_assertions_should_have_exactly_one_key_resolution_mode_with_value_import_or_require + case "Matched_by_default_include_pattern_Asterisk_Asterisk_Slash_Asterisk_1457": + return Matched_by_default_include_pattern_Asterisk_Asterisk_Slash_Asterisk + case "File_is_ECMAScript_module_because_0_has_field_type_with_value_module_1458": + return File_is_ECMAScript_module_because_0_has_field_type_with_value_module + case "File_is_CommonJS_module_because_0_has_field_type_whose_value_is_not_module_1459": + return File_is_CommonJS_module_because_0_has_field_type_whose_value_is_not_module + case "File_is_CommonJS_module_because_0_does_not_have_field_type_1460": + return File_is_CommonJS_module_because_0_does_not_have_field_type + case "File_is_CommonJS_module_because_package_json_was_not_found_1461": + return File_is_CommonJS_module_because_package_json_was_not_found + case "resolution_mode_is_the_only_valid_key_for_type_import_attributes_1463": + return X_resolution_mode_is_the_only_valid_key_for_type_import_attributes + case "Type_import_attributes_should_have_exactly_one_key_resolution_mode_with_value_import_or_require_1464": + return Type_import_attributes_should_have_exactly_one_key_resolution_mode_with_value_import_or_require + case "The_import_meta_meta_property_is_not_allowed_in_files_which_will_build_into_CommonJS_output_1470": + return The_import_meta_meta_property_is_not_allowed_in_files_which_will_build_into_CommonJS_output + case "Module_0_cannot_be_imported_using_this_construct_The_specifier_only_resolves_to_an_ES_module_which_c_1471": + return Module_0_cannot_be_imported_using_this_construct_The_specifier_only_resolves_to_an_ES_module_which_cannot_be_imported_with_require_Use_an_ECMAScript_import_instead + case "catch_or_finally_expected_1472": + return X_catch_or_finally_expected + case "An_import_declaration_can_only_be_used_at_the_top_level_of_a_module_1473": + return An_import_declaration_can_only_be_used_at_the_top_level_of_a_module + case "An_export_declaration_can_only_be_used_at_the_top_level_of_a_module_1474": + return An_export_declaration_can_only_be_used_at_the_top_level_of_a_module + case "Control_what_method_is_used_to_detect_module_format_JS_files_1475": + return Control_what_method_is_used_to_detect_module_format_JS_files + case "auto_Colon_Treat_files_with_imports_exports_import_meta_jsx_with_jsx_Colon_react_jsx_or_esm_format_w_1476": + return X_auto_Colon_Treat_files_with_imports_exports_import_meta_jsx_with_jsx_Colon_react_jsx_or_esm_format_with_module_Colon_node16_as_modules + case "An_instantiation_expression_cannot_be_followed_by_a_property_access_1477": + return An_instantiation_expression_cannot_be_followed_by_a_property_access + case "Identifier_or_string_literal_expected_1478": + return Identifier_or_string_literal_expected + case "The_current_file_is_a_CommonJS_module_whose_imports_will_produce_require_calls_however_the_reference_1479": + return The_current_file_is_a_CommonJS_module_whose_imports_will_produce_require_calls_however_the_referenced_file_is_an_ECMAScript_module_and_cannot_be_imported_with_require_Consider_writing_a_dynamic_import_0_call_instead + case "To_convert_this_file_to_an_ECMAScript_module_change_its_file_extension_to_0_or_create_a_local_packag_1480": + return To_convert_this_file_to_an_ECMAScript_module_change_its_file_extension_to_0_or_create_a_local_package_json_file_with_type_Colon_module + case "To_convert_this_file_to_an_ECMAScript_module_change_its_file_extension_to_0_or_add_the_field_type_Co_1481": + return To_convert_this_file_to_an_ECMAScript_module_change_its_file_extension_to_0_or_add_the_field_type_Colon_module_to_1 + case "To_convert_this_file_to_an_ECMAScript_module_add_the_field_type_Colon_module_to_0_1482": + return To_convert_this_file_to_an_ECMAScript_module_add_the_field_type_Colon_module_to_0 + case "To_convert_this_file_to_an_ECMAScript_module_create_a_local_package_json_file_with_type_Colon_module_1483": + return To_convert_this_file_to_an_ECMAScript_module_create_a_local_package_json_file_with_type_Colon_module + case "_0_is_a_type_and_must_be_imported_using_a_type_only_import_when_verbatimModuleSyntax_is_enabled_1484": + return X_0_is_a_type_and_must_be_imported_using_a_type_only_import_when_verbatimModuleSyntax_is_enabled + case "_0_resolves_to_a_type_only_declaration_and_must_be_imported_using_a_type_only_import_when_verbatimMo_1485": + return X_0_resolves_to_a_type_only_declaration_and_must_be_imported_using_a_type_only_import_when_verbatimModuleSyntax_is_enabled + case "Decorator_used_before_export_here_1486": + return Decorator_used_before_export_here + case "Octal_escape_sequences_are_not_allowed_Use_the_syntax_0_1487": + return Octal_escape_sequences_are_not_allowed_Use_the_syntax_0 + case "Escape_sequence_0_is_not_allowed_1488": + return Escape_sequence_0_is_not_allowed + case "Decimals_with_leading_zeros_are_not_allowed_1489": + return Decimals_with_leading_zeros_are_not_allowed + case "File_appears_to_be_binary_1490": + return File_appears_to_be_binary + case "_0_modifier_cannot_appear_on_a_using_declaration_1491": + return X_0_modifier_cannot_appear_on_a_using_declaration + case "_0_declarations_may_not_have_binding_patterns_1492": + return X_0_declarations_may_not_have_binding_patterns + case "The_left_hand_side_of_a_for_in_statement_cannot_be_a_using_declaration_1493": + return The_left_hand_side_of_a_for_in_statement_cannot_be_a_using_declaration + case "The_left_hand_side_of_a_for_in_statement_cannot_be_an_await_using_declaration_1494": + return The_left_hand_side_of_a_for_in_statement_cannot_be_an_await_using_declaration + case "_0_modifier_cannot_appear_on_an_await_using_declaration_1495": + return X_0_modifier_cannot_appear_on_an_await_using_declaration + case "Identifier_string_literal_or_number_literal_expected_1496": + return Identifier_string_literal_or_number_literal_expected + case "Expression_must_be_enclosed_in_parentheses_to_be_used_as_a_decorator_1497": + return Expression_must_be_enclosed_in_parentheses_to_be_used_as_a_decorator + case "Invalid_syntax_in_decorator_1498": + return Invalid_syntax_in_decorator + case "Unknown_regular_expression_flag_1499": + return Unknown_regular_expression_flag + case "Duplicate_regular_expression_flag_1500": + return Duplicate_regular_expression_flag + case "This_regular_expression_flag_is_only_available_when_targeting_0_or_later_1501": + return This_regular_expression_flag_is_only_available_when_targeting_0_or_later + case "The_Unicode_u_flag_and_the_Unicode_Sets_v_flag_cannot_be_set_simultaneously_1502": + return The_Unicode_u_flag_and_the_Unicode_Sets_v_flag_cannot_be_set_simultaneously + case "Named_capturing_groups_are_only_available_when_targeting_ES2018_or_later_1503": + return Named_capturing_groups_are_only_available_when_targeting_ES2018_or_later + case "Subpattern_flags_must_be_present_when_there_is_a_minus_sign_1504": + return Subpattern_flags_must_be_present_when_there_is_a_minus_sign + case "Incomplete_quantifier_Digit_expected_1505": + return Incomplete_quantifier_Digit_expected + case "Numbers_out_of_order_in_quantifier_1506": + return Numbers_out_of_order_in_quantifier + case "There_is_nothing_available_for_repetition_1507": + return There_is_nothing_available_for_repetition + case "Unexpected_0_Did_you_mean_to_escape_it_with_backslash_1508": + return Unexpected_0_Did_you_mean_to_escape_it_with_backslash + case "This_regular_expression_flag_cannot_be_toggled_within_a_subpattern_1509": + return This_regular_expression_flag_cannot_be_toggled_within_a_subpattern + case "k_must_be_followed_by_a_capturing_group_name_enclosed_in_angle_brackets_1510": + return X_k_must_be_followed_by_a_capturing_group_name_enclosed_in_angle_brackets + case "q_is_only_available_inside_character_class_1511": + return X_q_is_only_available_inside_character_class + case "c_must_be_followed_by_an_ASCII_letter_1512": + return X_c_must_be_followed_by_an_ASCII_letter + case "Undetermined_character_escape_1513": + return Undetermined_character_escape + case "Expected_a_capturing_group_name_1514": + return Expected_a_capturing_group_name + case "Named_capturing_groups_with_the_same_name_must_be_mutually_exclusive_to_each_other_1515": + return Named_capturing_groups_with_the_same_name_must_be_mutually_exclusive_to_each_other + case "A_character_class_range_must_not_be_bounded_by_another_character_class_1516": + return A_character_class_range_must_not_be_bounded_by_another_character_class + case "Range_out_of_order_in_character_class_1517": + return Range_out_of_order_in_character_class + case "Anything_that_would_possibly_match_more_than_a_single_character_is_invalid_inside_a_negated_characte_1518": + return Anything_that_would_possibly_match_more_than_a_single_character_is_invalid_inside_a_negated_character_class + case "Operators_must_not_be_mixed_within_a_character_class_Wrap_it_in_a_nested_class_instead_1519": + return Operators_must_not_be_mixed_within_a_character_class_Wrap_it_in_a_nested_class_instead + case "Expected_a_class_set_operand_1520": + return Expected_a_class_set_operand + case "q_must_be_followed_by_string_alternatives_enclosed_in_braces_1521": + return X_q_must_be_followed_by_string_alternatives_enclosed_in_braces + case "A_character_class_must_not_contain_a_reserved_double_punctuator_Did_you_mean_to_escape_it_with_backs_1522": + return A_character_class_must_not_contain_a_reserved_double_punctuator_Did_you_mean_to_escape_it_with_backslash + case "Expected_a_Unicode_property_name_1523": + return Expected_a_Unicode_property_name + case "Unknown_Unicode_property_name_1524": + return Unknown_Unicode_property_name + case "Expected_a_Unicode_property_value_1525": + return Expected_a_Unicode_property_value + case "Unknown_Unicode_property_value_1526": + return Unknown_Unicode_property_value + case "Expected_a_Unicode_property_name_or_value_1527": + return Expected_a_Unicode_property_name_or_value + case "Any_Unicode_property_that_would_possibly_match_more_than_a_single_character_is_only_available_when_t_1528": + return Any_Unicode_property_that_would_possibly_match_more_than_a_single_character_is_only_available_when_the_Unicode_Sets_v_flag_is_set + case "Unknown_Unicode_property_name_or_value_1529": + return Unknown_Unicode_property_name_or_value + case "Unicode_property_value_expressions_are_only_available_when_the_Unicode_u_flag_or_the_Unicode_Sets_v__1530": + return Unicode_property_value_expressions_are_only_available_when_the_Unicode_u_flag_or_the_Unicode_Sets_v_flag_is_set + case "_0_must_be_followed_by_a_Unicode_property_value_expression_enclosed_in_braces_1531": + return X_0_must_be_followed_by_a_Unicode_property_value_expression_enclosed_in_braces + case "There_is_no_capturing_group_named_0_in_this_regular_expression_1532": + return There_is_no_capturing_group_named_0_in_this_regular_expression + case "This_backreference_refers_to_a_group_that_does_not_exist_There_are_only_0_capturing_groups_in_this_r_1533": + return This_backreference_refers_to_a_group_that_does_not_exist_There_are_only_0_capturing_groups_in_this_regular_expression + case "This_backreference_refers_to_a_group_that_does_not_exist_There_are_no_capturing_groups_in_this_regul_1534": + return This_backreference_refers_to_a_group_that_does_not_exist_There_are_no_capturing_groups_in_this_regular_expression + case "This_character_cannot_be_escaped_in_a_regular_expression_1535": + return This_character_cannot_be_escaped_in_a_regular_expression + case "Octal_escape_sequences_and_backreferences_are_not_allowed_in_a_character_class_If_this_was_intended__1536": + return Octal_escape_sequences_and_backreferences_are_not_allowed_in_a_character_class_If_this_was_intended_as_an_escape_sequence_use_the_syntax_0_instead + case "Decimal_escape_sequences_and_backreferences_are_not_allowed_in_a_character_class_1537": + return Decimal_escape_sequences_and_backreferences_are_not_allowed_in_a_character_class + case "Unicode_escape_sequences_are_only_available_when_the_Unicode_u_flag_or_the_Unicode_Sets_v_flag_is_se_1538": + return Unicode_escape_sequences_are_only_available_when_the_Unicode_u_flag_or_the_Unicode_Sets_v_flag_is_set + case "A_bigint_literal_cannot_be_used_as_a_property_name_1539": + return A_bigint_literal_cannot_be_used_as_a_property_name + case "A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_key_1540": + return A_namespace_declaration_should_not_be_declared_using_the_module_keyword_Please_use_the_namespace_keyword_instead + case "Type_only_import_of_an_ECMAScript_module_from_a_CommonJS_module_must_have_a_resolution_mode_attribut_1541": + return Type_only_import_of_an_ECMAScript_module_from_a_CommonJS_module_must_have_a_resolution_mode_attribute + case "Type_import_of_an_ECMAScript_module_from_a_CommonJS_module_must_have_a_resolution_mode_attribute_1542": + return Type_import_of_an_ECMAScript_module_from_a_CommonJS_module_must_have_a_resolution_mode_attribute + case "Importing_a_JSON_file_into_an_ECMAScript_module_requires_a_type_Colon_json_import_attribute_when_mod_1543": + return Importing_a_JSON_file_into_an_ECMAScript_module_requires_a_type_Colon_json_import_attribute_when_module_is_set_to_0 + case "Named_imports_from_a_JSON_file_into_an_ECMAScript_module_are_not_allowed_when_module_is_set_to_0_1544": + return Named_imports_from_a_JSON_file_into_an_ECMAScript_module_are_not_allowed_when_module_is_set_to_0 + case "using_declarations_are_not_allowed_in_ambient_contexts_1545": + return X_using_declarations_are_not_allowed_in_ambient_contexts + case "await_using_declarations_are_not_allowed_in_ambient_contexts_1546": + return X_await_using_declarations_are_not_allowed_in_ambient_contexts + case "The_types_of_0_are_incompatible_between_these_types_2200": + return The_types_of_0_are_incompatible_between_these_types + case "The_types_returned_by_0_are_incompatible_between_these_types_2201": + return The_types_returned_by_0_are_incompatible_between_these_types + case "Call_signature_return_types_0_and_1_are_incompatible_2202": + return Call_signature_return_types_0_and_1_are_incompatible + case "Construct_signature_return_types_0_and_1_are_incompatible_2203": + return Construct_signature_return_types_0_and_1_are_incompatible + case "Call_signatures_with_no_arguments_have_incompatible_return_types_0_and_1_2204": + return Call_signatures_with_no_arguments_have_incompatible_return_types_0_and_1 + case "Construct_signatures_with_no_arguments_have_incompatible_return_types_0_and_1_2205": + return Construct_signatures_with_no_arguments_have_incompatible_return_types_0_and_1 + case "The_type_modifier_cannot_be_used_on_a_named_import_when_import_type_is_used_on_its_import_statement_2206": + return The_type_modifier_cannot_be_used_on_a_named_import_when_import_type_is_used_on_its_import_statement + case "The_type_modifier_cannot_be_used_on_a_named_export_when_export_type_is_used_on_its_export_statement_2207": + return The_type_modifier_cannot_be_used_on_a_named_export_when_export_type_is_used_on_its_export_statement + case "This_type_parameter_might_need_an_extends_0_constraint_2208": + return This_type_parameter_might_need_an_extends_0_constraint + case "The_project_root_is_ambiguous_but_is_required_to_resolve_export_map_entry_0_in_file_1_Supply_the_roo_2209": + return The_project_root_is_ambiguous_but_is_required_to_resolve_export_map_entry_0_in_file_1_Supply_the_rootDir_compiler_option_to_disambiguate + case "The_project_root_is_ambiguous_but_is_required_to_resolve_import_map_entry_0_in_file_1_Supply_the_roo_2210": + return The_project_root_is_ambiguous_but_is_required_to_resolve_import_map_entry_0_in_file_1_Supply_the_rootDir_compiler_option_to_disambiguate + case "Add_extends_constraint_2211": + return Add_extends_constraint + case "Add_extends_constraint_to_all_type_parameters_2212": + return Add_extends_constraint_to_all_type_parameters + case "Duplicate_identifier_0_2300": + return Duplicate_identifier_0 + case "Initializer_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2301": + return Initializer_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor + case "Static_members_cannot_reference_class_type_parameters_2302": + return Static_members_cannot_reference_class_type_parameters + case "Circular_definition_of_import_alias_0_2303": + return Circular_definition_of_import_alias_0 + case "Cannot_find_name_0_2304": + return Cannot_find_name_0 + case "Module_0_has_no_exported_member_1_2305": + return Module_0_has_no_exported_member_1 + case "File_0_is_not_a_module_2306": + return File_0_is_not_a_module + case "Cannot_find_module_0_or_its_corresponding_type_declarations_2307": + return Cannot_find_module_0_or_its_corresponding_type_declarations + case "Module_0_has_already_exported_a_member_named_1_Consider_explicitly_re_exporting_to_resolve_the_ambig_2308": + return Module_0_has_already_exported_a_member_named_1_Consider_explicitly_re_exporting_to_resolve_the_ambiguity + case "An_export_assignment_cannot_be_used_in_a_module_with_other_exported_elements_2309": + return An_export_assignment_cannot_be_used_in_a_module_with_other_exported_elements + case "Type_0_recursively_references_itself_as_a_base_type_2310": + return Type_0_recursively_references_itself_as_a_base_type + case "Cannot_find_name_0_Did_you_mean_to_write_this_in_an_async_function_2311": + return Cannot_find_name_0_Did_you_mean_to_write_this_in_an_async_function + case "An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_me_2312": + return An_interface_can_only_extend_an_object_type_or_intersection_of_object_types_with_statically_known_members + case "Type_parameter_0_has_a_circular_constraint_2313": + return Type_parameter_0_has_a_circular_constraint + case "Generic_type_0_requires_1_type_argument_s_2314": + return Generic_type_0_requires_1_type_argument_s + case "Type_0_is_not_generic_2315": + return Type_0_is_not_generic + case "Global_type_0_must_be_a_class_or_interface_type_2316": + return Global_type_0_must_be_a_class_or_interface_type + case "Global_type_0_must_have_1_type_parameter_s_2317": + return Global_type_0_must_have_1_type_parameter_s + case "Cannot_find_global_type_0_2318": + return Cannot_find_global_type_0 + case "Named_property_0_of_types_1_and_2_are_not_identical_2319": + return Named_property_0_of_types_1_and_2_are_not_identical + case "Interface_0_cannot_simultaneously_extend_types_1_and_2_2320": + return Interface_0_cannot_simultaneously_extend_types_1_and_2 + case "Excessive_stack_depth_comparing_types_0_and_1_2321": + return Excessive_stack_depth_comparing_types_0_and_1 + case "Type_0_is_not_assignable_to_type_1_2322": + return Type_0_is_not_assignable_to_type_1 + case "Cannot_redeclare_exported_variable_0_2323": + return Cannot_redeclare_exported_variable_0 + case "Property_0_is_missing_in_type_1_2324": + return Property_0_is_missing_in_type_1 + case "Property_0_is_private_in_type_1_but_not_in_type_2_2325": + return Property_0_is_private_in_type_1_but_not_in_type_2 + case "Types_of_property_0_are_incompatible_2326": + return Types_of_property_0_are_incompatible + case "Property_0_is_optional_in_type_1_but_required_in_type_2_2327": + return Property_0_is_optional_in_type_1_but_required_in_type_2 + case "Types_of_parameters_0_and_1_are_incompatible_2328": + return Types_of_parameters_0_and_1_are_incompatible + case "Index_signature_for_type_0_is_missing_in_type_1_2329": + return Index_signature_for_type_0_is_missing_in_type_1 + case "_0_and_1_index_signatures_are_incompatible_2330": + return X_0_and_1_index_signatures_are_incompatible + case "this_cannot_be_referenced_in_a_module_or_namespace_body_2331": + return X_this_cannot_be_referenced_in_a_module_or_namespace_body + case "this_cannot_be_referenced_in_current_location_2332": + return X_this_cannot_be_referenced_in_current_location + case "this_cannot_be_referenced_in_a_static_property_initializer_2334": + return X_this_cannot_be_referenced_in_a_static_property_initializer + case "super_can_only_be_referenced_in_a_derived_class_2335": + return X_super_can_only_be_referenced_in_a_derived_class + case "super_cannot_be_referenced_in_constructor_arguments_2336": + return X_super_cannot_be_referenced_in_constructor_arguments + case "Super_calls_are_not_permitted_outside_constructors_or_in_nested_functions_inside_constructors_2337": + return Super_calls_are_not_permitted_outside_constructors_or_in_nested_functions_inside_constructors + case "super_property_access_is_permitted_only_in_a_constructor_member_function_or_member_accessor_of_a_der_2338": + return X_super_property_access_is_permitted_only_in_a_constructor_member_function_or_member_accessor_of_a_derived_class + case "Property_0_does_not_exist_on_type_1_2339": + return Property_0_does_not_exist_on_type_1 + case "Only_public_and_protected_methods_of_the_base_class_are_accessible_via_the_super_keyword_2340": + return Only_public_and_protected_methods_of_the_base_class_are_accessible_via_the_super_keyword + case "Property_0_is_private_and_only_accessible_within_class_1_2341": + return Property_0_is_private_and_only_accessible_within_class_1 + case "This_syntax_requires_an_imported_helper_named_1_which_does_not_exist_in_0_Consider_upgrading_your_ve_2343": + return This_syntax_requires_an_imported_helper_named_1_which_does_not_exist_in_0_Consider_upgrading_your_version_of_0 + case "Type_0_does_not_satisfy_the_constraint_1_2344": + return Type_0_does_not_satisfy_the_constraint_1 + case "Argument_of_type_0_is_not_assignable_to_parameter_of_type_1_2345": + return Argument_of_type_0_is_not_assignable_to_parameter_of_type_1 + case "Call_target_does_not_contain_any_signatures_2346": + return Call_target_does_not_contain_any_signatures + case "Untyped_function_calls_may_not_accept_type_arguments_2347": + return Untyped_function_calls_may_not_accept_type_arguments + case "Value_of_type_0_is_not_callable_Did_you_mean_to_include_new_2348": + return Value_of_type_0_is_not_callable_Did_you_mean_to_include_new + case "This_expression_is_not_callable_2349": + return This_expression_is_not_callable + case "Only_a_void_function_can_be_called_with_the_new_keyword_2350": + return Only_a_void_function_can_be_called_with_the_new_keyword + case "This_expression_is_not_constructable_2351": + return This_expression_is_not_constructable + case "Conversion_of_type_0_to_type_1_may_be_a_mistake_because_neither_type_sufficiently_overlaps_with_the__2352": + return Conversion_of_type_0_to_type_1_may_be_a_mistake_because_neither_type_sufficiently_overlaps_with_the_other_If_this_was_intentional_convert_the_expression_to_unknown_first + case "Object_literal_may_only_specify_known_properties_and_0_does_not_exist_in_type_1_2353": + return Object_literal_may_only_specify_known_properties_and_0_does_not_exist_in_type_1 + case "This_syntax_requires_an_imported_helper_but_module_0_cannot_be_found_2354": + return This_syntax_requires_an_imported_helper_but_module_0_cannot_be_found + case "A_function_whose_declared_type_is_neither_undefined_void_nor_any_must_return_a_value_2355": + return A_function_whose_declared_type_is_neither_undefined_void_nor_any_must_return_a_value + case "An_arithmetic_operand_must_be_of_type_any_number_bigint_or_an_enum_type_2356": + return An_arithmetic_operand_must_be_of_type_any_number_bigint_or_an_enum_type + case "The_operand_of_an_increment_or_decrement_operator_must_be_a_variable_or_a_property_access_2357": + return The_operand_of_an_increment_or_decrement_operator_must_be_a_variable_or_a_property_access + case "The_left_hand_side_of_an_instanceof_expression_must_be_of_type_any_an_object_type_or_a_type_paramete_2358": + return The_left_hand_side_of_an_instanceof_expression_must_be_of_type_any_an_object_type_or_a_type_parameter + case "The_right_hand_side_of_an_instanceof_expression_must_be_either_of_type_any_a_class_function_or_other_2359": + return The_right_hand_side_of_an_instanceof_expression_must_be_either_of_type_any_a_class_function_or_other_type_assignable_to_the_Function_interface_type_or_an_object_type_with_a_Symbol_hasInstance_method + case "The_left_hand_side_of_an_arithmetic_operation_must_be_of_type_any_number_bigint_or_an_enum_type_2362": + return The_left_hand_side_of_an_arithmetic_operation_must_be_of_type_any_number_bigint_or_an_enum_type + case "The_right_hand_side_of_an_arithmetic_operation_must_be_of_type_any_number_bigint_or_an_enum_type_2363": + return The_right_hand_side_of_an_arithmetic_operation_must_be_of_type_any_number_bigint_or_an_enum_type + case "The_left_hand_side_of_an_assignment_expression_must_be_a_variable_or_a_property_access_2364": + return The_left_hand_side_of_an_assignment_expression_must_be_a_variable_or_a_property_access + case "Operator_0_cannot_be_applied_to_types_1_and_2_2365": + return Operator_0_cannot_be_applied_to_types_1_and_2 + case "Function_lacks_ending_return_statement_and_return_type_does_not_include_undefined_2366": + return Function_lacks_ending_return_statement_and_return_type_does_not_include_undefined + case "This_comparison_appears_to_be_unintentional_because_the_types_0_and_1_have_no_overlap_2367": + return This_comparison_appears_to_be_unintentional_because_the_types_0_and_1_have_no_overlap + case "Type_parameter_name_cannot_be_0_2368": + return Type_parameter_name_cannot_be_0 + case "A_parameter_property_is_only_allowed_in_a_constructor_implementation_2369": + return A_parameter_property_is_only_allowed_in_a_constructor_implementation + case "A_rest_parameter_must_be_of_an_array_type_2370": + return A_rest_parameter_must_be_of_an_array_type + case "A_parameter_initializer_is_only_allowed_in_a_function_or_constructor_implementation_2371": + return A_parameter_initializer_is_only_allowed_in_a_function_or_constructor_implementation + case "Parameter_0_cannot_reference_itself_2372": + return Parameter_0_cannot_reference_itself + case "Parameter_0_cannot_reference_identifier_1_declared_after_it_2373": + return Parameter_0_cannot_reference_identifier_1_declared_after_it + case "Duplicate_index_signature_for_type_0_2374": + return Duplicate_index_signature_for_type_0 + case "Type_0_is_not_assignable_to_type_1_with_exactOptionalPropertyTypes_Colon_true_Consider_adding_undefi_2375": + return Type_0_is_not_assignable_to_type_1_with_exactOptionalPropertyTypes_Colon_true_Consider_adding_undefined_to_the_types_of_the_target_s_properties + case "A_super_call_must_be_the_first_statement_in_the_constructor_to_refer_to_super_or_this_when_a_derived_2376": + return A_super_call_must_be_the_first_statement_in_the_constructor_to_refer_to_super_or_this_when_a_derived_class_contains_initialized_properties_parameter_properties_or_private_identifiers + case "Constructors_for_derived_classes_must_contain_a_super_call_2377": + return Constructors_for_derived_classes_must_contain_a_super_call + case "A_get_accessor_must_return_a_value_2378": + return A_get_accessor_must_return_a_value + case "Argument_of_type_0_is_not_assignable_to_parameter_of_type_1_with_exactOptionalPropertyTypes_Colon_tr_2379": + return Argument_of_type_0_is_not_assignable_to_parameter_of_type_1_with_exactOptionalPropertyTypes_Colon_true_Consider_adding_undefined_to_the_types_of_the_target_s_properties + case "Overload_signatures_must_all_be_exported_or_non_exported_2383": + return Overload_signatures_must_all_be_exported_or_non_exported + case "Overload_signatures_must_all_be_ambient_or_non_ambient_2384": + return Overload_signatures_must_all_be_ambient_or_non_ambient + case "Overload_signatures_must_all_be_public_private_or_protected_2385": + return Overload_signatures_must_all_be_public_private_or_protected + case "Overload_signatures_must_all_be_optional_or_required_2386": + return Overload_signatures_must_all_be_optional_or_required + case "Function_overload_must_be_static_2387": + return Function_overload_must_be_static + case "Function_overload_must_not_be_static_2388": + return Function_overload_must_not_be_static + case "Function_implementation_name_must_be_0_2389": + return Function_implementation_name_must_be_0 + case "Constructor_implementation_is_missing_2390": + return Constructor_implementation_is_missing + case "Function_implementation_is_missing_or_not_immediately_following_the_declaration_2391": + return Function_implementation_is_missing_or_not_immediately_following_the_declaration + case "Multiple_constructor_implementations_are_not_allowed_2392": + return Multiple_constructor_implementations_are_not_allowed + case "Duplicate_function_implementation_2393": + return Duplicate_function_implementation + case "This_overload_signature_is_not_compatible_with_its_implementation_signature_2394": + return This_overload_signature_is_not_compatible_with_its_implementation_signature + case "Individual_declarations_in_merged_declaration_0_must_be_all_exported_or_all_local_2395": + return Individual_declarations_in_merged_declaration_0_must_be_all_exported_or_all_local + case "Duplicate_identifier_arguments_Compiler_uses_arguments_to_initialize_rest_parameters_2396": + return Duplicate_identifier_arguments_Compiler_uses_arguments_to_initialize_rest_parameters + case "Declaration_name_conflicts_with_built_in_global_identifier_0_2397": + return Declaration_name_conflicts_with_built_in_global_identifier_0 + case "constructor_cannot_be_used_as_a_parameter_property_name_2398": + return X_constructor_cannot_be_used_as_a_parameter_property_name + case "Duplicate_identifier_this_Compiler_uses_variable_declaration_this_to_capture_this_reference_2399": + return Duplicate_identifier_this_Compiler_uses_variable_declaration_this_to_capture_this_reference + case "Expression_resolves_to_variable_declaration_this_that_compiler_uses_to_capture_this_reference_2400": + return Expression_resolves_to_variable_declaration_this_that_compiler_uses_to_capture_this_reference + case "A_super_call_must_be_a_root_level_statement_within_a_constructor_of_a_derived_class_that_contains_in_2401": + return A_super_call_must_be_a_root_level_statement_within_a_constructor_of_a_derived_class_that_contains_initialized_properties_parameter_properties_or_private_identifiers + case "Expression_resolves_to_super_that_compiler_uses_to_capture_base_class_reference_2402": + return Expression_resolves_to_super_that_compiler_uses_to_capture_base_class_reference + case "Subsequent_variable_declarations_must_have_the_same_type_Variable_0_must_be_of_type_1_but_here_has_t_2403": + return Subsequent_variable_declarations_must_have_the_same_type_Variable_0_must_be_of_type_1_but_here_has_type_2 + case "The_left_hand_side_of_a_for_in_statement_cannot_use_a_type_annotation_2404": + return The_left_hand_side_of_a_for_in_statement_cannot_use_a_type_annotation + case "The_left_hand_side_of_a_for_in_statement_must_be_of_type_string_or_any_2405": + return The_left_hand_side_of_a_for_in_statement_must_be_of_type_string_or_any + case "The_left_hand_side_of_a_for_in_statement_must_be_a_variable_or_a_property_access_2406": + return The_left_hand_side_of_a_for_in_statement_must_be_a_variable_or_a_property_access + case "The_right_hand_side_of_a_for_in_statement_must_be_of_type_any_an_object_type_or_a_type_parameter_but_2407": + return The_right_hand_side_of_a_for_in_statement_must_be_of_type_any_an_object_type_or_a_type_parameter_but_here_has_type_0 + case "Setters_cannot_return_a_value_2408": + return Setters_cannot_return_a_value + case "Return_type_of_constructor_signature_must_be_assignable_to_the_instance_type_of_the_class_2409": + return Return_type_of_constructor_signature_must_be_assignable_to_the_instance_type_of_the_class + case "The_with_statement_is_not_supported_All_symbols_in_a_with_block_will_have_type_any_2410": + return The_with_statement_is_not_supported_All_symbols_in_a_with_block_will_have_type_any + case "Property_0_of_type_1_is_not_assignable_to_2_index_type_3_2411": + return Property_0_of_type_1_is_not_assignable_to_2_index_type_3 + case "Type_0_is_not_assignable_to_type_1_with_exactOptionalPropertyTypes_Colon_true_Consider_adding_undefi_2412": + return Type_0_is_not_assignable_to_type_1_with_exactOptionalPropertyTypes_Colon_true_Consider_adding_undefined_to_the_type_of_the_target + case "_0_index_type_1_is_not_assignable_to_2_index_type_3_2413": + return X_0_index_type_1_is_not_assignable_to_2_index_type_3 + case "Class_name_cannot_be_0_2414": + return Class_name_cannot_be_0 + case "Class_0_incorrectly_extends_base_class_1_2415": + return Class_0_incorrectly_extends_base_class_1 + case "Property_0_in_type_1_is_not_assignable_to_the_same_property_in_base_type_2_2416": + return Property_0_in_type_1_is_not_assignable_to_the_same_property_in_base_type_2 + case "Class_static_side_0_incorrectly_extends_base_class_static_side_1_2417": + return Class_static_side_0_incorrectly_extends_base_class_static_side_1 + case "Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1_2418": + return Type_of_computed_property_s_value_is_0_which_is_not_assignable_to_type_1 + case "Types_of_construct_signatures_are_incompatible_2419": + return Types_of_construct_signatures_are_incompatible + case "Class_0_incorrectly_implements_interface_1_2420": + return Class_0_incorrectly_implements_interface_1 + case "A_class_can_only_implement_an_object_type_or_intersection_of_object_types_with_statically_known_memb_2422": + return A_class_can_only_implement_an_object_type_or_intersection_of_object_types_with_statically_known_members + case "Class_0_defines_instance_member_function_1_but_extended_class_2_defines_it_as_instance_member_access_2423": + return Class_0_defines_instance_member_function_1_but_extended_class_2_defines_it_as_instance_member_accessor + case "Class_0_defines_instance_member_property_1_but_extended_class_2_defines_it_as_instance_member_functi_2425": + return Class_0_defines_instance_member_property_1_but_extended_class_2_defines_it_as_instance_member_function + case "Class_0_defines_instance_member_accessor_1_but_extended_class_2_defines_it_as_instance_member_functi_2426": + return Class_0_defines_instance_member_accessor_1_but_extended_class_2_defines_it_as_instance_member_function + case "Interface_name_cannot_be_0_2427": + return Interface_name_cannot_be_0 + case "All_declarations_of_0_must_have_identical_type_parameters_2428": + return All_declarations_of_0_must_have_identical_type_parameters + case "Interface_0_incorrectly_extends_interface_1_2430": + return Interface_0_incorrectly_extends_interface_1 + case "Enum_name_cannot_be_0_2431": + return Enum_name_cannot_be_0 + case "In_an_enum_with_multiple_declarations_only_one_declaration_can_omit_an_initializer_for_its_first_enu_2432": + return In_an_enum_with_multiple_declarations_only_one_declaration_can_omit_an_initializer_for_its_first_enum_element + case "A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merg_2433": + return A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merged + case "A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged_2434": + return A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged + case "Ambient_modules_cannot_be_nested_in_other_modules_or_namespaces_2435": + return Ambient_modules_cannot_be_nested_in_other_modules_or_namespaces + case "Ambient_module_declaration_cannot_specify_relative_module_name_2436": + return Ambient_module_declaration_cannot_specify_relative_module_name + case "Module_0_is_hidden_by_a_local_declaration_with_the_same_name_2437": + return Module_0_is_hidden_by_a_local_declaration_with_the_same_name + case "Import_name_cannot_be_0_2438": + return Import_name_cannot_be_0 + case "Import_or_export_declaration_in_an_ambient_module_declaration_cannot_reference_module_through_relati_2439": + return Import_or_export_declaration_in_an_ambient_module_declaration_cannot_reference_module_through_relative_module_name + case "Import_declaration_conflicts_with_local_declaration_of_0_2440": + return Import_declaration_conflicts_with_local_declaration_of_0 + case "Duplicate_identifier_0_Compiler_reserves_name_1_in_top_level_scope_of_a_module_2441": + return Duplicate_identifier_0_Compiler_reserves_name_1_in_top_level_scope_of_a_module + case "Types_have_separate_declarations_of_a_private_property_0_2442": + return Types_have_separate_declarations_of_a_private_property_0 + case "Property_0_is_protected_but_type_1_is_not_a_class_derived_from_2_2443": + return Property_0_is_protected_but_type_1_is_not_a_class_derived_from_2 + case "Property_0_is_protected_in_type_1_but_public_in_type_2_2444": + return Property_0_is_protected_in_type_1_but_public_in_type_2 + case "Property_0_is_protected_and_only_accessible_within_class_1_and_its_subclasses_2445": + return Property_0_is_protected_and_only_accessible_within_class_1_and_its_subclasses + case "Property_0_is_protected_and_only_accessible_through_an_instance_of_class_1_This_is_an_instance_of_cl_2446": + return Property_0_is_protected_and_only_accessible_through_an_instance_of_class_1_This_is_an_instance_of_class_2 + case "The_0_operator_is_not_allowed_for_boolean_types_Consider_using_1_instead_2447": + return The_0_operator_is_not_allowed_for_boolean_types_Consider_using_1_instead + case "Block_scoped_variable_0_used_before_its_declaration_2448": + return Block_scoped_variable_0_used_before_its_declaration + case "Class_0_used_before_its_declaration_2449": + return Class_0_used_before_its_declaration + case "Enum_0_used_before_its_declaration_2450": + return Enum_0_used_before_its_declaration + case "Cannot_redeclare_block_scoped_variable_0_2451": + return Cannot_redeclare_block_scoped_variable_0 + case "An_enum_member_cannot_have_a_numeric_name_2452": + return An_enum_member_cannot_have_a_numeric_name + case "Variable_0_is_used_before_being_assigned_2454": + return Variable_0_is_used_before_being_assigned + case "Type_alias_0_circularly_references_itself_2456": + return Type_alias_0_circularly_references_itself + case "Type_alias_name_cannot_be_0_2457": + return Type_alias_name_cannot_be_0 + case "An_AMD_module_cannot_have_multiple_name_assignments_2458": + return An_AMD_module_cannot_have_multiple_name_assignments + case "Module_0_declares_1_locally_but_it_is_not_exported_2459": + return Module_0_declares_1_locally_but_it_is_not_exported + case "Module_0_declares_1_locally_but_it_is_exported_as_2_2460": + return Module_0_declares_1_locally_but_it_is_exported_as_2 + case "Type_0_is_not_an_array_type_2461": + return Type_0_is_not_an_array_type + case "A_rest_element_must_be_last_in_a_destructuring_pattern_2462": + return A_rest_element_must_be_last_in_a_destructuring_pattern + case "A_binding_pattern_parameter_cannot_be_optional_in_an_implementation_signature_2463": + return A_binding_pattern_parameter_cannot_be_optional_in_an_implementation_signature + case "A_computed_property_name_must_be_of_type_string_number_symbol_or_any_2464": + return A_computed_property_name_must_be_of_type_string_number_symbol_or_any + case "this_cannot_be_referenced_in_a_computed_property_name_2465": + return X_this_cannot_be_referenced_in_a_computed_property_name + case "super_cannot_be_referenced_in_a_computed_property_name_2466": + return X_super_cannot_be_referenced_in_a_computed_property_name + case "A_computed_property_name_cannot_reference_a_type_parameter_from_its_containing_type_2467": + return A_computed_property_name_cannot_reference_a_type_parameter_from_its_containing_type + case "Cannot_find_global_value_0_2468": + return Cannot_find_global_value_0 + case "The_0_operator_cannot_be_applied_to_type_symbol_2469": + return The_0_operator_cannot_be_applied_to_type_symbol + case "Spread_operator_in_new_expressions_is_only_available_when_targeting_ECMAScript_5_and_higher_2472": + return Spread_operator_in_new_expressions_is_only_available_when_targeting_ECMAScript_5_and_higher + case "Enum_declarations_must_all_be_const_or_non_const_2473": + return Enum_declarations_must_all_be_const_or_non_const + case "const_enum_member_initializers_must_be_constant_expressions_2474": + return X_const_enum_member_initializers_must_be_constant_expressions + case "const_enums_can_only_be_used_in_property_or_index_access_expressions_or_the_right_hand_side_of_an_im_2475": + return X_const_enums_can_only_be_used_in_property_or_index_access_expressions_or_the_right_hand_side_of_an_import_declaration_or_export_assignment_or_type_query + case "A_const_enum_member_can_only_be_accessed_using_a_string_literal_2476": + return A_const_enum_member_can_only_be_accessed_using_a_string_literal + case "const_enum_member_initializer_was_evaluated_to_a_non_finite_value_2477": + return X_const_enum_member_initializer_was_evaluated_to_a_non_finite_value + case "const_enum_member_initializer_was_evaluated_to_disallowed_value_NaN_2478": + return X_const_enum_member_initializer_was_evaluated_to_disallowed_value_NaN + case "let_is_not_allowed_to_be_used_as_a_name_in_let_or_const_declarations_2480": + return X_let_is_not_allowed_to_be_used_as_a_name_in_let_or_const_declarations + case "Cannot_initialize_outer_scoped_variable_0_in_the_same_scope_as_block_scoped_declaration_1_2481": + return Cannot_initialize_outer_scoped_variable_0_in_the_same_scope_as_block_scoped_declaration_1 + case "The_left_hand_side_of_a_for_of_statement_cannot_use_a_type_annotation_2483": + return The_left_hand_side_of_a_for_of_statement_cannot_use_a_type_annotation + case "Export_declaration_conflicts_with_exported_declaration_of_0_2484": + return Export_declaration_conflicts_with_exported_declaration_of_0 + case "The_left_hand_side_of_a_for_of_statement_must_be_a_variable_or_a_property_access_2487": + return The_left_hand_side_of_a_for_of_statement_must_be_a_variable_or_a_property_access + case "Type_0_must_have_a_Symbol_iterator_method_that_returns_an_iterator_2488": + return Type_0_must_have_a_Symbol_iterator_method_that_returns_an_iterator + case "An_iterator_must_have_a_next_method_2489": + return An_iterator_must_have_a_next_method + case "The_type_returned_by_the_0_method_of_an_iterator_must_have_a_value_property_2490": + return The_type_returned_by_the_0_method_of_an_iterator_must_have_a_value_property + case "The_left_hand_side_of_a_for_in_statement_cannot_be_a_destructuring_pattern_2491": + return The_left_hand_side_of_a_for_in_statement_cannot_be_a_destructuring_pattern + case "Cannot_redeclare_identifier_0_in_catch_clause_2492": + return Cannot_redeclare_identifier_0_in_catch_clause + case "Tuple_type_0_of_length_1_has_no_element_at_index_2_2493": + return Tuple_type_0_of_length_1_has_no_element_at_index_2 + case "Using_a_string_in_a_for_of_statement_is_only_supported_in_ECMAScript_5_and_higher_2494": + return Using_a_string_in_a_for_of_statement_is_only_supported_in_ECMAScript_5_and_higher + case "Type_0_is_not_an_array_type_or_a_string_type_2495": + return Type_0_is_not_an_array_type_or_a_string_type + case "The_arguments_object_cannot_be_referenced_in_an_arrow_function_in_ES5_Consider_using_a_standard_func_2496": + return The_arguments_object_cannot_be_referenced_in_an_arrow_function_in_ES5_Consider_using_a_standard_function_expression + case "This_module_can_only_be_referenced_with_ECMAScript_imports_Slashexports_by_turning_on_the_0_flag_and_2497": + return This_module_can_only_be_referenced_with_ECMAScript_imports_Slashexports_by_turning_on_the_0_flag_and_referencing_its_default_export + case "Module_0_uses_export_and_cannot_be_used_with_export_Asterisk_2498": + return Module_0_uses_export_and_cannot_be_used_with_export_Asterisk + case "An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments_2499": + return An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments + case "A_class_can_only_implement_an_identifier_Slashqualified_name_with_optional_type_arguments_2500": + return A_class_can_only_implement_an_identifier_Slashqualified_name_with_optional_type_arguments + case "A_rest_element_cannot_contain_a_binding_pattern_2501": + return A_rest_element_cannot_contain_a_binding_pattern + case "_0_is_referenced_directly_or_indirectly_in_its_own_type_annotation_2502": + return X_0_is_referenced_directly_or_indirectly_in_its_own_type_annotation + case "Cannot_find_namespace_0_2503": + return Cannot_find_namespace_0 + case "Type_0_must_have_a_Symbol_asyncIterator_method_that_returns_an_async_iterator_2504": + return Type_0_must_have_a_Symbol_asyncIterator_method_that_returns_an_async_iterator + case "A_generator_cannot_have_a_void_type_annotation_2505": + return A_generator_cannot_have_a_void_type_annotation + case "_0_is_referenced_directly_or_indirectly_in_its_own_base_expression_2506": + return X_0_is_referenced_directly_or_indirectly_in_its_own_base_expression + case "Type_0_is_not_a_constructor_function_type_2507": + return Type_0_is_not_a_constructor_function_type + case "No_base_constructor_has_the_specified_number_of_type_arguments_2508": + return No_base_constructor_has_the_specified_number_of_type_arguments + case "Base_constructor_return_type_0_is_not_an_object_type_or_intersection_of_object_types_with_statically_2509": + return Base_constructor_return_type_0_is_not_an_object_type_or_intersection_of_object_types_with_statically_known_members + case "Base_constructors_must_all_have_the_same_return_type_2510": + return Base_constructors_must_all_have_the_same_return_type + case "Cannot_create_an_instance_of_an_abstract_class_2511": + return Cannot_create_an_instance_of_an_abstract_class + case "Overload_signatures_must_all_be_abstract_or_non_abstract_2512": + return Overload_signatures_must_all_be_abstract_or_non_abstract + case "Abstract_method_0_in_class_1_cannot_be_accessed_via_super_expression_2513": + return Abstract_method_0_in_class_1_cannot_be_accessed_via_super_expression + case "A_tuple_type_cannot_be_indexed_with_a_negative_value_2514": + return A_tuple_type_cannot_be_indexed_with_a_negative_value + case "Non_abstract_class_0_does_not_implement_inherited_abstract_member_1_from_class_2_2515": + return Non_abstract_class_0_does_not_implement_inherited_abstract_member_1_from_class_2 + case "All_declarations_of_an_abstract_method_must_be_consecutive_2516": + return All_declarations_of_an_abstract_method_must_be_consecutive + case "Cannot_assign_an_abstract_constructor_type_to_a_non_abstract_constructor_type_2517": + return Cannot_assign_an_abstract_constructor_type_to_a_non_abstract_constructor_type + case "A_this_based_type_guard_is_not_compatible_with_a_parameter_based_type_guard_2518": + return A_this_based_type_guard_is_not_compatible_with_a_parameter_based_type_guard + case "An_async_iterator_must_have_a_next_method_2519": + return An_async_iterator_must_have_a_next_method + case "Duplicate_identifier_0_Compiler_uses_declaration_1_to_support_async_functions_2520": + return Duplicate_identifier_0_Compiler_uses_declaration_1_to_support_async_functions + case "The_arguments_object_cannot_be_referenced_in_an_async_function_or_method_in_ES5_Consider_using_a_sta_2522": + return The_arguments_object_cannot_be_referenced_in_an_async_function_or_method_in_ES5_Consider_using_a_standard_function_or_method + case "yield_expressions_cannot_be_used_in_a_parameter_initializer_2523": + return X_yield_expressions_cannot_be_used_in_a_parameter_initializer + case "await_expressions_cannot_be_used_in_a_parameter_initializer_2524": + return X_await_expressions_cannot_be_used_in_a_parameter_initializer + case "A_this_type_is_available_only_in_a_non_static_member_of_a_class_or_interface_2526": + return A_this_type_is_available_only_in_a_non_static_member_of_a_class_or_interface + case "The_inferred_type_of_0_references_an_inaccessible_1_type_A_type_annotation_is_necessary_2527": + return The_inferred_type_of_0_references_an_inaccessible_1_type_A_type_annotation_is_necessary + case "A_module_cannot_have_multiple_default_exports_2528": + return A_module_cannot_have_multiple_default_exports + case "Duplicate_identifier_0_Compiler_reserves_name_1_in_top_level_scope_of_a_module_containing_async_func_2529": + return Duplicate_identifier_0_Compiler_reserves_name_1_in_top_level_scope_of_a_module_containing_async_functions + case "Property_0_is_incompatible_with_index_signature_2530": + return Property_0_is_incompatible_with_index_signature + case "Object_is_possibly_null_2531": + return Object_is_possibly_null + case "Object_is_possibly_undefined_2532": + return Object_is_possibly_undefined + case "Object_is_possibly_null_or_undefined_2533": + return Object_is_possibly_null_or_undefined + case "A_function_returning_never_cannot_have_a_reachable_end_point_2534": + return A_function_returning_never_cannot_have_a_reachable_end_point + case "Type_0_cannot_be_used_to_index_type_1_2536": + return Type_0_cannot_be_used_to_index_type_1 + case "Type_0_has_no_matching_index_signature_for_type_1_2537": + return Type_0_has_no_matching_index_signature_for_type_1 + case "Type_0_cannot_be_used_as_an_index_type_2538": + return Type_0_cannot_be_used_as_an_index_type + case "Cannot_assign_to_0_because_it_is_not_a_variable_2539": + return Cannot_assign_to_0_because_it_is_not_a_variable + case "Cannot_assign_to_0_because_it_is_a_read_only_property_2540": + return Cannot_assign_to_0_because_it_is_a_read_only_property + case "Index_signature_in_type_0_only_permits_reading_2542": + return Index_signature_in_type_0_only_permits_reading + case "Duplicate_identifier_newTarget_Compiler_uses_variable_declaration_newTarget_to_capture_new_target_me_2543": + return Duplicate_identifier_newTarget_Compiler_uses_variable_declaration_newTarget_to_capture_new_target_meta_property_reference + case "Expression_resolves_to_variable_declaration_newTarget_that_compiler_uses_to_capture_new_target_meta__2544": + return Expression_resolves_to_variable_declaration_newTarget_that_compiler_uses_to_capture_new_target_meta_property_reference + case "A_mixin_class_must_have_a_constructor_with_a_single_rest_parameter_of_type_any_2545": + return A_mixin_class_must_have_a_constructor_with_a_single_rest_parameter_of_type_any + case "The_type_returned_by_the_0_method_of_an_async_iterator_must_be_a_promise_for_a_type_with_a_value_pro_2547": + return The_type_returned_by_the_0_method_of_an_async_iterator_must_be_a_promise_for_a_type_with_a_value_property + case "Type_0_is_not_an_array_type_or_does_not_have_a_Symbol_iterator_method_that_returns_an_iterator_2548": + return Type_0_is_not_an_array_type_or_does_not_have_a_Symbol_iterator_method_that_returns_an_iterator + case "Type_0_is_not_an_array_type_or_a_string_type_or_does_not_have_a_Symbol_iterator_method_that_returns__2549": + return Type_0_is_not_an_array_type_or_a_string_type_or_does_not_have_a_Symbol_iterator_method_that_returns_an_iterator + case "Property_0_does_not_exist_on_type_1_Do_you_need_to_change_your_target_library_Try_changing_the_lib_c_2550": + return Property_0_does_not_exist_on_type_1_Do_you_need_to_change_your_target_library_Try_changing_the_lib_compiler_option_to_2_or_later + case "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551": + return Property_0_does_not_exist_on_type_1_Did_you_mean_2 + case "Cannot_find_name_0_Did_you_mean_1_2552": + return Cannot_find_name_0_Did_you_mean_1 + case "Computed_values_are_not_permitted_in_an_enum_with_string_valued_members_2553": + return Computed_values_are_not_permitted_in_an_enum_with_string_valued_members + case "Expected_0_arguments_but_got_1_2554": + return Expected_0_arguments_but_got_1 + case "Expected_at_least_0_arguments_but_got_1_2555": + return Expected_at_least_0_arguments_but_got_1 + case "A_spread_argument_must_either_have_a_tuple_type_or_be_passed_to_a_rest_parameter_2556": + return A_spread_argument_must_either_have_a_tuple_type_or_be_passed_to_a_rest_parameter + case "Expected_0_type_arguments_but_got_1_2558": + return Expected_0_type_arguments_but_got_1 + case "Type_0_has_no_properties_in_common_with_type_1_2559": + return Type_0_has_no_properties_in_common_with_type_1 + case "Value_of_type_0_has_no_properties_in_common_with_type_1_Did_you_mean_to_call_it_2560": + return Value_of_type_0_has_no_properties_in_common_with_type_1_Did_you_mean_to_call_it + case "Object_literal_may_only_specify_known_properties_but_0_does_not_exist_in_type_1_Did_you_mean_to_writ_2561": + return Object_literal_may_only_specify_known_properties_but_0_does_not_exist_in_type_1_Did_you_mean_to_write_2 + case "Base_class_expressions_cannot_reference_class_type_parameters_2562": + return Base_class_expressions_cannot_reference_class_type_parameters + case "The_containing_function_or_module_body_is_too_large_for_control_flow_analysis_2563": + return The_containing_function_or_module_body_is_too_large_for_control_flow_analysis + case "Property_0_has_no_initializer_and_is_not_definitely_assigned_in_the_constructor_2564": + return Property_0_has_no_initializer_and_is_not_definitely_assigned_in_the_constructor + case "Property_0_is_used_before_being_assigned_2565": + return Property_0_is_used_before_being_assigned + case "A_rest_element_cannot_have_a_property_name_2566": + return A_rest_element_cannot_have_a_property_name + case "Enum_declarations_can_only_merge_with_namespace_or_other_enum_declarations_2567": + return Enum_declarations_can_only_merge_with_namespace_or_other_enum_declarations + case "Property_0_may_not_exist_on_type_1_Did_you_mean_2_2568": + return Property_0_may_not_exist_on_type_1_Did_you_mean_2 + case "Could_not_find_name_0_Did_you_mean_1_2570": + return Could_not_find_name_0_Did_you_mean_1 + case "Object_is_of_type_unknown_2571": + return Object_is_of_type_unknown + case "A_rest_element_type_must_be_an_array_type_2574": + return A_rest_element_type_must_be_an_array_type + case "No_overload_expects_0_arguments_but_overloads_do_exist_that_expect_either_1_or_2_arguments_2575": + return No_overload_expects_0_arguments_but_overloads_do_exist_that_expect_either_1_or_2_arguments + case "Property_0_does_not_exist_on_type_1_Did_you_mean_to_access_the_static_member_2_instead_2576": + return Property_0_does_not_exist_on_type_1_Did_you_mean_to_access_the_static_member_2_instead + case "Return_type_annotation_circularly_references_itself_2577": + return Return_type_annotation_circularly_references_itself + case "Unused_ts_expect_error_directive_2578": + return Unused_ts_expect_error_directive + case "Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_node_Try_npm_i_save_dev_types_Slashno_2580": + return Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_node_Try_npm_i_save_dev_types_Slashnode + case "Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_jQuery_Try_npm_i_save_dev_types_Slash_2581": + return Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_jQuery_Try_npm_i_save_dev_types_Slashjquery + case "Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_a_test_runner_Try_npm_i_save_dev_type_2582": + return Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_a_test_runner_Try_npm_i_save_dev_types_Slashjest_or_npm_i_save_dev_types_Slashmocha + case "Cannot_find_name_0_Do_you_need_to_change_your_target_library_Try_changing_the_lib_compiler_option_to_2583": + return Cannot_find_name_0_Do_you_need_to_change_your_target_library_Try_changing_the_lib_compiler_option_to_1_or_later + case "Cannot_find_name_0_Do_you_need_to_change_your_target_library_Try_changing_the_lib_compiler_option_to_2584": + return Cannot_find_name_0_Do_you_need_to_change_your_target_library_Try_changing_the_lib_compiler_option_to_include_dom + case "_0_only_refers_to_a_type_but_is_being_used_as_a_value_here_Do_you_need_to_change_your_target_library_2585": + return X_0_only_refers_to_a_type_but_is_being_used_as_a_value_here_Do_you_need_to_change_your_target_library_Try_changing_the_lib_compiler_option_to_es2015_or_later + case "Cannot_assign_to_0_because_it_is_a_constant_2588": + return Cannot_assign_to_0_because_it_is_a_constant + case "Type_instantiation_is_excessively_deep_and_possibly_infinite_2589": + return Type_instantiation_is_excessively_deep_and_possibly_infinite + case "Expression_produces_a_union_type_that_is_too_complex_to_represent_2590": + return Expression_produces_a_union_type_that_is_too_complex_to_represent + case "Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_node_Try_npm_i_save_dev_types_Slashno_2591": + return Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_node_Try_npm_i_save_dev_types_Slashnode_and_then_add_node_to_the_types_field_in_your_tsconfig + case "Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_jQuery_Try_npm_i_save_dev_types_Slash_2592": + return Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_jQuery_Try_npm_i_save_dev_types_Slashjquery_and_then_add_jquery_to_the_types_field_in_your_tsconfig + case "Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_a_test_runner_Try_npm_i_save_dev_type_2593": + return Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_a_test_runner_Try_npm_i_save_dev_types_Slashjest_or_npm_i_save_dev_types_Slashmocha_and_then_add_jest_or_mocha_to_the_types_field_in_your_tsconfig + case "This_module_is_declared_with_export_and_can_only_be_used_with_a_default_import_when_using_the_0_flag_2594": + return This_module_is_declared_with_export_and_can_only_be_used_with_a_default_import_when_using_the_0_flag + case "_0_can_only_be_imported_by_using_a_default_import_2595": + return X_0_can_only_be_imported_by_using_a_default_import + case "_0_can_only_be_imported_by_turning_on_the_esModuleInterop_flag_and_using_a_default_import_2596": + return X_0_can_only_be_imported_by_turning_on_the_esModuleInterop_flag_and_using_a_default_import + case "_0_can_only_be_imported_by_using_a_require_call_or_by_using_a_default_import_2597": + return X_0_can_only_be_imported_by_using_a_require_call_or_by_using_a_default_import + case "_0_can_only_be_imported_by_using_a_require_call_or_by_turning_on_the_esModuleInterop_flag_and_using__2598": + return X_0_can_only_be_imported_by_using_a_require_call_or_by_turning_on_the_esModuleInterop_flag_and_using_a_default_import + case "JSX_element_implicitly_has_type_any_because_the_global_type_JSX_Element_does_not_exist_2602": + return JSX_element_implicitly_has_type_any_because_the_global_type_JSX_Element_does_not_exist + case "Property_0_in_type_1_is_not_assignable_to_type_2_2603": + return Property_0_in_type_1_is_not_assignable_to_type_2 + case "JSX_element_type_0_does_not_have_any_construct_or_call_signatures_2604": + return JSX_element_type_0_does_not_have_any_construct_or_call_signatures + case "Property_0_of_JSX_spread_attribute_is_not_assignable_to_target_property_2606": + return Property_0_of_JSX_spread_attribute_is_not_assignable_to_target_property + case "JSX_element_class_does_not_support_attributes_because_it_does_not_have_a_0_property_2607": + return JSX_element_class_does_not_support_attributes_because_it_does_not_have_a_0_property + case "The_global_type_JSX_0_may_not_have_more_than_one_property_2608": + return The_global_type_JSX_0_may_not_have_more_than_one_property + case "JSX_spread_child_must_be_an_array_type_2609": + return JSX_spread_child_must_be_an_array_type + case "_0_is_defined_as_an_accessor_in_class_1_but_is_overridden_here_in_2_as_an_instance_property_2610": + return X_0_is_defined_as_an_accessor_in_class_1_but_is_overridden_here_in_2_as_an_instance_property + case "_0_is_defined_as_a_property_in_class_1_but_is_overridden_here_in_2_as_an_accessor_2611": + return X_0_is_defined_as_a_property_in_class_1_but_is_overridden_here_in_2_as_an_accessor + case "Property_0_will_overwrite_the_base_property_in_1_If_this_is_intentional_add_an_initializer_Otherwise_2612": + return Property_0_will_overwrite_the_base_property_in_1_If_this_is_intentional_add_an_initializer_Otherwise_add_a_declare_modifier_or_remove_the_redundant_declaration + case "Module_0_has_no_default_export_Did_you_mean_to_use_import_1_from_0_instead_2613": + return Module_0_has_no_default_export_Did_you_mean_to_use_import_1_from_0_instead + case "Module_0_has_no_exported_member_1_Did_you_mean_to_use_import_1_from_0_instead_2614": + return Module_0_has_no_exported_member_1_Did_you_mean_to_use_import_1_from_0_instead + case "Type_of_property_0_circularly_references_itself_in_mapped_type_1_2615": + return Type_of_property_0_circularly_references_itself_in_mapped_type_1 + case "_0_can_only_be_imported_by_using_import_1_require_2_or_a_default_import_2616": + return X_0_can_only_be_imported_by_using_import_1_require_2_or_a_default_import + case "_0_can_only_be_imported_by_using_import_1_require_2_or_by_turning_on_the_esModuleInterop_flag_and_us_2617": + return X_0_can_only_be_imported_by_using_import_1_require_2_or_by_turning_on_the_esModuleInterop_flag_and_using_a_default_import + case "Source_has_0_element_s_but_target_requires_1_2618": + return Source_has_0_element_s_but_target_requires_1 + case "Source_has_0_element_s_but_target_allows_only_1_2619": + return Source_has_0_element_s_but_target_allows_only_1 + case "Target_requires_0_element_s_but_source_may_have_fewer_2620": + return Target_requires_0_element_s_but_source_may_have_fewer + case "Target_allows_only_0_element_s_but_source_may_have_more_2621": + return Target_allows_only_0_element_s_but_source_may_have_more + case "Source_provides_no_match_for_required_element_at_position_0_in_target_2623": + return Source_provides_no_match_for_required_element_at_position_0_in_target + case "Source_provides_no_match_for_variadic_element_at_position_0_in_target_2624": + return Source_provides_no_match_for_variadic_element_at_position_0_in_target + case "Variadic_element_at_position_0_in_source_does_not_match_element_at_position_1_in_target_2625": + return Variadic_element_at_position_0_in_source_does_not_match_element_at_position_1_in_target + case "Type_at_position_0_in_source_is_not_compatible_with_type_at_position_1_in_target_2626": + return Type_at_position_0_in_source_is_not_compatible_with_type_at_position_1_in_target + case "Type_at_positions_0_through_1_in_source_is_not_compatible_with_type_at_position_2_in_target_2627": + return Type_at_positions_0_through_1_in_source_is_not_compatible_with_type_at_position_2_in_target + case "Cannot_assign_to_0_because_it_is_an_enum_2628": + return Cannot_assign_to_0_because_it_is_an_enum + case "Cannot_assign_to_0_because_it_is_a_class_2629": + return Cannot_assign_to_0_because_it_is_a_class + case "Cannot_assign_to_0_because_it_is_a_function_2630": + return Cannot_assign_to_0_because_it_is_a_function + case "Cannot_assign_to_0_because_it_is_a_namespace_2631": + return Cannot_assign_to_0_because_it_is_a_namespace + case "Cannot_assign_to_0_because_it_is_an_import_2632": + return Cannot_assign_to_0_because_it_is_an_import + case "JSX_property_access_expressions_cannot_include_JSX_namespace_names_2633": + return JSX_property_access_expressions_cannot_include_JSX_namespace_names + case "_0_index_signatures_are_incompatible_2634": + return X_0_index_signatures_are_incompatible + case "Type_0_has_no_signatures_for_which_the_type_argument_list_is_applicable_2635": + return Type_0_has_no_signatures_for_which_the_type_argument_list_is_applicable + case "Type_0_is_not_assignable_to_type_1_as_implied_by_variance_annotation_2636": + return Type_0_is_not_assignable_to_type_1_as_implied_by_variance_annotation + case "Variance_annotations_are_only_supported_in_type_aliases_for_object_function_constructor_and_mapped_t_2637": + return Variance_annotations_are_only_supported_in_type_aliases_for_object_function_constructor_and_mapped_types + case "Type_0_may_represent_a_primitive_value_which_is_not_permitted_as_the_right_operand_of_the_in_operato_2638": + return Type_0_may_represent_a_primitive_value_which_is_not_permitted_as_the_right_operand_of_the_in_operator + case "React_components_cannot_include_JSX_namespace_names_2639": + return React_components_cannot_include_JSX_namespace_names + case "Cannot_augment_module_0_with_value_exports_because_it_resolves_to_a_non_module_entity_2649": + return Cannot_augment_module_0_with_value_exports_because_it_resolves_to_a_non_module_entity + case "Non_abstract_class_expression_is_missing_implementations_for_the_following_members_of_0_Colon_1_and__2650": + return Non_abstract_class_expression_is_missing_implementations_for_the_following_members_of_0_Colon_1_and_2_more + case "A_member_initializer_in_a_enum_declaration_cannot_reference_members_declared_after_it_including_memb_2651": + return A_member_initializer_in_a_enum_declaration_cannot_reference_members_declared_after_it_including_members_defined_in_other_enums + case "Merged_declaration_0_cannot_include_a_default_export_declaration_Consider_adding_a_separate_export_d_2652": + return Merged_declaration_0_cannot_include_a_default_export_declaration_Consider_adding_a_separate_export_default_0_declaration_instead + case "Non_abstract_class_expression_does_not_implement_inherited_abstract_member_0_from_class_1_2653": + return Non_abstract_class_expression_does_not_implement_inherited_abstract_member_0_from_class_1 + case "Non_abstract_class_0_is_missing_implementations_for_the_following_members_of_1_Colon_2_2654": + return Non_abstract_class_0_is_missing_implementations_for_the_following_members_of_1_Colon_2 + case "Non_abstract_class_0_is_missing_implementations_for_the_following_members_of_1_Colon_2_and_3_more_2655": + return Non_abstract_class_0_is_missing_implementations_for_the_following_members_of_1_Colon_2_and_3_more + case "Non_abstract_class_expression_is_missing_implementations_for_the_following_members_of_0_Colon_1_2656": + return Non_abstract_class_expression_is_missing_implementations_for_the_following_members_of_0_Colon_1 + case "JSX_expressions_must_have_one_parent_element_2657": + return JSX_expressions_must_have_one_parent_element + case "Type_0_provides_no_match_for_the_signature_1_2658": + return Type_0_provides_no_match_for_the_signature_1 + case "super_is_only_allowed_in_members_of_object_literal_expressions_when_option_target_is_ES2015_or_highe_2659": + return X_super_is_only_allowed_in_members_of_object_literal_expressions_when_option_target_is_ES2015_or_higher + case "super_can_only_be_referenced_in_members_of_derived_classes_or_object_literal_expressions_2660": + return X_super_can_only_be_referenced_in_members_of_derived_classes_or_object_literal_expressions + case "Cannot_export_0_Only_local_declarations_can_be_exported_from_a_module_2661": + return Cannot_export_0_Only_local_declarations_can_be_exported_from_a_module + case "Cannot_find_name_0_Did_you_mean_the_static_member_1_0_2662": + return Cannot_find_name_0_Did_you_mean_the_static_member_1_0 + case "Cannot_find_name_0_Did_you_mean_the_instance_member_this_0_2663": + return Cannot_find_name_0_Did_you_mean_the_instance_member_this_0 + case "Invalid_module_name_in_augmentation_module_0_cannot_be_found_2664": + return Invalid_module_name_in_augmentation_module_0_cannot_be_found + case "Invalid_module_name_in_augmentation_Module_0_resolves_to_an_untyped_module_at_1_which_cannot_be_augm_2665": + return Invalid_module_name_in_augmentation_Module_0_resolves_to_an_untyped_module_at_1_which_cannot_be_augmented + case "Exports_and_export_assignments_are_not_permitted_in_module_augmentations_2666": + return Exports_and_export_assignments_are_not_permitted_in_module_augmentations + case "Imports_are_not_permitted_in_module_augmentations_Consider_moving_them_to_the_enclosing_external_mod_2667": + return Imports_are_not_permitted_in_module_augmentations_Consider_moving_them_to_the_enclosing_external_module + case "export_modifier_cannot_be_applied_to_ambient_modules_and_module_augmentations_since_they_are_always__2668": + return X_export_modifier_cannot_be_applied_to_ambient_modules_and_module_augmentations_since_they_are_always_visible + case "Augmentations_for_the_global_scope_can_only_be_directly_nested_in_external_modules_or_ambient_module_2669": + return Augmentations_for_the_global_scope_can_only_be_directly_nested_in_external_modules_or_ambient_module_declarations + case "Augmentations_for_the_global_scope_should_have_declare_modifier_unless_they_appear_in_already_ambien_2670": + return Augmentations_for_the_global_scope_should_have_declare_modifier_unless_they_appear_in_already_ambient_context + case "Cannot_augment_module_0_because_it_resolves_to_a_non_module_entity_2671": + return Cannot_augment_module_0_because_it_resolves_to_a_non_module_entity + case "Cannot_assign_a_0_constructor_type_to_a_1_constructor_type_2672": + return Cannot_assign_a_0_constructor_type_to_a_1_constructor_type + case "Constructor_of_class_0_is_private_and_only_accessible_within_the_class_declaration_2673": + return Constructor_of_class_0_is_private_and_only_accessible_within_the_class_declaration + case "Constructor_of_class_0_is_protected_and_only_accessible_within_the_class_declaration_2674": + return Constructor_of_class_0_is_protected_and_only_accessible_within_the_class_declaration + case "Cannot_extend_a_class_0_Class_constructor_is_marked_as_private_2675": + return Cannot_extend_a_class_0_Class_constructor_is_marked_as_private + case "Accessors_must_both_be_abstract_or_non_abstract_2676": + return Accessors_must_both_be_abstract_or_non_abstract + case "A_type_predicate_s_type_must_be_assignable_to_its_parameter_s_type_2677": + return A_type_predicate_s_type_must_be_assignable_to_its_parameter_s_type + case "Type_0_is_not_comparable_to_type_1_2678": + return Type_0_is_not_comparable_to_type_1 + case "A_function_that_is_called_with_the_new_keyword_cannot_have_a_this_type_that_is_void_2679": + return A_function_that_is_called_with_the_new_keyword_cannot_have_a_this_type_that_is_void + case "A_0_parameter_must_be_the_first_parameter_2680": + return A_0_parameter_must_be_the_first_parameter + case "A_constructor_cannot_have_a_this_parameter_2681": + return A_constructor_cannot_have_a_this_parameter + case "this_implicitly_has_type_any_because_it_does_not_have_a_type_annotation_2683": + return X_this_implicitly_has_type_any_because_it_does_not_have_a_type_annotation + case "The_this_context_of_type_0_is_not_assignable_to_method_s_this_of_type_1_2684": + return The_this_context_of_type_0_is_not_assignable_to_method_s_this_of_type_1 + case "The_this_types_of_each_signature_are_incompatible_2685": + return The_this_types_of_each_signature_are_incompatible + case "_0_refers_to_a_UMD_global_but_the_current_file_is_a_module_Consider_adding_an_import_instead_2686": + return X_0_refers_to_a_UMD_global_but_the_current_file_is_a_module_Consider_adding_an_import_instead + case "All_declarations_of_0_must_have_identical_modifiers_2687": + return All_declarations_of_0_must_have_identical_modifiers + case "Cannot_find_type_definition_file_for_0_2688": + return Cannot_find_type_definition_file_for_0 + case "Cannot_extend_an_interface_0_Did_you_mean_implements_2689": + return Cannot_extend_an_interface_0_Did_you_mean_implements + case "_0_only_refers_to_a_type_but_is_being_used_as_a_value_here_Did_you_mean_to_use_1_in_0_2690": + return X_0_only_refers_to_a_type_but_is_being_used_as_a_value_here_Did_you_mean_to_use_1_in_0 + case "_0_is_a_primitive_but_1_is_a_wrapper_object_Prefer_using_0_when_possible_2692": + return X_0_is_a_primitive_but_1_is_a_wrapper_object_Prefer_using_0_when_possible + case "_0_only_refers_to_a_type_but_is_being_used_as_a_value_here_2693": + return X_0_only_refers_to_a_type_but_is_being_used_as_a_value_here + case "Namespace_0_has_no_exported_member_1_2694": + return Namespace_0_has_no_exported_member_1 + case "Left_side_of_comma_operator_is_unused_and_has_no_side_effects_2695": + return Left_side_of_comma_operator_is_unused_and_has_no_side_effects + case "The_Object_type_is_assignable_to_very_few_other_types_Did_you_mean_to_use_the_any_type_instead_2696": + return The_Object_type_is_assignable_to_very_few_other_types_Did_you_mean_to_use_the_any_type_instead + case "An_async_function_or_method_must_return_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_in_2697": + return An_async_function_or_method_must_return_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_include_ES2015_in_your_lib_option + case "Spread_types_may_only_be_created_from_object_types_2698": + return Spread_types_may_only_be_created_from_object_types + case "Static_property_0_conflicts_with_built_in_property_Function_0_of_constructor_function_1_2699": + return Static_property_0_conflicts_with_built_in_property_Function_0_of_constructor_function_1 + case "Rest_types_may_only_be_created_from_object_types_2700": + return Rest_types_may_only_be_created_from_object_types + case "The_target_of_an_object_rest_assignment_must_be_a_variable_or_a_property_access_2701": + return The_target_of_an_object_rest_assignment_must_be_a_variable_or_a_property_access + case "_0_only_refers_to_a_type_but_is_being_used_as_a_namespace_here_2702": + return X_0_only_refers_to_a_type_but_is_being_used_as_a_namespace_here + case "The_operand_of_a_delete_operator_must_be_a_property_reference_2703": + return The_operand_of_a_delete_operator_must_be_a_property_reference + case "The_operand_of_a_delete_operator_cannot_be_a_read_only_property_2704": + return The_operand_of_a_delete_operator_cannot_be_a_read_only_property + case "An_async_function_or_method_in_ES5_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_2705": + return An_async_function_or_method_in_ES5_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_the_Promise_constructor_or_include_ES2015_in_your_lib_option + case "Required_type_parameters_may_not_follow_optional_type_parameters_2706": + return Required_type_parameters_may_not_follow_optional_type_parameters + case "Generic_type_0_requires_between_1_and_2_type_arguments_2707": + return Generic_type_0_requires_between_1_and_2_type_arguments + case "Cannot_use_namespace_0_as_a_value_2708": + return Cannot_use_namespace_0_as_a_value + case "Cannot_use_namespace_0_as_a_type_2709": + return Cannot_use_namespace_0_as_a_type + case "_0_are_specified_twice_The_attribute_named_0_will_be_overwritten_2710": + return X_0_are_specified_twice_The_attribute_named_0_will_be_overwritten + case "A_dynamic_import_call_returns_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_include_ES20_2711": + return A_dynamic_import_call_returns_a_Promise_Make_sure_you_have_a_declaration_for_Promise_or_include_ES2015_in_your_lib_option + case "A_dynamic_import_call_in_ES5_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_t_2712": + return A_dynamic_import_call_in_ES5_requires_the_Promise_constructor_Make_sure_you_have_a_declaration_for_the_Promise_constructor_or_include_ES2015_in_your_lib_option + case "Cannot_access_0_1_because_0_is_a_type_but_not_a_namespace_Did_you_mean_to_retrieve_the_type_of_the_p_2713": + return Cannot_access_0_1_because_0_is_a_type_but_not_a_namespace_Did_you_mean_to_retrieve_the_type_of_the_property_1_in_0_with_0_1 + case "The_expression_of_an_export_assignment_must_be_an_identifier_or_qualified_name_in_an_ambient_context_2714": + return The_expression_of_an_export_assignment_must_be_an_identifier_or_qualified_name_in_an_ambient_context + case "Abstract_property_0_in_class_1_cannot_be_accessed_in_the_constructor_2715": + return Abstract_property_0_in_class_1_cannot_be_accessed_in_the_constructor + case "Type_parameter_0_has_a_circular_default_2716": + return Type_parameter_0_has_a_circular_default + case "Subsequent_property_declarations_must_have_the_same_type_Property_0_must_be_of_type_1_but_here_has_t_2717": + return Subsequent_property_declarations_must_have_the_same_type_Property_0_must_be_of_type_1_but_here_has_type_2 + case "Duplicate_property_0_2718": + return Duplicate_property_0 + case "Type_0_is_not_assignable_to_type_1_Two_different_types_with_this_name_exist_but_they_are_unrelated_2719": + return Type_0_is_not_assignable_to_type_1_Two_different_types_with_this_name_exist_but_they_are_unrelated + case "Class_0_incorrectly_implements_class_1_Did_you_mean_to_extend_1_and_inherit_its_members_as_a_subclas_2720": + return Class_0_incorrectly_implements_class_1_Did_you_mean_to_extend_1_and_inherit_its_members_as_a_subclass + case "Cannot_invoke_an_object_which_is_possibly_null_2721": + return Cannot_invoke_an_object_which_is_possibly_null + case "Cannot_invoke_an_object_which_is_possibly_undefined_2722": + return Cannot_invoke_an_object_which_is_possibly_undefined + case "Cannot_invoke_an_object_which_is_possibly_null_or_undefined_2723": + return Cannot_invoke_an_object_which_is_possibly_null_or_undefined + case "_0_has_no_exported_member_named_1_Did_you_mean_2_2724": + return X_0_has_no_exported_member_named_1_Did_you_mean_2 + case "Class_name_cannot_be_Object_when_targeting_ES5_and_above_with_module_0_2725": + return Class_name_cannot_be_Object_when_targeting_ES5_and_above_with_module_0 + case "Cannot_find_lib_definition_for_0_2726": + return Cannot_find_lib_definition_for_0 + case "Cannot_find_lib_definition_for_0_Did_you_mean_1_2727": + return Cannot_find_lib_definition_for_0_Did_you_mean_1 + case "_0_is_declared_here_2728": + return X_0_is_declared_here + case "Property_0_is_used_before_its_initialization_2729": + return Property_0_is_used_before_its_initialization + case "An_arrow_function_cannot_have_a_this_parameter_2730": + return An_arrow_function_cannot_have_a_this_parameter + case "Implicit_conversion_of_a_symbol_to_a_string_will_fail_at_runtime_Consider_wrapping_this_expression_i_2731": + return Implicit_conversion_of_a_symbol_to_a_string_will_fail_at_runtime_Consider_wrapping_this_expression_in_String + case "Cannot_find_module_0_Consider_using_resolveJsonModule_to_import_module_with_json_extension_2732": + return Cannot_find_module_0_Consider_using_resolveJsonModule_to_import_module_with_json_extension + case "Property_0_was_also_declared_here_2733": + return Property_0_was_also_declared_here + case "Are_you_missing_a_semicolon_2734": + return Are_you_missing_a_semicolon + case "Did_you_mean_for_0_to_be_constrained_to_type_new_args_Colon_any_1_2735": + return Did_you_mean_for_0_to_be_constrained_to_type_new_args_Colon_any_1 + case "Operator_0_cannot_be_applied_to_type_1_2736": + return Operator_0_cannot_be_applied_to_type_1 + case "BigInt_literals_are_not_available_when_targeting_lower_than_ES2020_2737": + return BigInt_literals_are_not_available_when_targeting_lower_than_ES2020 + case "An_outer_value_of_this_is_shadowed_by_this_container_2738": + return An_outer_value_of_this_is_shadowed_by_this_container + case "Type_0_is_missing_the_following_properties_from_type_1_Colon_2_2739": + return Type_0_is_missing_the_following_properties_from_type_1_Colon_2 + case "Type_0_is_missing_the_following_properties_from_type_1_Colon_2_and_3_more_2740": + return Type_0_is_missing_the_following_properties_from_type_1_Colon_2_and_3_more + case "Property_0_is_missing_in_type_1_but_required_in_type_2_2741": + return Property_0_is_missing_in_type_1_but_required_in_type_2 + case "The_inferred_type_of_0_cannot_be_named_without_a_reference_to_1_This_is_likely_not_portable_A_type_a_2742": + return The_inferred_type_of_0_cannot_be_named_without_a_reference_to_1_This_is_likely_not_portable_A_type_annotation_is_necessary + case "No_overload_expects_0_type_arguments_but_overloads_do_exist_that_expect_either_1_or_2_type_arguments_2743": + return No_overload_expects_0_type_arguments_but_overloads_do_exist_that_expect_either_1_or_2_type_arguments + case "Type_parameter_defaults_can_only_reference_previously_declared_type_parameters_2744": + return Type_parameter_defaults_can_only_reference_previously_declared_type_parameters + case "This_JSX_tag_s_0_prop_expects_type_1_which_requires_multiple_children_but_only_a_single_child_was_pr_2745": + return This_JSX_tag_s_0_prop_expects_type_1_which_requires_multiple_children_but_only_a_single_child_was_provided + case "This_JSX_tag_s_0_prop_expects_a_single_child_of_type_1_but_multiple_children_were_provided_2746": + return This_JSX_tag_s_0_prop_expects_a_single_child_of_type_1_but_multiple_children_were_provided + case "_0_components_don_t_accept_text_as_child_elements_Text_in_JSX_has_the_type_string_but_the_expected_t_2747": + return X_0_components_don_t_accept_text_as_child_elements_Text_in_JSX_has_the_type_string_but_the_expected_type_of_1_is_2 + case "Cannot_access_ambient_const_enums_when_0_is_enabled_2748": + return Cannot_access_ambient_const_enums_when_0_is_enabled + case "_0_refers_to_a_value_but_is_being_used_as_a_type_here_Did_you_mean_typeof_0_2749": + return X_0_refers_to_a_value_but_is_being_used_as_a_type_here_Did_you_mean_typeof_0 + case "The_implementation_signature_is_declared_here_2750": + return The_implementation_signature_is_declared_here + case "Circularity_originates_in_type_at_this_location_2751": + return Circularity_originates_in_type_at_this_location + case "The_first_export_default_is_here_2752": + return The_first_export_default_is_here + case "Another_export_default_is_here_2753": + return Another_export_default_is_here + case "super_may_not_use_type_arguments_2754": + return X_super_may_not_use_type_arguments + case "No_constituent_of_type_0_is_callable_2755": + return No_constituent_of_type_0_is_callable + case "Not_all_constituents_of_type_0_are_callable_2756": + return Not_all_constituents_of_type_0_are_callable + case "Type_0_has_no_call_signatures_2757": + return Type_0_has_no_call_signatures + case "Each_member_of_the_union_type_0_has_signatures_but_none_of_those_signatures_are_compatible_with_each_2758": + return Each_member_of_the_union_type_0_has_signatures_but_none_of_those_signatures_are_compatible_with_each_other + case "No_constituent_of_type_0_is_constructable_2759": + return No_constituent_of_type_0_is_constructable + case "Not_all_constituents_of_type_0_are_constructable_2760": + return Not_all_constituents_of_type_0_are_constructable + case "Type_0_has_no_construct_signatures_2761": + return Type_0_has_no_construct_signatures + case "Each_member_of_the_union_type_0_has_construct_signatures_but_none_of_those_signatures_are_compatible_2762": + return Each_member_of_the_union_type_0_has_construct_signatures_but_none_of_those_signatures_are_compatible_with_each_other + case "Cannot_iterate_value_because_the_next_method_of_its_iterator_expects_type_1_but_for_of_will_always_s_2763": + return Cannot_iterate_value_because_the_next_method_of_its_iterator_expects_type_1_but_for_of_will_always_send_0 + case "Cannot_iterate_value_because_the_next_method_of_its_iterator_expects_type_1_but_array_spread_will_al_2764": + return Cannot_iterate_value_because_the_next_method_of_its_iterator_expects_type_1_but_array_spread_will_always_send_0 + case "Cannot_iterate_value_because_the_next_method_of_its_iterator_expects_type_1_but_array_destructuring__2765": + return Cannot_iterate_value_because_the_next_method_of_its_iterator_expects_type_1_but_array_destructuring_will_always_send_0 + case "Cannot_delegate_iteration_to_value_because_the_next_method_of_its_iterator_expects_type_1_but_the_co_2766": + return Cannot_delegate_iteration_to_value_because_the_next_method_of_its_iterator_expects_type_1_but_the_containing_generator_will_always_send_0 + case "The_0_property_of_an_iterator_must_be_a_method_2767": + return The_0_property_of_an_iterator_must_be_a_method + case "The_0_property_of_an_async_iterator_must_be_a_method_2768": + return The_0_property_of_an_async_iterator_must_be_a_method + case "No_overload_matches_this_call_2769": + return No_overload_matches_this_call + case "The_last_overload_gave_the_following_error_2770": + return The_last_overload_gave_the_following_error + case "The_last_overload_is_declared_here_2771": + return The_last_overload_is_declared_here + case "Overload_0_of_1_2_gave_the_following_error_2772": + return Overload_0_of_1_2_gave_the_following_error + case "Did_you_forget_to_use_await_2773": + return Did_you_forget_to_use_await + case "This_condition_will_always_return_true_since_this_function_is_always_defined_Did_you_mean_to_call_it_2774": + return This_condition_will_always_return_true_since_this_function_is_always_defined_Did_you_mean_to_call_it_instead + case "Assertions_require_every_name_in_the_call_target_to_be_declared_with_an_explicit_type_annotation_2775": + return Assertions_require_every_name_in_the_call_target_to_be_declared_with_an_explicit_type_annotation + case "Assertions_require_the_call_target_to_be_an_identifier_or_qualified_name_2776": + return Assertions_require_the_call_target_to_be_an_identifier_or_qualified_name + case "The_operand_of_an_increment_or_decrement_operator_may_not_be_an_optional_property_access_2777": + return The_operand_of_an_increment_or_decrement_operator_may_not_be_an_optional_property_access + case "The_target_of_an_object_rest_assignment_may_not_be_an_optional_property_access_2778": + return The_target_of_an_object_rest_assignment_may_not_be_an_optional_property_access + case "The_left_hand_side_of_an_assignment_expression_may_not_be_an_optional_property_access_2779": + return The_left_hand_side_of_an_assignment_expression_may_not_be_an_optional_property_access + case "The_left_hand_side_of_a_for_in_statement_may_not_be_an_optional_property_access_2780": + return The_left_hand_side_of_a_for_in_statement_may_not_be_an_optional_property_access + case "The_left_hand_side_of_a_for_of_statement_may_not_be_an_optional_property_access_2781": + return The_left_hand_side_of_a_for_of_statement_may_not_be_an_optional_property_access + case "_0_needs_an_explicit_type_annotation_2782": + return X_0_needs_an_explicit_type_annotation + case "_0_is_specified_more_than_once_so_this_usage_will_be_overwritten_2783": + return X_0_is_specified_more_than_once_so_this_usage_will_be_overwritten + case "get_and_set_accessors_cannot_declare_this_parameters_2784": + return X_get_and_set_accessors_cannot_declare_this_parameters + case "This_spread_always_overwrites_this_property_2785": + return This_spread_always_overwrites_this_property + case "_0_cannot_be_used_as_a_JSX_component_2786": + return X_0_cannot_be_used_as_a_JSX_component + case "Its_return_type_0_is_not_a_valid_JSX_element_2787": + return Its_return_type_0_is_not_a_valid_JSX_element + case "Its_instance_type_0_is_not_a_valid_JSX_element_2788": + return Its_instance_type_0_is_not_a_valid_JSX_element + case "Its_element_type_0_is_not_a_valid_JSX_element_2789": + return Its_element_type_0_is_not_a_valid_JSX_element + case "The_operand_of_a_delete_operator_must_be_optional_2790": + return The_operand_of_a_delete_operator_must_be_optional + case "Exponentiation_cannot_be_performed_on_bigint_values_unless_the_target_option_is_set_to_es2016_or_lat_2791": + return Exponentiation_cannot_be_performed_on_bigint_values_unless_the_target_option_is_set_to_es2016_or_later + case "Cannot_find_module_0_Did_you_mean_to_set_the_moduleResolution_option_to_nodenext_or_to_add_aliases_t_2792": + return Cannot_find_module_0_Did_you_mean_to_set_the_moduleResolution_option_to_nodenext_or_to_add_aliases_to_the_paths_option + case "The_call_would_have_succeeded_against_this_implementation_but_implementation_signatures_of_overloads_2793": + return The_call_would_have_succeeded_against_this_implementation_but_implementation_signatures_of_overloads_are_not_externally_visible + case "Expected_0_arguments_but_got_1_Did_you_forget_to_include_void_in_your_type_argument_to_Promise_2794": + return Expected_0_arguments_but_got_1_Did_you_forget_to_include_void_in_your_type_argument_to_Promise + case "The_intrinsic_keyword_can_only_be_used_to_declare_compiler_provided_intrinsic_types_2795": + return The_intrinsic_keyword_can_only_be_used_to_declare_compiler_provided_intrinsic_types + case "It_is_likely_that_you_are_missing_a_comma_to_separate_these_two_template_expressions_They_form_a_tag_2796": + return It_is_likely_that_you_are_missing_a_comma_to_separate_these_two_template_expressions_They_form_a_tagged_template_expression_which_cannot_be_invoked + case "A_mixin_class_that_extends_from_a_type_variable_containing_an_abstract_construct_signature_must_also_2797": + return A_mixin_class_that_extends_from_a_type_variable_containing_an_abstract_construct_signature_must_also_be_declared_abstract + case "The_declaration_was_marked_as_deprecated_here_2798": + return The_declaration_was_marked_as_deprecated_here + case "Type_produces_a_tuple_type_that_is_too_large_to_represent_2799": + return Type_produces_a_tuple_type_that_is_too_large_to_represent + case "Expression_produces_a_tuple_type_that_is_too_large_to_represent_2800": + return Expression_produces_a_tuple_type_that_is_too_large_to_represent + case "This_condition_will_always_return_true_since_this_0_is_always_defined_2801": + return This_condition_will_always_return_true_since_this_0_is_always_defined + case "Type_0_can_only_be_iterated_through_when_using_the_downlevelIteration_flag_or_with_a_target_of_es201_2802": + return Type_0_can_only_be_iterated_through_when_using_the_downlevelIteration_flag_or_with_a_target_of_es2015_or_higher + case "Cannot_assign_to_private_method_0_Private_methods_are_not_writable_2803": + return Cannot_assign_to_private_method_0_Private_methods_are_not_writable + case "Duplicate_identifier_0_Static_and_instance_elements_cannot_share_the_same_private_name_2804": + return Duplicate_identifier_0_Static_and_instance_elements_cannot_share_the_same_private_name + case "Private_accessor_was_defined_without_a_getter_2806": + return Private_accessor_was_defined_without_a_getter + case "This_syntax_requires_an_imported_helper_named_1_with_2_parameters_which_is_not_compatible_with_the_o_2807": + return This_syntax_requires_an_imported_helper_named_1_with_2_parameters_which_is_not_compatible_with_the_one_in_0_Consider_upgrading_your_version_of_0 + case "A_get_accessor_must_be_at_least_as_accessible_as_the_setter_2808": + return A_get_accessor_must_be_at_least_as_accessible_as_the_setter + case "Declaration_or_statement_expected_This_follows_a_block_of_statements_so_if_you_intended_to_write_a_d_2809": + return Declaration_or_statement_expected_This_follows_a_block_of_statements_so_if_you_intended_to_write_a_destructuring_assignment_you_might_need_to_wrap_the_whole_assignment_in_parentheses + case "Expected_1_argument_but_got_0_new_Promise_needs_a_JSDoc_hint_to_produce_a_resolve_that_can_be_called_2810": + return Expected_1_argument_but_got_0_new_Promise_needs_a_JSDoc_hint_to_produce_a_resolve_that_can_be_called_without_arguments + case "Initializer_for_property_0_2811": + return Initializer_for_property_0 + case "Property_0_does_not_exist_on_type_1_Try_changing_the_lib_compiler_option_to_include_dom_2812": + return Property_0_does_not_exist_on_type_1_Try_changing_the_lib_compiler_option_to_include_dom + case "Class_declaration_cannot_implement_overload_list_for_0_2813": + return Class_declaration_cannot_implement_overload_list_for_0 + case "Function_with_bodies_can_only_merge_with_classes_that_are_ambient_2814": + return Function_with_bodies_can_only_merge_with_classes_that_are_ambient + case "arguments_cannot_be_referenced_in_property_initializers_or_class_static_initialization_blocks_2815": + return X_arguments_cannot_be_referenced_in_property_initializers_or_class_static_initialization_blocks + case "Cannot_use_this_in_a_static_property_initializer_of_a_decorated_class_2816": + return Cannot_use_this_in_a_static_property_initializer_of_a_decorated_class + case "Property_0_has_no_initializer_and_is_not_definitely_assigned_in_a_class_static_block_2817": + return Property_0_has_no_initializer_and_is_not_definitely_assigned_in_a_class_static_block + case "Duplicate_identifier_0_Compiler_reserves_name_1_when_emitting_super_references_in_static_initializer_2818": + return Duplicate_identifier_0_Compiler_reserves_name_1_when_emitting_super_references_in_static_initializers + case "Namespace_name_cannot_be_0_2819": + return Namespace_name_cannot_be_0 + case "Type_0_is_not_assignable_to_type_1_Did_you_mean_2_2820": + return Type_0_is_not_assignable_to_type_1_Did_you_mean_2 + case "Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_node18_node20_nodenext__2821": + return Import_assertions_are_only_supported_when_the_module_option_is_set_to_esnext_node18_node20_nodenext_or_preserve + case "Import_assertions_cannot_be_used_with_type_only_imports_or_exports_2822": + return Import_assertions_cannot_be_used_with_type_only_imports_or_exports + case "Import_attributes_are_only_supported_when_the_module_option_is_set_to_esnext_node18_node20_nodenext__2823": + return Import_attributes_are_only_supported_when_the_module_option_is_set_to_esnext_node18_node20_nodenext_or_preserve + case "Cannot_find_namespace_0_Did_you_mean_1_2833": + return Cannot_find_namespace_0_Did_you_mean_1 + case "Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_n_2834": + return Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_node16_or_nodenext_Consider_adding_an_extension_to_the_import_path + case "Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_n_2835": + return Relative_import_paths_need_explicit_file_extensions_in_ECMAScript_imports_when_moduleResolution_is_node16_or_nodenext_Did_you_mean_0 + case "Import_assertions_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls_2836": + return Import_assertions_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls + case "Import_assertion_values_must_be_string_literal_expressions_2837": + return Import_assertion_values_must_be_string_literal_expressions + case "All_declarations_of_0_must_have_identical_constraints_2838": + return All_declarations_of_0_must_have_identical_constraints + case "This_condition_will_always_return_0_since_JavaScript_compares_objects_by_reference_not_value_2839": + return This_condition_will_always_return_0_since_JavaScript_compares_objects_by_reference_not_value + case "An_interface_cannot_extend_a_primitive_type_like_0_It_can_only_extend_other_named_object_types_2840": + return An_interface_cannot_extend_a_primitive_type_like_0_It_can_only_extend_other_named_object_types + case "_0_is_an_unused_renaming_of_1_Did_you_intend_to_use_it_as_a_type_annotation_2842": + return X_0_is_an_unused_renaming_of_1_Did_you_intend_to_use_it_as_a_type_annotation + case "We_can_only_write_a_type_for_0_by_adding_a_type_for_the_entire_parameter_here_2843": + return We_can_only_write_a_type_for_0_by_adding_a_type_for_the_entire_parameter_here + case "Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor_2844": + return Type_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor + case "This_condition_will_always_return_0_2845": + return This_condition_will_always_return_0 + case "A_declaration_file_cannot_be_imported_without_import_type_Did_you_mean_to_import_an_implementation_f_2846": + return A_declaration_file_cannot_be_imported_without_import_type_Did_you_mean_to_import_an_implementation_file_0_instead + case "The_right_hand_side_of_an_instanceof_expression_must_not_be_an_instantiation_expression_2848": + return The_right_hand_side_of_an_instanceof_expression_must_not_be_an_instantiation_expression + case "Target_signature_provides_too_few_arguments_Expected_0_or_more_but_got_1_2849": + return Target_signature_provides_too_few_arguments_Expected_0_or_more_but_got_1 + case "The_initializer_of_a_using_declaration_must_be_either_an_object_with_a_Symbol_dispose_method_or_be_n_2850": + return The_initializer_of_a_using_declaration_must_be_either_an_object_with_a_Symbol_dispose_method_or_be_null_or_undefined + case "The_initializer_of_an_await_using_declaration_must_be_either_an_object_with_a_Symbol_asyncDispose_or_2851": + return The_initializer_of_an_await_using_declaration_must_be_either_an_object_with_a_Symbol_asyncDispose_or_Symbol_dispose_method_or_be_null_or_undefined + case "await_using_statements_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules_2852": + return X_await_using_statements_are_only_allowed_within_async_functions_and_at_the_top_levels_of_modules + case "await_using_statements_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_th_2853": + return X_await_using_statements_are_only_allowed_at_the_top_level_of_a_file_when_that_file_is_a_module_but_this_file_has_no_imports_or_exports_Consider_adding_an_empty_export_to_make_this_file_a_module + case "Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_sys_2854": + return Top_level_await_using_statements_are_only_allowed_when_the_module_option_is_set_to_es2022_esnext_system_node16_node18_node20_nodenext_or_preserve_and_the_target_option_is_set_to_es2017_or_higher + case "Class_field_0_defined_by_the_parent_class_is_not_accessible_in_the_child_class_via_super_2855": + return Class_field_0_defined_by_the_parent_class_is_not_accessible_in_the_child_class_via_super + case "Import_attributes_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls_2856": + return Import_attributes_are_not_allowed_on_statements_that_compile_to_CommonJS_require_calls + case "Import_attributes_cannot_be_used_with_type_only_imports_or_exports_2857": + return Import_attributes_cannot_be_used_with_type_only_imports_or_exports + case "Import_attribute_values_must_be_string_literal_expressions_2858": + return Import_attribute_values_must_be_string_literal_expressions + case "Excessive_complexity_comparing_types_0_and_1_2859": + return Excessive_complexity_comparing_types_0_and_1 + case "The_left_hand_side_of_an_instanceof_expression_must_be_assignable_to_the_first_argument_of_the_right_2860": + return The_left_hand_side_of_an_instanceof_expression_must_be_assignable_to_the_first_argument_of_the_right_hand_side_s_Symbol_hasInstance_method + case "An_object_s_Symbol_hasInstance_method_must_return_a_boolean_value_for_it_to_be_used_on_the_right_han_2861": + return An_object_s_Symbol_hasInstance_method_must_return_a_boolean_value_for_it_to_be_used_on_the_right_hand_side_of_an_instanceof_expression + case "Type_0_is_generic_and_can_only_be_indexed_for_reading_2862": + return Type_0_is_generic_and_can_only_be_indexed_for_reading + case "A_class_cannot_extend_a_primitive_type_like_0_Classes_can_only_extend_constructable_values_2863": + return A_class_cannot_extend_a_primitive_type_like_0_Classes_can_only_extend_constructable_values + case "A_class_cannot_implement_a_primitive_type_like_0_It_can_only_implement_other_named_object_types_2864": + return A_class_cannot_implement_a_primitive_type_like_0_It_can_only_implement_other_named_object_types + case "Import_0_conflicts_with_local_value_so_must_be_declared_with_a_type_only_import_when_isolatedModules_2865": + return Import_0_conflicts_with_local_value_so_must_be_declared_with_a_type_only_import_when_isolatedModules_is_enabled + case "Import_0_conflicts_with_global_value_used_in_this_file_so_must_be_declared_with_a_type_only_import_w_2866": + return Import_0_conflicts_with_global_value_used_in_this_file_so_must_be_declared_with_a_type_only_import_when_isolatedModules_is_enabled + case "Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_Bun_Try_npm_i_save_dev_types_Slashbun_2867": + return Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_Bun_Try_npm_i_save_dev_types_Slashbun + case "Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_Bun_Try_npm_i_save_dev_types_Slashbun_2868": + return Cannot_find_name_0_Do_you_need_to_install_type_definitions_for_Bun_Try_npm_i_save_dev_types_Slashbun_and_then_add_bun_to_the_types_field_in_your_tsconfig + case "Right_operand_of_is_unreachable_because_the_left_operand_is_never_nullish_2869": + return Right_operand_of_is_unreachable_because_the_left_operand_is_never_nullish + case "This_binary_expression_is_never_nullish_Are_you_missing_parentheses_2870": + return This_binary_expression_is_never_nullish_Are_you_missing_parentheses + case "This_expression_is_always_nullish_2871": + return This_expression_is_always_nullish + case "This_kind_of_expression_is_always_truthy_2872": + return This_kind_of_expression_is_always_truthy + case "This_kind_of_expression_is_always_falsy_2873": + return This_kind_of_expression_is_always_falsy + case "This_JSX_tag_requires_0_to_be_in_scope_but_it_could_not_be_found_2874": + return This_JSX_tag_requires_0_to_be_in_scope_but_it_could_not_be_found + case "This_JSX_tag_requires_the_module_path_0_to_exist_but_none_could_be_found_Make_sure_you_have_types_fo_2875": + return This_JSX_tag_requires_the_module_path_0_to_exist_but_none_could_be_found_Make_sure_you_have_types_for_the_appropriate_package_installed + case "This_relative_import_path_is_unsafe_to_rewrite_because_it_looks_like_a_file_name_but_actually_resolv_2876": + return This_relative_import_path_is_unsafe_to_rewrite_because_it_looks_like_a_file_name_but_actually_resolves_to_0 + case "This_import_uses_a_0_extension_to_resolve_to_an_input_TypeScript_file_but_will_not_be_rewritten_duri_2877": + return This_import_uses_a_0_extension_to_resolve_to_an_input_TypeScript_file_but_will_not_be_rewritten_during_emit_because_it_is_not_a_relative_path + case "This_import_path_is_unsafe_to_rewrite_because_it_resolves_to_another_project_and_the_relative_path_b_2878": + return This_import_path_is_unsafe_to_rewrite_because_it_resolves_to_another_project_and_the_relative_path_between_the_projects_output_files_is_not_the_same_as_the_relative_path_between_its_input_files + case "Using_JSX_fragments_requires_fragment_factory_0_to_be_in_scope_but_it_could_not_be_found_2879": + return Using_JSX_fragments_requires_fragment_factory_0_to_be_in_scope_but_it_could_not_be_found + case "Import_assertions_have_been_replaced_by_import_attributes_Use_with_instead_of_assert_2880": + return Import_assertions_have_been_replaced_by_import_attributes_Use_with_instead_of_assert + case "This_expression_is_never_nullish_2881": + return This_expression_is_never_nullish + case "Import_declaration_0_is_using_private_name_1_4000": + return Import_declaration_0_is_using_private_name_1 + case "Type_parameter_0_of_exported_class_has_or_is_using_private_name_1_4002": + return Type_parameter_0_of_exported_class_has_or_is_using_private_name_1 + case "Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1_4004": + return Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1 + case "Type_parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_1_4006": + return Type_parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_1 + case "Type_parameter_0_of_call_signature_from_exported_interface_has_or_is_using_private_name_1_4008": + return Type_parameter_0_of_call_signature_from_exported_interface_has_or_is_using_private_name_1 + case "Type_parameter_0_of_public_static_method_from_exported_class_has_or_is_using_private_name_1_4010": + return Type_parameter_0_of_public_static_method_from_exported_class_has_or_is_using_private_name_1 + case "Type_parameter_0_of_public_method_from_exported_class_has_or_is_using_private_name_1_4012": + return Type_parameter_0_of_public_method_from_exported_class_has_or_is_using_private_name_1 + case "Type_parameter_0_of_method_from_exported_interface_has_or_is_using_private_name_1_4014": + return Type_parameter_0_of_method_from_exported_interface_has_or_is_using_private_name_1 + case "Type_parameter_0_of_exported_function_has_or_is_using_private_name_1_4016": + return Type_parameter_0_of_exported_function_has_or_is_using_private_name_1 + case "Implements_clause_of_exported_class_0_has_or_is_using_private_name_1_4019": + return Implements_clause_of_exported_class_0_has_or_is_using_private_name_1 + case "extends_clause_of_exported_class_0_has_or_is_using_private_name_1_4020": + return X_extends_clause_of_exported_class_0_has_or_is_using_private_name_1 + case "extends_clause_of_exported_class_has_or_is_using_private_name_0_4021": + return X_extends_clause_of_exported_class_has_or_is_using_private_name_0 + case "extends_clause_of_exported_interface_0_has_or_is_using_private_name_1_4022": + return X_extends_clause_of_exported_interface_0_has_or_is_using_private_name_1 + case "Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023": + return Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Exported_variable_0_has_or_is_using_name_1_from_private_module_2_4024": + return Exported_variable_0_has_or_is_using_name_1_from_private_module_2 + case "Exported_variable_0_has_or_is_using_private_name_1_4025": + return Exported_variable_0_has_or_is_using_private_name_1 + case "Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot__4026": + return Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2_4027": + return Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Public_static_property_0_of_exported_class_has_or_is_using_private_name_1_4028": + return Public_static_property_0_of_exported_class_has_or_is_using_private_name_1 + case "Public_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_name_4029": + return Public_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Public_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2_4030": + return Public_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Public_property_0_of_exported_class_has_or_is_using_private_name_1_4031": + return Public_property_0_of_exported_class_has_or_is_using_private_name_1 + case "Property_0_of_exported_interface_has_or_is_using_name_1_from_private_module_2_4032": + return Property_0_of_exported_interface_has_or_is_using_name_1_from_private_module_2 + case "Property_0_of_exported_interface_has_or_is_using_private_name_1_4033": + return Property_0_of_exported_interface_has_or_is_using_private_name_1 + case "Parameter_type_of_public_static_setter_0_from_exported_class_has_or_is_using_name_1_from_private_mod_4034": + return Parameter_type_of_public_static_setter_0_from_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Parameter_type_of_public_static_setter_0_from_exported_class_has_or_is_using_private_name_1_4035": + return Parameter_type_of_public_static_setter_0_from_exported_class_has_or_is_using_private_name_1 + case "Parameter_type_of_public_setter_0_from_exported_class_has_or_is_using_name_1_from_private_module_2_4036": + return Parameter_type_of_public_setter_0_from_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Parameter_type_of_public_setter_0_from_exported_class_has_or_is_using_private_name_1_4037": + return Parameter_type_of_public_setter_0_from_exported_class_has_or_is_using_private_name_1 + case "Return_type_of_public_static_getter_0_from_exported_class_has_or_is_using_name_1_from_external_modul_4038": + return Return_type_of_public_static_getter_0_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Return_type_of_public_static_getter_0_from_exported_class_has_or_is_using_name_1_from_private_module_4039": + return Return_type_of_public_static_getter_0_from_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Return_type_of_public_static_getter_0_from_exported_class_has_or_is_using_private_name_1_4040": + return Return_type_of_public_static_getter_0_from_exported_class_has_or_is_using_private_name_1 + case "Return_type_of_public_getter_0_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_4041": + return Return_type_of_public_getter_0_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Return_type_of_public_getter_0_from_exported_class_has_or_is_using_name_1_from_private_module_2_4042": + return Return_type_of_public_getter_0_from_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Return_type_of_public_getter_0_from_exported_class_has_or_is_using_private_name_1_4043": + return Return_type_of_public_getter_0_from_exported_class_has_or_is_using_private_name_1 + case "Return_type_of_constructor_signature_from_exported_interface_has_or_is_using_name_0_from_private_mod_4044": + return Return_type_of_constructor_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1 + case "Return_type_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_0_4045": + return Return_type_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_0 + case "Return_type_of_call_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1_4046": + return Return_type_of_call_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1 + case "Return_type_of_call_signature_from_exported_interface_has_or_is_using_private_name_0_4047": + return Return_type_of_call_signature_from_exported_interface_has_or_is_using_private_name_0 + case "Return_type_of_index_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1_4048": + return Return_type_of_index_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1 + case "Return_type_of_index_signature_from_exported_interface_has_or_is_using_private_name_0_4049": + return Return_type_of_index_signature_from_exported_interface_has_or_is_using_private_name_0 + case "Return_type_of_public_static_method_from_exported_class_has_or_is_using_name_0_from_external_module__4050": + return Return_type_of_public_static_method_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named + case "Return_type_of_public_static_method_from_exported_class_has_or_is_using_name_0_from_private_module_1_4051": + return Return_type_of_public_static_method_from_exported_class_has_or_is_using_name_0_from_private_module_1 + case "Return_type_of_public_static_method_from_exported_class_has_or_is_using_private_name_0_4052": + return Return_type_of_public_static_method_from_exported_class_has_or_is_using_private_name_0 + case "Return_type_of_public_method_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_c_4053": + return Return_type_of_public_method_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named + case "Return_type_of_public_method_from_exported_class_has_or_is_using_name_0_from_private_module_1_4054": + return Return_type_of_public_method_from_exported_class_has_or_is_using_name_0_from_private_module_1 + case "Return_type_of_public_method_from_exported_class_has_or_is_using_private_name_0_4055": + return Return_type_of_public_method_from_exported_class_has_or_is_using_private_name_0 + case "Return_type_of_method_from_exported_interface_has_or_is_using_name_0_from_private_module_1_4056": + return Return_type_of_method_from_exported_interface_has_or_is_using_name_0_from_private_module_1 + case "Return_type_of_method_from_exported_interface_has_or_is_using_private_name_0_4057": + return Return_type_of_method_from_exported_interface_has_or_is_using_private_name_0 + case "Return_type_of_exported_function_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named_4058": + return Return_type_of_exported_function_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named + case "Return_type_of_exported_function_has_or_is_using_name_0_from_private_module_1_4059": + return Return_type_of_exported_function_has_or_is_using_name_0_from_private_module_1 + case "Return_type_of_exported_function_has_or_is_using_private_name_0_4060": + return Return_type_of_exported_function_has_or_is_using_private_name_0 + case "Parameter_0_of_constructor_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_can_4061": + return Parameter_0_of_constructor_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Parameter_0_of_constructor_from_exported_class_has_or_is_using_name_1_from_private_module_2_4062": + return Parameter_0_of_constructor_from_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_constructor_from_exported_class_has_or_is_using_private_name_1_4063": + return Parameter_0_of_constructor_from_exported_class_has_or_is_using_private_name_1 + case "Parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_name_1_from_private_mod_4064": + return Parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_1_4065": + return Parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_1 + case "Parameter_0_of_call_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2_4066": + return Parameter_0_of_call_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_call_signature_from_exported_interface_has_or_is_using_private_name_1_4067": + return Parameter_0_of_call_signature_from_exported_interface_has_or_is_using_private_name_1 + case "Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_name_1_from_external_module__4068": + return Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_name_1_from_private_module_2_4069": + return Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_private_name_1_4070": + return Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_private_name_1 + case "Parameter_0_of_public_method_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_c_4071": + return Parameter_0_of_public_method_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Parameter_0_of_public_method_from_exported_class_has_or_is_using_name_1_from_private_module_2_4072": + return Parameter_0_of_public_method_from_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_public_method_from_exported_class_has_or_is_using_private_name_1_4073": + return Parameter_0_of_public_method_from_exported_class_has_or_is_using_private_name_1 + case "Parameter_0_of_method_from_exported_interface_has_or_is_using_name_1_from_private_module_2_4074": + return Parameter_0_of_method_from_exported_interface_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_method_from_exported_interface_has_or_is_using_private_name_1_4075": + return Parameter_0_of_method_from_exported_interface_has_or_is_using_private_name_1 + case "Parameter_0_of_exported_function_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4076": + return Parameter_0_of_exported_function_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Parameter_0_of_exported_function_has_or_is_using_name_1_from_private_module_2_4077": + return Parameter_0_of_exported_function_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_exported_function_has_or_is_using_private_name_1_4078": + return Parameter_0_of_exported_function_has_or_is_using_private_name_1 + case "Exported_type_alias_0_has_or_is_using_private_name_1_4081": + return Exported_type_alias_0_has_or_is_using_private_name_1 + case "Default_export_of_the_module_has_or_is_using_private_name_0_4082": + return Default_export_of_the_module_has_or_is_using_private_name_0 + case "Type_parameter_0_of_exported_type_alias_has_or_is_using_private_name_1_4083": + return Type_parameter_0_of_exported_type_alias_has_or_is_using_private_name_1 + case "Exported_type_alias_0_has_or_is_using_private_name_1_from_module_2_4084": + return Exported_type_alias_0_has_or_is_using_private_name_1_from_module_2 + case "Extends_clause_for_inferred_type_0_has_or_is_using_private_name_1_4085": + return Extends_clause_for_inferred_type_0_has_or_is_using_private_name_1 + case "Parameter_0_of_index_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2_4091": + return Parameter_0_of_index_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_index_signature_from_exported_interface_has_or_is_using_private_name_1_4092": + return Parameter_0_of_index_signature_from_exported_interface_has_or_is_using_private_name_1 + case "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094": + return Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected + case "Public_static_method_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_4095": + return Public_static_method_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Public_static_method_0_of_exported_class_has_or_is_using_name_1_from_private_module_2_4096": + return Public_static_method_0_of_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Public_static_method_0_of_exported_class_has_or_is_using_private_name_1_4097": + return Public_static_method_0_of_exported_class_has_or_is_using_private_name_1 + case "Public_method_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4098": + return Public_method_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Public_method_0_of_exported_class_has_or_is_using_name_1_from_private_module_2_4099": + return Public_method_0_of_exported_class_has_or_is_using_name_1_from_private_module_2 + case "Public_method_0_of_exported_class_has_or_is_using_private_name_1_4100": + return Public_method_0_of_exported_class_has_or_is_using_private_name_1 + case "Method_0_of_exported_interface_has_or_is_using_name_1_from_private_module_2_4101": + return Method_0_of_exported_interface_has_or_is_using_name_1_from_private_module_2 + case "Method_0_of_exported_interface_has_or_is_using_private_name_1_4102": + return Method_0_of_exported_interface_has_or_is_using_private_name_1 + case "Type_parameter_0_of_exported_mapped_object_type_is_using_private_name_1_4103": + return Type_parameter_0_of_exported_mapped_object_type_is_using_private_name_1 + case "The_type_0_is_readonly_and_cannot_be_assigned_to_the_mutable_type_1_4104": + return The_type_0_is_readonly_and_cannot_be_assigned_to_the_mutable_type_1 + case "Private_or_protected_member_0_cannot_be_accessed_on_a_type_parameter_4105": + return Private_or_protected_member_0_cannot_be_accessed_on_a_type_parameter + case "Parameter_0_of_accessor_has_or_is_using_private_name_1_4106": + return Parameter_0_of_accessor_has_or_is_using_private_name_1 + case "Parameter_0_of_accessor_has_or_is_using_name_1_from_private_module_2_4107": + return Parameter_0_of_accessor_has_or_is_using_name_1_from_private_module_2 + case "Parameter_0_of_accessor_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4108": + return Parameter_0_of_accessor_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named + case "Type_arguments_for_0_circularly_reference_themselves_4109": + return Type_arguments_for_0_circularly_reference_themselves + case "Tuple_type_arguments_circularly_reference_themselves_4110": + return Tuple_type_arguments_circularly_reference_themselves + case "Property_0_comes_from_an_index_signature_so_it_must_be_accessed_with_0_4111": + return Property_0_comes_from_an_index_signature_so_it_must_be_accessed_with_0 + case "This_member_cannot_have_an_override_modifier_because_its_containing_class_0_does_not_extend_another__4112": + return This_member_cannot_have_an_override_modifier_because_its_containing_class_0_does_not_extend_another_class + case "This_member_cannot_have_an_override_modifier_because_it_is_not_declared_in_the_base_class_0_4113": + return This_member_cannot_have_an_override_modifier_because_it_is_not_declared_in_the_base_class_0 + case "This_member_must_have_an_override_modifier_because_it_overrides_a_member_in_the_base_class_0_4114": + return This_member_must_have_an_override_modifier_because_it_overrides_a_member_in_the_base_class_0 + case "This_parameter_property_must_have_an_override_modifier_because_it_overrides_a_member_in_base_class_0_4115": + return This_parameter_property_must_have_an_override_modifier_because_it_overrides_a_member_in_base_class_0 + case "This_member_must_have_an_override_modifier_because_it_overrides_an_abstract_method_that_is_declared__4116": + return This_member_must_have_an_override_modifier_because_it_overrides_an_abstract_method_that_is_declared_in_the_base_class_0 + case "This_member_cannot_have_an_override_modifier_because_it_is_not_declared_in_the_base_class_0_Did_you__4117": + return This_member_cannot_have_an_override_modifier_because_it_is_not_declared_in_the_base_class_0_Did_you_mean_1 + case "The_type_of_this_node_cannot_be_serialized_because_its_property_0_cannot_be_serialized_4118": + return The_type_of_this_node_cannot_be_serialized_because_its_property_0_cannot_be_serialized + case "This_member_must_have_a_JSDoc_comment_with_an_override_tag_because_it_overrides_a_member_in_the_base_4119": + return This_member_must_have_a_JSDoc_comment_with_an_override_tag_because_it_overrides_a_member_in_the_base_class_0 + case "This_parameter_property_must_have_a_JSDoc_comment_with_an_override_tag_because_it_overrides_a_member_4120": + return This_parameter_property_must_have_a_JSDoc_comment_with_an_override_tag_because_it_overrides_a_member_in_the_base_class_0 + case "This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_containing_class_0_does_not_4121": + return This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_containing_class_0_does_not_extend_another_class + case "This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_it_is_not_declared_in_the_base__4122": + return This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_it_is_not_declared_in_the_base_class_0 + case "This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_it_is_not_declared_in_the_base__4123": + return This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_it_is_not_declared_in_the_base_class_0_Did_you_mean_1 + case "Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_w_4124": + return Compiler_option_0_of_value_1_is_unstable_Use_nightly_TypeScript_to_silence_this_error_Try_updating_with_npm_install_D_typescript_next + case "Each_declaration_of_0_1_differs_in_its_value_where_2_was_expected_but_3_was_given_4125": + return Each_declaration_of_0_1_differs_in_its_value_where_2_was_expected_but_3_was_given + case "One_value_of_0_1_is_the_string_2_and_the_other_is_assumed_to_be_an_unknown_numeric_value_4126": + return One_value_of_0_1_is_the_string_2_and_the_other_is_assumed_to_be_an_unknown_numeric_value + case "This_member_cannot_have_an_override_modifier_because_its_name_is_dynamic_4127": + return This_member_cannot_have_an_override_modifier_because_its_name_is_dynamic + case "This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_name_is_dynamic_4128": + return This_member_cannot_have_a_JSDoc_comment_with_an_override_tag_because_its_name_is_dynamic + case "The_current_host_does_not_support_the_0_option_5001": + return The_current_host_does_not_support_the_0_option + case "Cannot_find_the_common_subdirectory_path_for_the_input_files_5009": + return Cannot_find_the_common_subdirectory_path_for_the_input_files + case "File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0_5010": + return File_specification_cannot_end_in_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0 + case "Cannot_read_file_0_Colon_1_5012": + return Cannot_read_file_0_Colon_1 + case "Unknown_compiler_option_0_5023": + return Unknown_compiler_option_0 + case "Compiler_option_0_requires_a_value_of_type_1_5024": + return Compiler_option_0_requires_a_value_of_type_1 + case "Unknown_compiler_option_0_Did_you_mean_1_5025": + return Unknown_compiler_option_0_Did_you_mean_1 + case "Could_not_write_file_0_Colon_1_5033": + return Could_not_write_file_0_Colon_1 + case "Option_project_cannot_be_mixed_with_source_files_on_a_command_line_5042": + return Option_project_cannot_be_mixed_with_source_files_on_a_command_line + case "Option_isolatedModules_can_only_be_used_when_either_option_module_is_provided_or_option_target_is_ES_5047": + return Option_isolatedModules_can_only_be_used_when_either_option_module_is_provided_or_option_target_is_ES2015_or_higher + case "Option_0_can_only_be_used_when_either_option_inlineSourceMap_or_option_sourceMap_is_provided_5051": + return Option_0_can_only_be_used_when_either_option_inlineSourceMap_or_option_sourceMap_is_provided + case "Option_0_cannot_be_specified_without_specifying_option_1_5052": + return Option_0_cannot_be_specified_without_specifying_option_1 + case "Option_0_cannot_be_specified_with_option_1_5053": + return Option_0_cannot_be_specified_with_option_1 + case "A_tsconfig_json_file_is_already_defined_at_Colon_0_5054": + return A_tsconfig_json_file_is_already_defined_at_Colon_0 + case "Cannot_write_file_0_because_it_would_overwrite_input_file_5055": + return Cannot_write_file_0_because_it_would_overwrite_input_file + case "Cannot_write_file_0_because_it_would_be_overwritten_by_multiple_input_files_5056": + return Cannot_write_file_0_because_it_would_be_overwritten_by_multiple_input_files + case "Cannot_find_a_tsconfig_json_file_at_the_specified_directory_Colon_0_5057": + return Cannot_find_a_tsconfig_json_file_at_the_specified_directory_Colon_0 + case "The_specified_path_does_not_exist_Colon_0_5058": + return The_specified_path_does_not_exist_Colon_0 + case "Invalid_value_for_reactNamespace_0_is_not_a_valid_identifier_5059": + return Invalid_value_for_reactNamespace_0_is_not_a_valid_identifier + case "Pattern_0_can_have_at_most_one_Asterisk_character_5061": + return Pattern_0_can_have_at_most_one_Asterisk_character + case "Substitution_0_in_pattern_1_can_have_at_most_one_Asterisk_character_5062": + return Substitution_0_in_pattern_1_can_have_at_most_one_Asterisk_character + case "Substitutions_for_pattern_0_should_be_an_array_5063": + return Substitutions_for_pattern_0_should_be_an_array + case "Substitution_0_for_pattern_1_has_incorrect_type_expected_string_got_2_5064": + return Substitution_0_for_pattern_1_has_incorrect_type_expected_string_got_2 + case "File_specification_cannot_contain_a_parent_directory_that_appears_after_a_recursive_directory_wildca_5065": + return File_specification_cannot_contain_a_parent_directory_that_appears_after_a_recursive_directory_wildcard_Asterisk_Asterisk_Colon_0 + case "Substitutions_for_pattern_0_shouldn_t_be_an_empty_array_5066": + return Substitutions_for_pattern_0_shouldn_t_be_an_empty_array + case "Invalid_value_for_jsxFactory_0_is_not_a_valid_identifier_or_qualified_name_5067": + return Invalid_value_for_jsxFactory_0_is_not_a_valid_identifier_or_qualified_name + case "Adding_a_tsconfig_json_file_will_help_organize_projects_that_contain_both_TypeScript_and_JavaScript__5068": + return Adding_a_tsconfig_json_file_will_help_organize_projects_that_contain_both_TypeScript_and_JavaScript_files_Learn_more_at_https_Colon_Slash_Slashaka_ms_Slashtsconfig + case "Option_0_cannot_be_specified_without_specifying_option_1_or_option_2_5069": + return Option_0_cannot_be_specified_without_specifying_option_1_or_option_2 + case "Option_resolveJsonModule_cannot_be_specified_when_moduleResolution_is_set_to_classic_5070": + return Option_resolveJsonModule_cannot_be_specified_when_moduleResolution_is_set_to_classic + case "Option_resolveJsonModule_cannot_be_specified_when_module_is_set_to_none_system_or_umd_5071": + return Option_resolveJsonModule_cannot_be_specified_when_module_is_set_to_none_system_or_umd + case "Unknown_build_option_0_5072": + return Unknown_build_option_0 + case "Build_option_0_requires_a_value_of_type_1_5073": + return Build_option_0_requires_a_value_of_type_1 + case "Option_incremental_can_only_be_specified_using_tsconfig_emitting_to_single_file_or_when_option_tsBui_5074": + return Option_incremental_can_only_be_specified_using_tsconfig_emitting_to_single_file_or_when_option_tsBuildInfoFile_is_specified + case "_0_is_assignable_to_the_constraint_of_type_1_but_1_could_be_instantiated_with_a_different_subtype_of_5075": + return X_0_is_assignable_to_the_constraint_of_type_1_but_1_could_be_instantiated_with_a_different_subtype_of_constraint_2 + case "_0_and_1_operations_cannot_be_mixed_without_parentheses_5076": + return X_0_and_1_operations_cannot_be_mixed_without_parentheses + case "Unknown_build_option_0_Did_you_mean_1_5077": + return Unknown_build_option_0_Did_you_mean_1 + case "Unknown_watch_option_0_5078": + return Unknown_watch_option_0 + case "Unknown_watch_option_0_Did_you_mean_1_5079": + return Unknown_watch_option_0_Did_you_mean_1 + case "Watch_option_0_requires_a_value_of_type_1_5080": + return Watch_option_0_requires_a_value_of_type_1 + case "Cannot_find_a_tsconfig_json_file_at_the_current_directory_Colon_0_5081": + return Cannot_find_a_tsconfig_json_file_at_the_current_directory_Colon_0 + case "_0_could_be_instantiated_with_an_arbitrary_type_which_could_be_unrelated_to_1_5082": + return X_0_could_be_instantiated_with_an_arbitrary_type_which_could_be_unrelated_to_1 + case "Cannot_read_file_0_5083": + return Cannot_read_file_0 + case "A_tuple_member_cannot_be_both_optional_and_rest_5085": + return A_tuple_member_cannot_be_both_optional_and_rest + case "A_labeled_tuple_element_is_declared_as_optional_with_a_question_mark_after_the_name_and_before_the_c_5086": + return A_labeled_tuple_element_is_declared_as_optional_with_a_question_mark_after_the_name_and_before_the_colon_rather_than_after_the_type + case "A_labeled_tuple_element_is_declared_as_rest_with_a_before_the_name_rather_than_before_the_type_5087": + return A_labeled_tuple_element_is_declared_as_rest_with_a_before_the_name_rather_than_before_the_type + case "The_inferred_type_of_0_references_a_type_with_a_cyclic_structure_which_cannot_be_trivially_serialize_5088": + return The_inferred_type_of_0_references_a_type_with_a_cyclic_structure_which_cannot_be_trivially_serialized_A_type_annotation_is_necessary + case "Option_0_cannot_be_specified_when_option_jsx_is_1_5089": + return Option_0_cannot_be_specified_when_option_jsx_is_1 + case "Non_relative_paths_are_not_allowed_Did_you_forget_a_leading_Slash_5090": + return Non_relative_paths_are_not_allowed_Did_you_forget_a_leading_Slash + case "Option_preserveConstEnums_cannot_be_disabled_when_0_is_enabled_5091": + return Option_preserveConstEnums_cannot_be_disabled_when_0_is_enabled + case "The_root_value_of_a_0_file_must_be_an_object_5092": + return The_root_value_of_a_0_file_must_be_an_object + case "Compiler_option_0_may_only_be_used_with_build_5093": + return Compiler_option_0_may_only_be_used_with_build + case "Compiler_option_0_may_not_be_used_with_build_5094": + return Compiler_option_0_may_not_be_used_with_build + case "Option_0_can_only_be_used_when_module_is_set_to_preserve_commonjs_or_es2015_or_later_5095": + return Option_0_can_only_be_used_when_module_is_set_to_preserve_commonjs_or_es2015_or_later + case "Option_allowImportingTsExtensions_can_only_be_used_when_either_noEmit_or_emitDeclarationOnly_is_set_5096": + return Option_allowImportingTsExtensions_can_only_be_used_when_either_noEmit_or_emitDeclarationOnly_is_set + case "An_import_path_can_only_end_with_a_0_extension_when_allowImportingTsExtensions_is_enabled_5097": + return An_import_path_can_only_end_with_a_0_extension_when_allowImportingTsExtensions_is_enabled + case "Option_0_can_only_be_used_when_moduleResolution_is_set_to_node16_nodenext_or_bundler_5098": + return Option_0_can_only_be_used_when_moduleResolution_is_set_to_node16_nodenext_or_bundler + case "Option_0_is_deprecated_and_will_stop_functioning_in_TypeScript_1_Specify_compilerOption_ignoreDeprec_5101": + return Option_0_is_deprecated_and_will_stop_functioning_in_TypeScript_1_Specify_compilerOption_ignoreDeprecations_Colon_2_to_silence_this_error + case "Option_0_has_been_removed_Please_remove_it_from_your_configuration_5102": + return Option_0_has_been_removed_Please_remove_it_from_your_configuration + case "Invalid_value_for_ignoreDeprecations_5103": + return Invalid_value_for_ignoreDeprecations + case "Option_0_is_redundant_and_cannot_be_specified_with_option_1_5104": + return Option_0_is_redundant_and_cannot_be_specified_with_option_1 + case "Option_verbatimModuleSyntax_cannot_be_used_when_module_is_set_to_UMD_AMD_or_System_5105": + return Option_verbatimModuleSyntax_cannot_be_used_when_module_is_set_to_UMD_AMD_or_System + case "Use_0_instead_5106": + return Use_0_instead + case "Option_0_1_is_deprecated_and_will_stop_functioning_in_TypeScript_2_Specify_compilerOption_ignoreDepr_5107": + return Option_0_1_is_deprecated_and_will_stop_functioning_in_TypeScript_2_Specify_compilerOption_ignoreDeprecations_Colon_3_to_silence_this_error + case "Option_0_1_has_been_removed_Please_remove_it_from_your_configuration_5108": + return Option_0_1_has_been_removed_Please_remove_it_from_your_configuration + case "Option_moduleResolution_must_be_set_to_0_or_left_unspecified_when_option_module_is_set_to_1_5109": + return Option_moduleResolution_must_be_set_to_0_or_left_unspecified_when_option_module_is_set_to_1 + case "Option_module_must_be_set_to_0_when_option_moduleResolution_is_set_to_1_5110": + return Option_module_must_be_set_to_0_when_option_moduleResolution_is_set_to_1 + case "Visit_https_Colon_Slash_Slashaka_ms_Slashts6_for_migration_information_5111": + return Visit_https_Colon_Slash_Slashaka_ms_Slashts6_for_migration_information + case "Generates_a_sourcemap_for_each_corresponding_d_ts_file_6000": + return Generates_a_sourcemap_for_each_corresponding_d_ts_file + case "Concatenate_and_emit_output_to_single_file_6001": + return Concatenate_and_emit_output_to_single_file + case "Generates_corresponding_d_ts_file_6002": + return Generates_corresponding_d_ts_file + case "Specify_the_location_where_debugger_should_locate_TypeScript_files_instead_of_source_locations_6004": + return Specify_the_location_where_debugger_should_locate_TypeScript_files_instead_of_source_locations + case "Watch_input_files_6005": + return Watch_input_files + case "Redirect_output_structure_to_the_directory_6006": + return Redirect_output_structure_to_the_directory + case "Do_not_erase_const_enum_declarations_in_generated_code_6007": + return Do_not_erase_const_enum_declarations_in_generated_code + case "Do_not_emit_outputs_if_any_errors_were_reported_6008": + return Do_not_emit_outputs_if_any_errors_were_reported + case "Do_not_emit_comments_to_output_6009": + return Do_not_emit_comments_to_output + case "Do_not_emit_outputs_6010": + return Do_not_emit_outputs + case "Allow_default_imports_from_modules_with_no_default_export_This_does_not_affect_code_emit_just_typech_6011": + return Allow_default_imports_from_modules_with_no_default_export_This_does_not_affect_code_emit_just_typechecking + case "Skip_type_checking_of_declaration_files_6012": + return Skip_type_checking_of_declaration_files + case "Do_not_resolve_the_real_path_of_symlinks_6013": + return Do_not_resolve_the_real_path_of_symlinks + case "Only_emit_d_ts_declaration_files_6014": + return Only_emit_d_ts_declaration_files + case "Specify_ECMAScript_target_version_6015": + return Specify_ECMAScript_target_version + case "Specify_module_code_generation_6016": + return Specify_module_code_generation + case "Print_this_message_6017": + return Print_this_message + case "Print_the_compiler_s_version_6019": + return Print_the_compiler_s_version + case "Compile_the_project_given_the_path_to_its_configuration_file_or_to_a_folder_with_a_tsconfig_json_6020": + return Compile_the_project_given_the_path_to_its_configuration_file_or_to_a_folder_with_a_tsconfig_json + case "Syntax_Colon_0_6023": + return Syntax_Colon_0 + case "options_6024": + return X_options + case "file_6025": + return X_file + case "Examples_Colon_0_6026": + return Examples_Colon_0 + case "Options_Colon_6027": + return Options_Colon + case "Version_0_6029": + return Version_0 + case "Insert_command_line_options_and_files_from_a_file_6030": + return Insert_command_line_options_and_files_from_a_file + case "Starting_compilation_in_watch_mode_6031": + return Starting_compilation_in_watch_mode + case "File_change_detected_Starting_incremental_compilation_6032": + return File_change_detected_Starting_incremental_compilation + case "KIND_6034": + return KIND + case "FILE_6035": + return FILE + case "VERSION_6036": + return VERSION + case "LOCATION_6037": + return LOCATION + case "DIRECTORY_6038": + return DIRECTORY + case "STRATEGY_6039": + return STRATEGY + case "FILE_OR_DIRECTORY_6040": + return FILE_OR_DIRECTORY + case "Errors_Files_6041": + return Errors_Files + case "Generates_corresponding_map_file_6043": + return Generates_corresponding_map_file + case "Compiler_option_0_expects_an_argument_6044": + return Compiler_option_0_expects_an_argument + case "Unterminated_quoted_string_in_response_file_0_6045": + return Unterminated_quoted_string_in_response_file_0 + case "Argument_for_0_option_must_be_Colon_1_6046": + return Argument_for_0_option_must_be_Colon_1 + case "Locale_must_be_an_IETF_BCP_47_language_tag_Examples_Colon_0_1_6048": + return Locale_must_be_an_IETF_BCP_47_language_tag_Examples_Colon_0_1 + case "Unable_to_open_file_0_6050": + return Unable_to_open_file_0 + case "Corrupted_locale_file_0_6051": + return Corrupted_locale_file_0 + case "Raise_error_on_expressions_and_declarations_with_an_implied_any_type_6052": + return Raise_error_on_expressions_and_declarations_with_an_implied_any_type + case "File_0_not_found_6053": + return File_0_not_found + case "File_0_has_an_unsupported_extension_The_only_supported_extensions_are_1_6054": + return File_0_has_an_unsupported_extension_The_only_supported_extensions_are_1 + case "Suppress_noImplicitAny_errors_for_indexing_objects_lacking_index_signatures_6055": + return Suppress_noImplicitAny_errors_for_indexing_objects_lacking_index_signatures + case "Do_not_emit_declarations_for_code_that_has_an_internal_annotation_6056": + return Do_not_emit_declarations_for_code_that_has_an_internal_annotation + case "Specify_the_root_directory_of_input_files_Use_to_control_the_output_directory_structure_with_outDir_6058": + return Specify_the_root_directory_of_input_files_Use_to_control_the_output_directory_structure_with_outDir + case "File_0_is_not_under_rootDir_1_rootDir_is_expected_to_contain_all_source_files_6059": + return File_0_is_not_under_rootDir_1_rootDir_is_expected_to_contain_all_source_files + case "Specify_the_end_of_line_sequence_to_be_used_when_emitting_files_Colon_CRLF_dos_or_LF_unix_6060": + return Specify_the_end_of_line_sequence_to_be_used_when_emitting_files_Colon_CRLF_dos_or_LF_unix + case "NEWLINE_6061": + return NEWLINE + case "Option_0_can_only_be_specified_in_tsconfig_json_file_or_set_to_null_on_command_line_6064": + return Option_0_can_only_be_specified_in_tsconfig_json_file_or_set_to_null_on_command_line + case "Enables_experimental_support_for_ES7_decorators_6065": + return Enables_experimental_support_for_ES7_decorators + case "Enables_experimental_support_for_emitting_type_metadata_for_decorators_6066": + return Enables_experimental_support_for_emitting_type_metadata_for_decorators + case "Initializes_a_TypeScript_project_and_creates_a_tsconfig_json_file_6070": + return Initializes_a_TypeScript_project_and_creates_a_tsconfig_json_file + case "Successfully_created_a_tsconfig_json_file_6071": + return Successfully_created_a_tsconfig_json_file + case "Suppress_excess_property_checks_for_object_literals_6072": + return Suppress_excess_property_checks_for_object_literals + case "Stylize_errors_and_messages_using_color_and_context_experimental_6073": + return Stylize_errors_and_messages_using_color_and_context_experimental + case "Do_not_report_errors_on_unused_labels_6074": + return Do_not_report_errors_on_unused_labels + case "Report_error_when_not_all_code_paths_in_function_return_a_value_6075": + return Report_error_when_not_all_code_paths_in_function_return_a_value + case "Report_errors_for_fallthrough_cases_in_switch_statement_6076": + return Report_errors_for_fallthrough_cases_in_switch_statement + case "Do_not_report_errors_on_unreachable_code_6077": + return Do_not_report_errors_on_unreachable_code + case "Disallow_inconsistently_cased_references_to_the_same_file_6078": + return Disallow_inconsistently_cased_references_to_the_same_file + case "Specify_library_files_to_be_included_in_the_compilation_6079": + return Specify_library_files_to_be_included_in_the_compilation + case "Specify_JSX_code_generation_6080": + return Specify_JSX_code_generation + case "Only_amd_and_system_modules_are_supported_alongside_0_6082": + return Only_amd_and_system_modules_are_supported_alongside_0 + case "Base_directory_to_resolve_non_absolute_module_names_6083": + return Base_directory_to_resolve_non_absolute_module_names + case "Deprecated_Use_jsxFactory_instead_Specify_the_object_invoked_for_createElement_when_targeting_react__6084": + return Deprecated_Use_jsxFactory_instead_Specify_the_object_invoked_for_createElement_when_targeting_react_JSX_emit + case "Enable_tracing_of_the_name_resolution_process_6085": + return Enable_tracing_of_the_name_resolution_process + case "Resolving_module_0_from_1_6086": + return Resolving_module_0_from_1 + case "Explicitly_specified_module_resolution_kind_Colon_0_6087": + return Explicitly_specified_module_resolution_kind_Colon_0 + case "Module_resolution_kind_is_not_specified_using_0_6088": + return Module_resolution_kind_is_not_specified_using_0 + case "Module_name_0_was_successfully_resolved_to_1_6089": + return Module_name_0_was_successfully_resolved_to_1 + case "Module_name_0_was_not_resolved_6090": + return Module_name_0_was_not_resolved + case "paths_option_is_specified_looking_for_a_pattern_to_match_module_name_0_6091": + return X_paths_option_is_specified_looking_for_a_pattern_to_match_module_name_0 + case "Module_name_0_matched_pattern_1_6092": + return Module_name_0_matched_pattern_1 + case "Trying_substitution_0_candidate_module_location_Colon_1_6093": + return Trying_substitution_0_candidate_module_location_Colon_1 + case "Resolving_module_name_0_relative_to_base_url_1_2_6094": + return Resolving_module_name_0_relative_to_base_url_1_2 + case "Loading_module_as_file_Slash_folder_candidate_module_location_0_target_file_types_Colon_1_6095": + return Loading_module_as_file_Slash_folder_candidate_module_location_0_target_file_types_Colon_1 + case "File_0_does_not_exist_6096": + return File_0_does_not_exist + case "File_0_exists_use_it_as_a_name_resolution_result_6097": + return File_0_exists_use_it_as_a_name_resolution_result + case "Loading_module_0_from_node_modules_folder_target_file_types_Colon_1_6098": + return Loading_module_0_from_node_modules_folder_target_file_types_Colon_1 + case "Found_package_json_at_0_6099": + return Found_package_json_at_0 + case "package_json_does_not_have_a_0_field_6100": + return X_package_json_does_not_have_a_0_field + case "package_json_has_0_field_1_that_references_2_6101": + return X_package_json_has_0_field_1_that_references_2 + case "Allow_javascript_files_to_be_compiled_6102": + return Allow_javascript_files_to_be_compiled + case "Checking_if_0_is_the_longest_matching_prefix_for_1_2_6104": + return Checking_if_0_is_the_longest_matching_prefix_for_1_2 + case "Expected_type_of_0_field_in_package_json_to_be_1_got_2_6105": + return Expected_type_of_0_field_in_package_json_to_be_1_got_2 + case "baseUrl_option_is_set_to_0_using_this_value_to_resolve_non_relative_module_name_1_6106": + return X_baseUrl_option_is_set_to_0_using_this_value_to_resolve_non_relative_module_name_1 + case "rootDirs_option_is_set_using_it_to_resolve_relative_module_name_0_6107": + return X_rootDirs_option_is_set_using_it_to_resolve_relative_module_name_0 + case "Longest_matching_prefix_for_0_is_1_6108": + return Longest_matching_prefix_for_0_is_1 + case "Loading_0_from_the_root_dir_1_candidate_location_2_6109": + return Loading_0_from_the_root_dir_1_candidate_location_2 + case "Trying_other_entries_in_rootDirs_6110": + return Trying_other_entries_in_rootDirs + case "Module_resolution_using_rootDirs_has_failed_6111": + return Module_resolution_using_rootDirs_has_failed + case "Do_not_emit_use_strict_directives_in_module_output_6112": + return Do_not_emit_use_strict_directives_in_module_output + case "Enable_strict_null_checks_6113": + return Enable_strict_null_checks + case "Unknown_option_excludes_Did_you_mean_exclude_6114": + return Unknown_option_excludes_Did_you_mean_exclude + case "Raise_error_on_this_expressions_with_an_implied_any_type_6115": + return Raise_error_on_this_expressions_with_an_implied_any_type + case "Resolving_type_reference_directive_0_containing_file_1_root_directory_2_6116": + return Resolving_type_reference_directive_0_containing_file_1_root_directory_2 + case "Type_reference_directive_0_was_successfully_resolved_to_1_primary_Colon_2_6119": + return Type_reference_directive_0_was_successfully_resolved_to_1_primary_Colon_2 + case "Type_reference_directive_0_was_not_resolved_6120": + return Type_reference_directive_0_was_not_resolved + case "Resolving_with_primary_search_path_0_6121": + return Resolving_with_primary_search_path_0 + case "Root_directory_cannot_be_determined_skipping_primary_search_paths_6122": + return Root_directory_cannot_be_determined_skipping_primary_search_paths + case "Resolving_type_reference_directive_0_containing_file_1_root_directory_not_set_6123": + return Resolving_type_reference_directive_0_containing_file_1_root_directory_not_set + case "Type_declaration_files_to_be_included_in_compilation_6124": + return Type_declaration_files_to_be_included_in_compilation + case "Looking_up_in_node_modules_folder_initial_location_0_6125": + return Looking_up_in_node_modules_folder_initial_location_0 + case "Containing_file_is_not_specified_and_root_directory_cannot_be_determined_skipping_lookup_in_node_mod_6126": + return Containing_file_is_not_specified_and_root_directory_cannot_be_determined_skipping_lookup_in_node_modules_folder + case "Resolving_type_reference_directive_0_containing_file_not_set_root_directory_1_6127": + return Resolving_type_reference_directive_0_containing_file_not_set_root_directory_1 + case "Resolving_type_reference_directive_0_containing_file_not_set_root_directory_not_set_6128": + return Resolving_type_reference_directive_0_containing_file_not_set_root_directory_not_set + case "Resolving_real_path_for_0_result_1_6130": + return Resolving_real_path_for_0_result_1 + case "Cannot_compile_modules_using_option_0_unless_the_module_flag_is_amd_or_system_6131": + return Cannot_compile_modules_using_option_0_unless_the_module_flag_is_amd_or_system + case "File_name_0_has_a_1_extension_stripping_it_6132": + return File_name_0_has_a_1_extension_stripping_it + case "_0_is_declared_but_its_value_is_never_read_6133": + return X_0_is_declared_but_its_value_is_never_read + case "Report_errors_on_unused_locals_6134": + return Report_errors_on_unused_locals + case "Report_errors_on_unused_parameters_6135": + return Report_errors_on_unused_parameters + case "The_maximum_dependency_depth_to_search_under_node_modules_and_load_JavaScript_files_6136": + return The_maximum_dependency_depth_to_search_under_node_modules_and_load_JavaScript_files + case "Cannot_import_type_declaration_files_Consider_importing_0_instead_of_1_6137": + return Cannot_import_type_declaration_files_Consider_importing_0_instead_of_1 + case "Property_0_is_declared_but_its_value_is_never_read_6138": + return Property_0_is_declared_but_its_value_is_never_read + case "Import_emit_helpers_from_tslib_6139": + return Import_emit_helpers_from_tslib + case "Auto_discovery_for_typings_is_enabled_in_project_0_Running_extra_resolution_pass_for_module_1_using__6140": + return Auto_discovery_for_typings_is_enabled_in_project_0_Running_extra_resolution_pass_for_module_1_using_cache_location_2 + case "Parse_in_strict_mode_and_emit_use_strict_for_each_source_file_6141": + return Parse_in_strict_mode_and_emit_use_strict_for_each_source_file + case "Module_0_was_resolved_to_1_but_jsx_is_not_set_6142": + return Module_0_was_resolved_to_1_but_jsx_is_not_set + case "Module_0_was_resolved_as_locally_declared_ambient_module_in_file_1_6144": + return Module_0_was_resolved_as_locally_declared_ambient_module_in_file_1 + case "Specify_the_JSX_factory_function_to_use_when_targeting_react_JSX_emit_e_g_React_createElement_or_h_6146": + return Specify_the_JSX_factory_function_to_use_when_targeting_react_JSX_emit_e_g_React_createElement_or_h + case "Resolution_for_module_0_was_found_in_cache_from_location_1_6147": + return Resolution_for_module_0_was_found_in_cache_from_location_1 + case "Directory_0_does_not_exist_skipping_all_lookups_in_it_6148": + return Directory_0_does_not_exist_skipping_all_lookups_in_it + case "Show_diagnostic_information_6149": + return Show_diagnostic_information + case "Show_verbose_diagnostic_information_6150": + return Show_verbose_diagnostic_information + case "Emit_a_single_file_with_source_maps_instead_of_having_a_separate_file_6151": + return Emit_a_single_file_with_source_maps_instead_of_having_a_separate_file + case "Emit_the_source_alongside_the_sourcemaps_within_a_single_file_requires_inlineSourceMap_or_sourceMap__6152": + return Emit_the_source_alongside_the_sourcemaps_within_a_single_file_requires_inlineSourceMap_or_sourceMap_to_be_set + case "Transpile_each_file_as_a_separate_module_similar_to_ts_transpileModule_6153": + return Transpile_each_file_as_a_separate_module_similar_to_ts_transpileModule + case "Print_names_of_generated_files_part_of_the_compilation_6154": + return Print_names_of_generated_files_part_of_the_compilation + case "Print_names_of_files_part_of_the_compilation_6155": + return Print_names_of_files_part_of_the_compilation + case "The_locale_used_when_displaying_messages_to_the_user_e_g_en_us_6156": + return The_locale_used_when_displaying_messages_to_the_user_e_g_en_us + case "Do_not_generate_custom_helper_functions_like_extends_in_compiled_output_6157": + return Do_not_generate_custom_helper_functions_like_extends_in_compiled_output + case "Do_not_include_the_default_library_file_lib_d_ts_6158": + return Do_not_include_the_default_library_file_lib_d_ts + case "Do_not_add_triple_slash_references_or_imported_modules_to_the_list_of_compiled_files_6159": + return Do_not_add_triple_slash_references_or_imported_modules_to_the_list_of_compiled_files + case "Deprecated_Use_skipLibCheck_instead_Skip_type_checking_of_default_library_declaration_files_6160": + return Deprecated_Use_skipLibCheck_instead_Skip_type_checking_of_default_library_declaration_files + case "List_of_folders_to_include_type_definitions_from_6161": + return List_of_folders_to_include_type_definitions_from + case "Disable_size_limitations_on_JavaScript_projects_6162": + return Disable_size_limitations_on_JavaScript_projects + case "The_character_set_of_the_input_files_6163": + return The_character_set_of_the_input_files + case "Skipping_module_0_that_looks_like_an_absolute_URI_target_file_types_Colon_1_6164": + return Skipping_module_0_that_looks_like_an_absolute_URI_target_file_types_Colon_1 + case "Do_not_truncate_error_messages_6165": + return Do_not_truncate_error_messages + case "Output_directory_for_generated_declaration_files_6166": + return Output_directory_for_generated_declaration_files + case "A_series_of_entries_which_re_map_imports_to_lookup_locations_relative_to_the_baseUrl_6167": + return A_series_of_entries_which_re_map_imports_to_lookup_locations_relative_to_the_baseUrl + case "List_of_root_folders_whose_combined_content_represents_the_structure_of_the_project_at_runtime_6168": + return List_of_root_folders_whose_combined_content_represents_the_structure_of_the_project_at_runtime + case "Show_all_compiler_options_6169": + return Show_all_compiler_options + case "Deprecated_Use_outFile_instead_Concatenate_and_emit_output_to_single_file_6170": + return Deprecated_Use_outFile_instead_Concatenate_and_emit_output_to_single_file + case "Command_line_Options_6171": + return Command_line_Options + case "Provide_full_support_for_iterables_in_for_of_spread_and_destructuring_when_targeting_ES5_6179": + return Provide_full_support_for_iterables_in_for_of_spread_and_destructuring_when_targeting_ES5 + case "Enable_all_strict_type_checking_options_6180": + return Enable_all_strict_type_checking_options + case "Scoped_package_detected_looking_in_0_6182": + return Scoped_package_detected_looking_in_0 + case "Reusing_resolution_of_module_0_from_1_of_old_program_it_was_successfully_resolved_to_2_6183": + return Reusing_resolution_of_module_0_from_1_of_old_program_it_was_successfully_resolved_to_2 + case "Reusing_resolution_of_module_0_from_1_of_old_program_it_was_successfully_resolved_to_2_with_Package__6184": + return Reusing_resolution_of_module_0_from_1_of_old_program_it_was_successfully_resolved_to_2_with_Package_ID_3 + case "Enable_strict_checking_of_function_types_6186": + return Enable_strict_checking_of_function_types + case "Enable_strict_checking_of_property_initialization_in_classes_6187": + return Enable_strict_checking_of_property_initialization_in_classes + case "Numeric_separators_are_not_allowed_here_6188": + return Numeric_separators_are_not_allowed_here + case "Multiple_consecutive_numeric_separators_are_not_permitted_6189": + return Multiple_consecutive_numeric_separators_are_not_permitted + case "Whether_to_keep_outdated_console_output_in_watch_mode_instead_of_clearing_the_screen_6191": + return Whether_to_keep_outdated_console_output_in_watch_mode_instead_of_clearing_the_screen + case "All_imports_in_import_declaration_are_unused_6192": + return All_imports_in_import_declaration_are_unused + case "Found_1_error_Watching_for_file_changes_6193": + return Found_1_error_Watching_for_file_changes + case "Found_0_errors_Watching_for_file_changes_6194": + return Found_0_errors_Watching_for_file_changes + case "Resolve_keyof_to_string_valued_property_names_only_no_numbers_or_symbols_6195": + return Resolve_keyof_to_string_valued_property_names_only_no_numbers_or_symbols + case "_0_is_declared_but_never_used_6196": + return X_0_is_declared_but_never_used + case "Include_modules_imported_with_json_extension_6197": + return Include_modules_imported_with_json_extension + case "All_destructured_elements_are_unused_6198": + return All_destructured_elements_are_unused + case "All_variables_are_unused_6199": + return All_variables_are_unused + case "Definitions_of_the_following_identifiers_conflict_with_those_in_another_file_Colon_0_6200": + return Definitions_of_the_following_identifiers_conflict_with_those_in_another_file_Colon_0 + case "Conflicts_are_in_this_file_6201": + return Conflicts_are_in_this_file + case "Project_references_may_not_form_a_circular_graph_Cycle_detected_Colon_0_6202": + return Project_references_may_not_form_a_circular_graph_Cycle_detected_Colon_0 + case "_0_was_also_declared_here_6203": + return X_0_was_also_declared_here + case "and_here_6204": + return X_and_here + case "All_type_parameters_are_unused_6205": + return All_type_parameters_are_unused + case "package_json_has_a_typesVersions_field_with_version_specific_path_mappings_6206": + return X_package_json_has_a_typesVersions_field_with_version_specific_path_mappings + case "package_json_does_not_have_a_typesVersions_entry_that_matches_version_0_6207": + return X_package_json_does_not_have_a_typesVersions_entry_that_matches_version_0 + case "package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_ma_6208": + return X_package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2 + case "package_json_has_a_typesVersions_entry_0_that_is_not_a_valid_semver_range_6209": + return X_package_json_has_a_typesVersions_entry_0_that_is_not_a_valid_semver_range + case "An_argument_for_0_was_not_provided_6210": + return An_argument_for_0_was_not_provided + case "An_argument_matching_this_binding_pattern_was_not_provided_6211": + return An_argument_matching_this_binding_pattern_was_not_provided + case "Did_you_mean_to_call_this_expression_6212": + return Did_you_mean_to_call_this_expression + case "Did_you_mean_to_use_new_with_this_expression_6213": + return Did_you_mean_to_use_new_with_this_expression + case "Enable_strict_bind_call_and_apply_methods_on_functions_6214": + return Enable_strict_bind_call_and_apply_methods_on_functions + case "Using_compiler_options_of_project_reference_redirect_0_6215": + return Using_compiler_options_of_project_reference_redirect_0 + case "Found_1_error_6216": + return Found_1_error + case "Found_0_errors_6217": + return Found_0_errors + case "Module_name_0_was_successfully_resolved_to_1_with_Package_ID_2_6218": + return Module_name_0_was_successfully_resolved_to_1_with_Package_ID_2 + case "Type_reference_directive_0_was_successfully_resolved_to_1_with_Package_ID_2_primary_Colon_3_6219": + return Type_reference_directive_0_was_successfully_resolved_to_1_with_Package_ID_2_primary_Colon_3 + case "package_json_had_a_falsy_0_field_6220": + return X_package_json_had_a_falsy_0_field + case "Disable_use_of_source_files_instead_of_declaration_files_from_referenced_projects_6221": + return Disable_use_of_source_files_instead_of_declaration_files_from_referenced_projects + case "Emit_class_fields_with_Define_instead_of_Set_6222": + return Emit_class_fields_with_Define_instead_of_Set + case "Generates_a_CPU_profile_6223": + return Generates_a_CPU_profile + case "Disable_solution_searching_for_this_project_6224": + return Disable_solution_searching_for_this_project + case "Specify_strategy_for_watching_file_Colon_FixedPollingInterval_default_PriorityPollingInterval_Dynami_6225": + return Specify_strategy_for_watching_file_Colon_FixedPollingInterval_default_PriorityPollingInterval_DynamicPriorityPolling_FixedChunkSizePolling_UseFsEvents_UseFsEventsOnParentDirectory + case "Specify_strategy_for_watching_directory_on_platforms_that_don_t_support_recursive_watching_natively__6226": + return Specify_strategy_for_watching_directory_on_platforms_that_don_t_support_recursive_watching_natively_Colon_UseFsEvents_default_FixedPollingInterval_DynamicPriorityPolling_FixedChunkSizePolling + case "Specify_strategy_for_creating_a_polling_watch_when_it_fails_to_create_using_file_system_events_Colon_6227": + return Specify_strategy_for_creating_a_polling_watch_when_it_fails_to_create_using_file_system_events_Colon_FixedInterval_default_PriorityInterval_DynamicPriority_FixedChunkSize + case "Tag_0_expects_at_least_1_arguments_but_the_JSX_factory_2_provides_at_most_3_6229": + return Tag_0_expects_at_least_1_arguments_but_the_JSX_factory_2_provides_at_most_3 + case "Option_0_can_only_be_specified_in_tsconfig_json_file_or_set_to_false_or_null_on_command_line_6230": + return Option_0_can_only_be_specified_in_tsconfig_json_file_or_set_to_false_or_null_on_command_line + case "Could_not_resolve_the_path_0_with_the_extensions_Colon_1_6231": + return Could_not_resolve_the_path_0_with_the_extensions_Colon_1 + case "Declaration_augments_declaration_in_another_file_This_cannot_be_serialized_6232": + return Declaration_augments_declaration_in_another_file_This_cannot_be_serialized + case "This_is_the_declaration_being_augmented_Consider_moving_the_augmenting_declaration_into_the_same_fil_6233": + return This_is_the_declaration_being_augmented_Consider_moving_the_augmenting_declaration_into_the_same_file + case "This_expression_is_not_callable_because_it_is_a_get_accessor_Did_you_mean_to_use_it_without_6234": + return This_expression_is_not_callable_because_it_is_a_get_accessor_Did_you_mean_to_use_it_without + case "Disable_loading_referenced_projects_6235": + return Disable_loading_referenced_projects + case "Arguments_for_the_rest_parameter_0_were_not_provided_6236": + return Arguments_for_the_rest_parameter_0_were_not_provided + case "Generates_an_event_trace_and_a_list_of_types_6237": + return Generates_an_event_trace_and_a_list_of_types + case "Specify_the_module_specifier_to_be_used_to_import_the_jsx_and_jsxs_factory_functions_from_eg_react_6238": + return Specify_the_module_specifier_to_be_used_to_import_the_jsx_and_jsxs_factory_functions_from_eg_react + case "File_0_exists_according_to_earlier_cached_lookups_6239": + return File_0_exists_according_to_earlier_cached_lookups + case "File_0_does_not_exist_according_to_earlier_cached_lookups_6240": + return File_0_does_not_exist_according_to_earlier_cached_lookups + case "Resolution_for_type_reference_directive_0_was_found_in_cache_from_location_1_6241": + return Resolution_for_type_reference_directive_0_was_found_in_cache_from_location_1 + case "Resolving_type_reference_directive_0_containing_file_1_6242": + return Resolving_type_reference_directive_0_containing_file_1 + case "Interpret_optional_property_types_as_written_rather_than_adding_undefined_6243": + return Interpret_optional_property_types_as_written_rather_than_adding_undefined + case "Modules_6244": + return Modules + case "File_Management_6245": + return File_Management + case "Emit_6246": + return Emit + case "JavaScript_Support_6247": + return JavaScript_Support + case "Type_Checking_6248": + return Type_Checking + case "Editor_Support_6249": + return Editor_Support + case "Watch_and_Build_Modes_6250": + return Watch_and_Build_Modes + case "Compiler_Diagnostics_6251": + return Compiler_Diagnostics + case "Interop_Constraints_6252": + return Interop_Constraints + case "Backwards_Compatibility_6253": + return Backwards_Compatibility + case "Language_and_Environment_6254": + return Language_and_Environment + case "Projects_6255": + return Projects + case "Output_Formatting_6256": + return Output_Formatting + case "Completeness_6257": + return Completeness + case "_0_should_be_set_inside_the_compilerOptions_object_of_the_config_json_file_6258": + return X_0_should_be_set_inside_the_compilerOptions_object_of_the_config_json_file + case "Found_1_error_in_0_6259": + return Found_1_error_in_0 + case "Found_0_errors_in_the_same_file_starting_at_Colon_1_6260": + return Found_0_errors_in_the_same_file_starting_at_Colon_1 + case "Found_0_errors_in_1_files_6261": + return Found_0_errors_in_1_files + case "File_name_0_has_a_1_extension_looking_up_2_instead_6262": + return File_name_0_has_a_1_extension_looking_up_2_instead + case "Module_0_was_resolved_to_1_but_allowArbitraryExtensions_is_not_set_6263": + return Module_0_was_resolved_to_1_but_allowArbitraryExtensions_is_not_set + case "Enable_importing_files_with_any_extension_provided_a_declaration_file_is_present_6264": + return Enable_importing_files_with_any_extension_provided_a_declaration_file_is_present + case "Resolving_type_reference_directive_for_program_that_specifies_custom_typeRoots_skipping_lookup_in_no_6265": + return Resolving_type_reference_directive_for_program_that_specifies_custom_typeRoots_skipping_lookup_in_node_modules_folder + case "Option_0_can_only_be_specified_on_command_line_6266": + return Option_0_can_only_be_specified_on_command_line + case "Directory_0_has_no_containing_package_json_scope_Imports_will_not_resolve_6270": + return Directory_0_has_no_containing_package_json_scope_Imports_will_not_resolve + case "Import_specifier_0_does_not_exist_in_package_json_scope_at_path_1_6271": + return Import_specifier_0_does_not_exist_in_package_json_scope_at_path_1 + case "Invalid_import_specifier_0_has_no_possible_resolutions_6272": + return Invalid_import_specifier_0_has_no_possible_resolutions + case "package_json_scope_0_has_no_imports_defined_6273": + return X_package_json_scope_0_has_no_imports_defined + case "package_json_scope_0_explicitly_maps_specifier_1_to_null_6274": + return X_package_json_scope_0_explicitly_maps_specifier_1_to_null + case "package_json_scope_0_has_invalid_type_for_target_of_specifier_1_6275": + return X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1 + case "Export_specifier_0_does_not_exist_in_package_json_scope_at_path_1_6276": + return Export_specifier_0_does_not_exist_in_package_json_scope_at_path_1 + case "Resolution_of_non_relative_name_failed_trying_with_modern_Node_resolution_features_disabled_to_see_i_6277": + return Resolution_of_non_relative_name_failed_trying_with_modern_Node_resolution_features_disabled_to_see_if_npm_library_needs_configuration_update + case "There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278": + return There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The_1_library_may_need_to_update_its_package_json_or_typings + case "Resolution_of_non_relative_name_failed_trying_with_moduleResolution_bundler_to_see_if_project_may_ne_6279": + return Resolution_of_non_relative_name_failed_trying_with_moduleResolution_bundler_to_see_if_project_may_need_configuration_update + case "There_are_types_at_0_but_this_result_could_not_be_resolved_under_your_current_moduleResolution_setti_6280": + return There_are_types_at_0_but_this_result_could_not_be_resolved_under_your_current_moduleResolution_setting_Consider_updating_to_node16_nodenext_or_bundler + case "package_json_has_a_peerDependencies_field_6281": + return X_package_json_has_a_peerDependencies_field + case "Found_peerDependency_0_with_1_version_6282": + return Found_peerDependency_0_with_1_version + case "Failed_to_find_peerDependency_0_6283": + return Failed_to_find_peerDependency_0 + case "File_Layout_6284": + return File_Layout + case "Environment_Settings_6285": + return Environment_Settings + case "See_also_https_Colon_Slash_Slashaka_ms_Slashtsconfig_Slashmodule_6286": + return See_also_https_Colon_Slash_Slashaka_ms_Slashtsconfig_Slashmodule + case "For_nodejs_Colon_6287": + return For_nodejs_Colon + case "and_npm_install_D_types_Slashnode_6290": + return X_and_npm_install_D_types_Slashnode + case "Other_Outputs_6291": + return Other_Outputs + case "Stricter_Typechecking_Options_6292": + return Stricter_Typechecking_Options + case "Style_Options_6293": + return Style_Options + case "Recommended_Options_6294": + return Recommended_Options + case "Enable_project_compilation_6302": + return Enable_project_compilation + case "Composite_projects_may_not_disable_declaration_emit_6304": + return Composite_projects_may_not_disable_declaration_emit + case "Output_file_0_has_not_been_built_from_source_file_1_6305": + return Output_file_0_has_not_been_built_from_source_file_1 + case "Referenced_project_0_must_have_setting_composite_Colon_true_6306": + return Referenced_project_0_must_have_setting_composite_Colon_true + case "File_0_is_not_listed_within_the_file_list_of_project_1_Projects_must_list_all_files_or_use_an_includ_6307": + return File_0_is_not_listed_within_the_file_list_of_project_1_Projects_must_list_all_files_or_use_an_include_pattern + case "Referenced_project_0_may_not_disable_emit_6310": + return Referenced_project_0_may_not_disable_emit + case "Project_0_is_out_of_date_because_output_1_is_older_than_input_2_6350": + return Project_0_is_out_of_date_because_output_1_is_older_than_input_2 + case "Project_0_is_up_to_date_because_newest_input_1_is_older_than_output_2_6351": + return Project_0_is_up_to_date_because_newest_input_1_is_older_than_output_2 + case "Project_0_is_out_of_date_because_output_file_1_does_not_exist_6352": + return Project_0_is_out_of_date_because_output_file_1_does_not_exist + case "Failed_to_delete_file_0_6353": + return Failed_to_delete_file_0 + case "Project_0_is_up_to_date_with_d_ts_files_from_its_dependencies_6354": + return Project_0_is_up_to_date_with_d_ts_files_from_its_dependencies + case "Projects_in_this_build_Colon_0_6355": + return Projects_in_this_build_Colon_0 + case "A_non_dry_build_would_delete_the_following_files_Colon_0_6356": + return A_non_dry_build_would_delete_the_following_files_Colon_0 + case "A_non_dry_build_would_build_project_0_6357": + return A_non_dry_build_would_build_project_0 + case "Building_project_0_6358": + return Building_project_0 + case "Updating_output_timestamps_of_project_0_6359": + return Updating_output_timestamps_of_project_0 + case "Project_0_is_up_to_date_6361": + return Project_0_is_up_to_date + case "Skipping_build_of_project_0_because_its_dependency_1_has_errors_6362": + return Skipping_build_of_project_0_because_its_dependency_1_has_errors + case "Project_0_can_t_be_built_because_its_dependency_1_has_errors_6363": + return Project_0_can_t_be_built_because_its_dependency_1_has_errors + case "Build_one_or_more_projects_and_their_dependencies_if_out_of_date_6364": + return Build_one_or_more_projects_and_their_dependencies_if_out_of_date + case "Delete_the_outputs_of_all_projects_6365": + return Delete_the_outputs_of_all_projects + case "Show_what_would_be_built_or_deleted_if_specified_with_clean_6367": + return Show_what_would_be_built_or_deleted_if_specified_with_clean + case "Option_build_must_be_the_first_command_line_argument_6369": + return Option_build_must_be_the_first_command_line_argument + case "Options_0_and_1_cannot_be_combined_6370": + return Options_0_and_1_cannot_be_combined + case "Updating_unchanged_output_timestamps_of_project_0_6371": + return Updating_unchanged_output_timestamps_of_project_0 + case "A_non_dry_build_would_update_timestamps_for_output_of_project_0_6374": + return A_non_dry_build_would_update_timestamps_for_output_of_project_0 + case "Cannot_write_file_0_because_it_will_overwrite_tsbuildinfo_file_generated_by_referenced_project_1_6377": + return Cannot_write_file_0_because_it_will_overwrite_tsbuildinfo_file_generated_by_referenced_project_1 + case "Composite_projects_may_not_disable_incremental_compilation_6379": + return Composite_projects_may_not_disable_incremental_compilation + case "Specify_file_to_store_incremental_compilation_information_6380": + return Specify_file_to_store_incremental_compilation_information + case "Project_0_is_out_of_date_because_output_for_it_was_generated_with_version_1_that_differs_with_curren_6381": + return Project_0_is_out_of_date_because_output_for_it_was_generated_with_version_1_that_differs_with_current_version_2 + case "Skipping_build_of_project_0_because_its_dependency_1_was_not_built_6382": + return Skipping_build_of_project_0_because_its_dependency_1_was_not_built + case "Project_0_can_t_be_built_because_its_dependency_1_was_not_built_6383": + return Project_0_can_t_be_built_because_its_dependency_1_was_not_built + case "Have_recompiles_in_incremental_and_watch_assume_that_changes_within_a_file_will_only_affect_files_di_6384": + return Have_recompiles_in_incremental_and_watch_assume_that_changes_within_a_file_will_only_affect_files_directly_depending_on_it + case "_0_is_deprecated_6385": + return X_0_is_deprecated + case "Performance_timings_for_diagnostics_or_extendedDiagnostics_are_not_available_in_this_session_A_nativ_6386": + return Performance_timings_for_diagnostics_or_extendedDiagnostics_are_not_available_in_this_session_A_native_implementation_of_the_Web_Performance_API_could_not_be_found + case "The_signature_0_of_1_is_deprecated_6387": + return The_signature_0_of_1_is_deprecated + case "Project_0_is_being_forcibly_rebuilt_6388": + return Project_0_is_being_forcibly_rebuilt + case "Reusing_resolution_of_module_0_from_1_of_old_program_it_was_not_resolved_6389": + return Reusing_resolution_of_module_0_from_1_of_old_program_it_was_not_resolved + case "Reusing_resolution_of_type_reference_directive_0_from_1_of_old_program_it_was_successfully_resolved__6390": + return Reusing_resolution_of_type_reference_directive_0_from_1_of_old_program_it_was_successfully_resolved_to_2 + case "Reusing_resolution_of_type_reference_directive_0_from_1_of_old_program_it_was_successfully_resolved__6391": + return Reusing_resolution_of_type_reference_directive_0_from_1_of_old_program_it_was_successfully_resolved_to_2_with_Package_ID_3 + case "Reusing_resolution_of_type_reference_directive_0_from_1_of_old_program_it_was_not_resolved_6392": + return Reusing_resolution_of_type_reference_directive_0_from_1_of_old_program_it_was_not_resolved + case "Reusing_resolution_of_module_0_from_1_found_in_cache_from_location_2_it_was_successfully_resolved_to_6393": + return Reusing_resolution_of_module_0_from_1_found_in_cache_from_location_2_it_was_successfully_resolved_to_3 + case "Reusing_resolution_of_module_0_from_1_found_in_cache_from_location_2_it_was_successfully_resolved_to_6394": + return Reusing_resolution_of_module_0_from_1_found_in_cache_from_location_2_it_was_successfully_resolved_to_3_with_Package_ID_4 + case "Reusing_resolution_of_module_0_from_1_found_in_cache_from_location_2_it_was_not_resolved_6395": + return Reusing_resolution_of_module_0_from_1_found_in_cache_from_location_2_it_was_not_resolved + case "Reusing_resolution_of_type_reference_directive_0_from_1_found_in_cache_from_location_2_it_was_succes_6396": + return Reusing_resolution_of_type_reference_directive_0_from_1_found_in_cache_from_location_2_it_was_successfully_resolved_to_3 + case "Reusing_resolution_of_type_reference_directive_0_from_1_found_in_cache_from_location_2_it_was_succes_6397": + return Reusing_resolution_of_type_reference_directive_0_from_1_found_in_cache_from_location_2_it_was_successfully_resolved_to_3_with_Package_ID_4 + case "Reusing_resolution_of_type_reference_directive_0_from_1_found_in_cache_from_location_2_it_was_not_re_6398": + return Reusing_resolution_of_type_reference_directive_0_from_1_found_in_cache_from_location_2_it_was_not_resolved + case "Project_0_is_out_of_date_because_buildinfo_file_1_indicates_that_some_of_the_changes_were_not_emitte_6399": + return Project_0_is_out_of_date_because_buildinfo_file_1_indicates_that_some_of_the_changes_were_not_emitted + case "Project_0_is_up_to_date_but_needs_to_update_timestamps_of_output_files_that_are_older_than_input_fil_6400": + return Project_0_is_up_to_date_but_needs_to_update_timestamps_of_output_files_that_are_older_than_input_files + case "Project_0_is_out_of_date_because_config_file_does_not_exist_6401": + return Project_0_is_out_of_date_because_config_file_does_not_exist + case "Resolving_in_0_mode_with_conditions_1_6402": + return Resolving_in_0_mode_with_conditions_1 + case "Matched_0_condition_1_6403": + return Matched_0_condition_1 + case "Using_0_subpath_1_with_target_2_6404": + return Using_0_subpath_1_with_target_2 + case "Saw_non_matching_condition_0_6405": + return Saw_non_matching_condition_0 + case "Project_0_is_out_of_date_because_buildinfo_file_1_indicates_there_is_change_in_compilerOptions_6406": + return Project_0_is_out_of_date_because_buildinfo_file_1_indicates_there_is_change_in_compilerOptions + case "Allow_imports_to_include_TypeScript_file_extensions_Requires_moduleResolution_bundler_and_either_noE_6407": + return Allow_imports_to_include_TypeScript_file_extensions_Requires_moduleResolution_bundler_and_either_noEmit_or_emitDeclarationOnly_to_be_set + case "Use_the_package_json_exports_field_when_resolving_package_imports_6408": + return Use_the_package_json_exports_field_when_resolving_package_imports + case "Use_the_package_json_imports_field_when_resolving_imports_6409": + return Use_the_package_json_imports_field_when_resolving_imports + case "Conditions_to_set_in_addition_to_the_resolver_specific_defaults_when_resolving_imports_6410": + return Conditions_to_set_in_addition_to_the_resolver_specific_defaults_when_resolving_imports + case "true_when_moduleResolution_is_node16_nodenext_or_bundler_otherwise_false_6411": + return X_true_when_moduleResolution_is_node16_nodenext_or_bundler_otherwise_false + case "Project_0_is_out_of_date_because_buildinfo_file_1_indicates_that_file_2_was_root_file_of_compilation_6412": + return Project_0_is_out_of_date_because_buildinfo_file_1_indicates_that_file_2_was_root_file_of_compilation_but_not_any_more + case "Entering_conditional_exports_6413": + return Entering_conditional_exports + case "Resolved_under_condition_0_6414": + return Resolved_under_condition_0 + case "Failed_to_resolve_under_condition_0_6415": + return Failed_to_resolve_under_condition_0 + case "Exiting_conditional_exports_6416": + return Exiting_conditional_exports + case "Searching_all_ancestor_node_modules_directories_for_preferred_extensions_Colon_0_6417": + return Searching_all_ancestor_node_modules_directories_for_preferred_extensions_Colon_0 + case "Searching_all_ancestor_node_modules_directories_for_fallback_extensions_Colon_0_6418": + return Searching_all_ancestor_node_modules_directories_for_fallback_extensions_Colon_0 + case "Project_0_is_out_of_date_because_buildinfo_file_1_indicates_that_program_needs_to_report_errors_6419": + return Project_0_is_out_of_date_because_buildinfo_file_1_indicates_that_program_needs_to_report_errors + case "Project_0_is_out_of_date_because_input_1_does_not_exist_6420": + return Project_0_is_out_of_date_because_input_1_does_not_exist + case "Rewrite_ts_tsx_mts_and_cts_file_extensions_in_relative_import_paths_to_their_JavaScript_equivalent_i_6421": + return Rewrite_ts_tsx_mts_and_cts_file_extensions_in_relative_import_paths_to_their_JavaScript_equivalent_in_output_files + case "Project_0_is_out_of_date_because_it_has_errors_6423": + return Project_0_is_out_of_date_because_it_has_errors + case "The_expected_type_comes_from_property_0_which_is_declared_here_on_type_1_6500": + return The_expected_type_comes_from_property_0_which_is_declared_here_on_type_1 + case "The_expected_type_comes_from_this_index_signature_6501": + return The_expected_type_comes_from_this_index_signature + case "The_expected_type_comes_from_the_return_type_of_this_signature_6502": + return The_expected_type_comes_from_the_return_type_of_this_signature + case "Print_names_of_files_that_are_part_of_the_compilation_and_then_stop_processing_6503": + return Print_names_of_files_that_are_part_of_the_compilation_and_then_stop_processing + case "File_0_is_a_JavaScript_file_Did_you_mean_to_enable_the_allowJs_option_6504": + return File_0_is_a_JavaScript_file_Did_you_mean_to_enable_the_allowJs_option + case "Print_names_of_files_and_the_reason_they_are_part_of_the_compilation_6505": + return Print_names_of_files_and_the_reason_they_are_part_of_the_compilation + case "Consider_adding_a_declare_modifier_to_this_class_6506": + return Consider_adding_a_declare_modifier_to_this_class + case "Allow_JavaScript_files_to_be_a_part_of_your_program_Use_the_checkJs_option_to_get_errors_from_these__6600": + return Allow_JavaScript_files_to_be_a_part_of_your_program_Use_the_checkJs_option_to_get_errors_from_these_files + case "Allow_import_x_from_y_when_a_module_doesn_t_have_a_default_export_6601": + return Allow_import_x_from_y_when_a_module_doesn_t_have_a_default_export + case "Allow_accessing_UMD_globals_from_modules_6602": + return Allow_accessing_UMD_globals_from_modules + case "Disable_error_reporting_for_unreachable_code_6603": + return Disable_error_reporting_for_unreachable_code + case "Disable_error_reporting_for_unused_labels_6604": + return Disable_error_reporting_for_unused_labels + case "Ensure_use_strict_is_always_emitted_6605": + return Ensure_use_strict_is_always_emitted + case "Have_recompiles_in_projects_that_use_incremental_and_watch_mode_assume_that_changes_within_a_file_wi_6606": + return Have_recompiles_in_projects_that_use_incremental_and_watch_mode_assume_that_changes_within_a_file_will_only_affect_files_directly_depending_on_it + case "Specify_the_base_directory_to_resolve_non_relative_module_names_6607": + return Specify_the_base_directory_to_resolve_non_relative_module_names + case "No_longer_supported_In_early_versions_manually_set_the_text_encoding_for_reading_files_6608": + return No_longer_supported_In_early_versions_manually_set_the_text_encoding_for_reading_files + case "Enable_error_reporting_in_type_checked_JavaScript_files_6609": + return Enable_error_reporting_in_type_checked_JavaScript_files + case "Enable_constraints_that_allow_a_TypeScript_project_to_be_used_with_project_references_6611": + return Enable_constraints_that_allow_a_TypeScript_project_to_be_used_with_project_references + case "Generate_d_ts_files_from_TypeScript_and_JavaScript_files_in_your_project_6612": + return Generate_d_ts_files_from_TypeScript_and_JavaScript_files_in_your_project + case "Specify_the_output_directory_for_generated_declaration_files_6613": + return Specify_the_output_directory_for_generated_declaration_files + case "Create_sourcemaps_for_d_ts_files_6614": + return Create_sourcemaps_for_d_ts_files + case "Output_compiler_performance_information_after_building_6615": + return Output_compiler_performance_information_after_building + case "Disables_inference_for_type_acquisition_by_looking_at_filenames_in_a_project_6616": + return Disables_inference_for_type_acquisition_by_looking_at_filenames_in_a_project + case "Reduce_the_number_of_projects_loaded_automatically_by_TypeScript_6617": + return Reduce_the_number_of_projects_loaded_automatically_by_TypeScript + case "Remove_the_20mb_cap_on_total_source_code_size_for_JavaScript_files_in_the_TypeScript_language_server_6618": + return Remove_the_20mb_cap_on_total_source_code_size_for_JavaScript_files_in_the_TypeScript_language_server + case "Opt_a_project_out_of_multi_project_reference_checking_when_editing_6619": + return Opt_a_project_out_of_multi_project_reference_checking_when_editing + case "Disable_preferring_source_files_instead_of_declaration_files_when_referencing_composite_projects_6620": + return Disable_preferring_source_files_instead_of_declaration_files_when_referencing_composite_projects + case "Emit_more_compliant_but_verbose_and_less_performant_JavaScript_for_iteration_6621": + return Emit_more_compliant_but_verbose_and_less_performant_JavaScript_for_iteration + case "Emit_a_UTF_8_Byte_Order_Mark_BOM_in_the_beginning_of_output_files_6622": + return Emit_a_UTF_8_Byte_Order_Mark_BOM_in_the_beginning_of_output_files + case "Only_output_d_ts_files_and_not_JavaScript_files_6623": + return Only_output_d_ts_files_and_not_JavaScript_files + case "Emit_design_type_metadata_for_decorated_declarations_in_source_files_6624": + return Emit_design_type_metadata_for_decorated_declarations_in_source_files + case "Disable_the_type_acquisition_for_JavaScript_projects_6625": + return Disable_the_type_acquisition_for_JavaScript_projects + case "Emit_additional_JavaScript_to_ease_support_for_importing_CommonJS_modules_This_enables_allowSyntheti_6626": + return Emit_additional_JavaScript_to_ease_support_for_importing_CommonJS_modules_This_enables_allowSyntheticDefaultImports_for_type_compatibility + case "Filters_results_from_the_include_option_6627": + return Filters_results_from_the_include_option + case "Remove_a_list_of_directories_from_the_watch_process_6628": + return Remove_a_list_of_directories_from_the_watch_process + case "Remove_a_list_of_files_from_the_watch_mode_s_processing_6629": + return Remove_a_list_of_files_from_the_watch_mode_s_processing + case "Enable_experimental_support_for_legacy_experimental_decorators_6630": + return Enable_experimental_support_for_legacy_experimental_decorators + case "Print_files_read_during_the_compilation_including_why_it_was_included_6631": + return Print_files_read_during_the_compilation_including_why_it_was_included + case "Output_more_detailed_compiler_performance_information_after_building_6632": + return Output_more_detailed_compiler_performance_information_after_building + case "Specify_one_or_more_path_or_node_module_references_to_base_configuration_files_from_which_settings_a_6633": + return Specify_one_or_more_path_or_node_module_references_to_base_configuration_files_from_which_settings_are_inherited + case "Specify_what_approach_the_watcher_should_use_if_the_system_runs_out_of_native_file_watchers_6634": + return Specify_what_approach_the_watcher_should_use_if_the_system_runs_out_of_native_file_watchers + case "Include_a_list_of_files_This_does_not_support_glob_patterns_as_opposed_to_include_6635": + return Include_a_list_of_files_This_does_not_support_glob_patterns_as_opposed_to_include + case "Build_all_projects_including_those_that_appear_to_be_up_to_date_6636": + return Build_all_projects_including_those_that_appear_to_be_up_to_date + case "Ensure_that_casing_is_correct_in_imports_6637": + return Ensure_that_casing_is_correct_in_imports + case "Emit_a_v8_CPU_profile_of_the_compiler_run_for_debugging_6638": + return Emit_a_v8_CPU_profile_of_the_compiler_run_for_debugging + case "Allow_importing_helper_functions_from_tslib_once_per_project_instead_of_including_them_per_file_6639": + return Allow_importing_helper_functions_from_tslib_once_per_project_instead_of_including_them_per_file + case "Skip_building_downstream_projects_on_error_in_upstream_project_6640": + return Skip_building_downstream_projects_on_error_in_upstream_project + case "Specify_a_list_of_glob_patterns_that_match_files_to_be_included_in_compilation_6641": + return Specify_a_list_of_glob_patterns_that_match_files_to_be_included_in_compilation + case "Save_tsbuildinfo_files_to_allow_for_incremental_compilation_of_projects_6642": + return Save_tsbuildinfo_files_to_allow_for_incremental_compilation_of_projects + case "Include_sourcemap_files_inside_the_emitted_JavaScript_6643": + return Include_sourcemap_files_inside_the_emitted_JavaScript + case "Include_source_code_in_the_sourcemaps_inside_the_emitted_JavaScript_6644": + return Include_source_code_in_the_sourcemaps_inside_the_emitted_JavaScript + case "Ensure_that_each_file_can_be_safely_transpiled_without_relying_on_other_imports_6645": + return Ensure_that_each_file_can_be_safely_transpiled_without_relying_on_other_imports + case "Specify_what_JSX_code_is_generated_6646": + return Specify_what_JSX_code_is_generated + case "Specify_the_JSX_factory_function_used_when_targeting_React_JSX_emit_e_g_React_createElement_or_h_6647": + return Specify_the_JSX_factory_function_used_when_targeting_React_JSX_emit_e_g_React_createElement_or_h + case "Specify_the_JSX_Fragment_reference_used_for_fragments_when_targeting_React_JSX_emit_e_g_React_Fragme_6648": + return Specify_the_JSX_Fragment_reference_used_for_fragments_when_targeting_React_JSX_emit_e_g_React_Fragment_or_Fragment + case "Specify_module_specifier_used_to_import_the_JSX_factory_functions_when_using_jsx_Colon_react_jsx_Ast_6649": + return Specify_module_specifier_used_to_import_the_JSX_factory_functions_when_using_jsx_Colon_react_jsx_Asterisk + case "Make_keyof_only_return_strings_instead_of_string_numbers_or_symbols_Legacy_option_6650": + return Make_keyof_only_return_strings_instead_of_string_numbers_or_symbols_Legacy_option + case "Specify_a_set_of_bundled_library_declaration_files_that_describe_the_target_runtime_environment_6651": + return Specify_a_set_of_bundled_library_declaration_files_that_describe_the_target_runtime_environment + case "Print_the_names_of_emitted_files_after_a_compilation_6652": + return Print_the_names_of_emitted_files_after_a_compilation + case "Print_all_of_the_files_read_during_the_compilation_6653": + return Print_all_of_the_files_read_during_the_compilation + case "Set_the_language_of_the_messaging_from_TypeScript_This_does_not_affect_emit_6654": + return Set_the_language_of_the_messaging_from_TypeScript_This_does_not_affect_emit + case "Specify_the_location_where_debugger_should_locate_map_files_instead_of_generated_locations_6655": + return Specify_the_location_where_debugger_should_locate_map_files_instead_of_generated_locations + case "Specify_the_maximum_folder_depth_used_for_checking_JavaScript_files_from_node_modules_Only_applicabl_6656": + return Specify_the_maximum_folder_depth_used_for_checking_JavaScript_files_from_node_modules_Only_applicable_with_allowJs + case "Specify_what_module_code_is_generated_6657": + return Specify_what_module_code_is_generated + case "Specify_how_TypeScript_looks_up_a_file_from_a_given_module_specifier_6658": + return Specify_how_TypeScript_looks_up_a_file_from_a_given_module_specifier + case "Set_the_newline_character_for_emitting_files_6659": + return Set_the_newline_character_for_emitting_files + case "Disable_emitting_files_from_a_compilation_6660": + return Disable_emitting_files_from_a_compilation + case "Disable_generating_custom_helper_functions_like_extends_in_compiled_output_6661": + return Disable_generating_custom_helper_functions_like_extends_in_compiled_output + case "Disable_emitting_files_if_any_type_checking_errors_are_reported_6662": + return Disable_emitting_files_if_any_type_checking_errors_are_reported + case "Disable_truncating_types_in_error_messages_6663": + return Disable_truncating_types_in_error_messages + case "Enable_error_reporting_for_fallthrough_cases_in_switch_statements_6664": + return Enable_error_reporting_for_fallthrough_cases_in_switch_statements + case "Enable_error_reporting_for_expressions_and_declarations_with_an_implied_any_type_6665": + return Enable_error_reporting_for_expressions_and_declarations_with_an_implied_any_type + case "Ensure_overriding_members_in_derived_classes_are_marked_with_an_override_modifier_6666": + return Ensure_overriding_members_in_derived_classes_are_marked_with_an_override_modifier + case "Enable_error_reporting_for_codepaths_that_do_not_explicitly_return_in_a_function_6667": + return Enable_error_reporting_for_codepaths_that_do_not_explicitly_return_in_a_function + case "Enable_error_reporting_when_this_is_given_the_type_any_6668": + return Enable_error_reporting_when_this_is_given_the_type_any + case "Disable_adding_use_strict_directives_in_emitted_JavaScript_files_6669": + return Disable_adding_use_strict_directives_in_emitted_JavaScript_files + case "Disable_including_any_library_files_including_the_default_lib_d_ts_6670": + return Disable_including_any_library_files_including_the_default_lib_d_ts + case "Enforces_using_indexed_accessors_for_keys_declared_using_an_indexed_type_6671": + return Enforces_using_indexed_accessors_for_keys_declared_using_an_indexed_type + case "Disallow_import_s_require_s_or_reference_s_from_expanding_the_number_of_files_TypeScript_should_add__6672": + return Disallow_import_s_require_s_or_reference_s_from_expanding_the_number_of_files_TypeScript_should_add_to_a_project + case "Disable_strict_checking_of_generic_signatures_in_function_types_6673": + return Disable_strict_checking_of_generic_signatures_in_function_types + case "Add_undefined_to_a_type_when_accessed_using_an_index_6674": + return Add_undefined_to_a_type_when_accessed_using_an_index + case "Enable_error_reporting_when_local_variables_aren_t_read_6675": + return Enable_error_reporting_when_local_variables_aren_t_read + case "Raise_an_error_when_a_function_parameter_isn_t_read_6676": + return Raise_an_error_when_a_function_parameter_isn_t_read + case "Deprecated_setting_Use_outFile_instead_6677": + return Deprecated_setting_Use_outFile_instead + case "Specify_an_output_folder_for_all_emitted_files_6678": + return Specify_an_output_folder_for_all_emitted_files + case "Specify_a_file_that_bundles_all_outputs_into_one_JavaScript_file_If_declaration_is_true_also_designa_6679": + return Specify_a_file_that_bundles_all_outputs_into_one_JavaScript_file_If_declaration_is_true_also_designates_a_file_that_bundles_all_d_ts_output + case "Specify_a_set_of_entries_that_re_map_imports_to_additional_lookup_locations_6680": + return Specify_a_set_of_entries_that_re_map_imports_to_additional_lookup_locations + case "Specify_a_list_of_language_service_plugins_to_include_6681": + return Specify_a_list_of_language_service_plugins_to_include + case "Disable_erasing_const_enum_declarations_in_generated_code_6682": + return Disable_erasing_const_enum_declarations_in_generated_code + case "Disable_resolving_symlinks_to_their_realpath_This_correlates_to_the_same_flag_in_node_6683": + return Disable_resolving_symlinks_to_their_realpath_This_correlates_to_the_same_flag_in_node + case "Disable_wiping_the_console_in_watch_mode_6684": + return Disable_wiping_the_console_in_watch_mode + case "Enable_color_and_formatting_in_TypeScript_s_output_to_make_compiler_errors_easier_to_read_6685": + return Enable_color_and_formatting_in_TypeScript_s_output_to_make_compiler_errors_easier_to_read + case "Specify_the_object_invoked_for_createElement_This_only_applies_when_targeting_react_JSX_emit_6686": + return Specify_the_object_invoked_for_createElement_This_only_applies_when_targeting_react_JSX_emit + case "Specify_an_array_of_objects_that_specify_paths_for_projects_Used_in_project_references_6687": + return Specify_an_array_of_objects_that_specify_paths_for_projects_Used_in_project_references + case "Disable_emitting_comments_6688": + return Disable_emitting_comments + case "Enable_importing_json_files_6689": + return Enable_importing_json_files + case "Specify_the_root_folder_within_your_source_files_6690": + return Specify_the_root_folder_within_your_source_files + case "Allow_multiple_folders_to_be_treated_as_one_when_resolving_modules_6691": + return Allow_multiple_folders_to_be_treated_as_one_when_resolving_modules + case "Skip_type_checking_d_ts_files_that_are_included_with_TypeScript_6692": + return Skip_type_checking_d_ts_files_that_are_included_with_TypeScript + case "Skip_type_checking_all_d_ts_files_6693": + return Skip_type_checking_all_d_ts_files + case "Create_source_map_files_for_emitted_JavaScript_files_6694": + return Create_source_map_files_for_emitted_JavaScript_files + case "Specify_the_root_path_for_debuggers_to_find_the_reference_source_code_6695": + return Specify_the_root_path_for_debuggers_to_find_the_reference_source_code + case "Check_that_the_arguments_for_bind_call_and_apply_methods_match_the_original_function_6697": + return Check_that_the_arguments_for_bind_call_and_apply_methods_match_the_original_function + case "When_assigning_functions_check_to_ensure_parameters_and_the_return_values_are_subtype_compatible_6698": + return When_assigning_functions_check_to_ensure_parameters_and_the_return_values_are_subtype_compatible + case "When_type_checking_take_into_account_null_and_undefined_6699": + return When_type_checking_take_into_account_null_and_undefined + case "Check_for_class_properties_that_are_declared_but_not_set_in_the_constructor_6700": + return Check_for_class_properties_that_are_declared_but_not_set_in_the_constructor + case "Disable_emitting_declarations_that_have_internal_in_their_JSDoc_comments_6701": + return Disable_emitting_declarations_that_have_internal_in_their_JSDoc_comments + case "Disable_reporting_of_excess_property_errors_during_the_creation_of_object_literals_6702": + return Disable_reporting_of_excess_property_errors_during_the_creation_of_object_literals + case "Suppress_noImplicitAny_errors_when_indexing_objects_that_lack_index_signatures_6703": + return Suppress_noImplicitAny_errors_when_indexing_objects_that_lack_index_signatures + case "Synchronously_call_callbacks_and_update_the_state_of_directory_watchers_on_platforms_that_don_t_supp_6704": + return Synchronously_call_callbacks_and_update_the_state_of_directory_watchers_on_platforms_that_don_t_support_recursive_watching_natively + case "Set_the_JavaScript_language_version_for_emitted_JavaScript_and_include_compatible_library_declaratio_6705": + return Set_the_JavaScript_language_version_for_emitted_JavaScript_and_include_compatible_library_declarations + case "Log_paths_used_during_the_moduleResolution_process_6706": + return Log_paths_used_during_the_moduleResolution_process + case "Specify_the_path_to_tsbuildinfo_incremental_compilation_file_6707": + return Specify_the_path_to_tsbuildinfo_incremental_compilation_file + case "Specify_options_for_automatic_acquisition_of_declaration_files_6709": + return Specify_options_for_automatic_acquisition_of_declaration_files + case "Specify_multiple_folders_that_act_like_Slashnode_modules_Slash_types_6710": + return Specify_multiple_folders_that_act_like_Slashnode_modules_Slash_types + case "Specify_type_package_names_to_be_included_without_being_referenced_in_a_source_file_6711": + return Specify_type_package_names_to_be_included_without_being_referenced_in_a_source_file + case "Emit_ECMAScript_standard_compliant_class_fields_6712": + return Emit_ECMAScript_standard_compliant_class_fields + case "Enable_verbose_logging_6713": + return Enable_verbose_logging + case "Specify_how_directories_are_watched_on_systems_that_lack_recursive_file_watching_functionality_6714": + return Specify_how_directories_are_watched_on_systems_that_lack_recursive_file_watching_functionality + case "Specify_how_the_TypeScript_watch_mode_works_6715": + return Specify_how_the_TypeScript_watch_mode_works + case "Require_undeclared_properties_from_index_signatures_to_use_element_accesses_6717": + return Require_undeclared_properties_from_index_signatures_to_use_element_accesses + case "Specify_emit_Slashchecking_behavior_for_imports_that_are_only_used_for_types_6718": + return Specify_emit_Slashchecking_behavior_for_imports_that_are_only_used_for_types + case "Require_sufficient_annotation_on_exports_so_other_tools_can_trivially_generate_declaration_files_6719": + return Require_sufficient_annotation_on_exports_so_other_tools_can_trivially_generate_declaration_files + case "Built_in_iterators_are_instantiated_with_a_TReturn_type_of_undefined_instead_of_any_6720": + return Built_in_iterators_are_instantiated_with_a_TReturn_type_of_undefined_instead_of_any + case "Do_not_allow_runtime_constructs_that_are_not_part_of_ECMAScript_6721": + return Do_not_allow_runtime_constructs_that_are_not_part_of_ECMAScript + case "Default_catch_clause_variables_as_unknown_instead_of_any_6803": + return Default_catch_clause_variables_as_unknown_instead_of_any + case "Do_not_transform_or_elide_any_imports_or_exports_not_marked_as_type_only_ensuring_they_are_written_i_6804": + return Do_not_transform_or_elide_any_imports_or_exports_not_marked_as_type_only_ensuring_they_are_written_in_the_output_file_s_format_based_on_the_module_setting + case "Disable_full_type_checking_only_critical_parse_and_emit_errors_will_be_reported_6805": + return Disable_full_type_checking_only_critical_parse_and_emit_errors_will_be_reported + case "Check_side_effect_imports_6806": + return Check_side_effect_imports + case "This_operation_can_be_simplified_This_shift_is_identical_to_0_1_2_6807": + return This_operation_can_be_simplified_This_shift_is_identical_to_0_1_2 + case "Enable_lib_replacement_6808": + return Enable_lib_replacement + case "one_of_Colon_6900": + return X_one_of_Colon + case "one_or_more_Colon_6901": + return X_one_or_more_Colon + case "type_Colon_6902": + return X_type_Colon + case "default_Colon_6903": + return X_default_Colon + case "module_system_or_esModuleInterop_6904": + return X_module_system_or_esModuleInterop + case "false_unless_strict_is_set_6905": + return X_false_unless_strict_is_set + case "false_unless_composite_is_set_6906": + return X_false_unless_composite_is_set + case "node_modules_bower_components_jspm_packages_plus_the_value_of_outDir_if_one_is_specified_6907": + return X_node_modules_bower_components_jspm_packages_plus_the_value_of_outDir_if_one_is_specified + case "if_files_is_specified_otherwise_Asterisk_Asterisk_Slash_Asterisk_6908": + return X_if_files_is_specified_otherwise_Asterisk_Asterisk_Slash_Asterisk + case "true_if_composite_false_otherwise_6909": + return X_true_if_composite_false_otherwise + case "Computed_from_the_list_of_input_files_6911": + return Computed_from_the_list_of_input_files + case "Platform_specific_6912": + return Platform_specific + case "You_can_learn_about_all_of_the_compiler_options_at_0_6913": + return You_can_learn_about_all_of_the_compiler_options_at_0 + case "Including_watch_w_will_start_watching_the_current_project_for_the_file_changes_Once_set_you_can_conf_6914": + return Including_watch_w_will_start_watching_the_current_project_for_the_file_changes_Once_set_you_can_config_watch_mode_with_Colon + case "Using_build_b_will_make_tsc_behave_more_like_a_build_orchestrator_than_a_compiler_This_is_used_to_tr_6915": + return Using_build_b_will_make_tsc_behave_more_like_a_build_orchestrator_than_a_compiler_This_is_used_to_trigger_building_composite_projects_which_you_can_learn_more_about_at_0 + case "COMMON_COMMANDS_6916": + return COMMON_COMMANDS + case "ALL_COMPILER_OPTIONS_6917": + return ALL_COMPILER_OPTIONS + case "WATCH_OPTIONS_6918": + return WATCH_OPTIONS + case "BUILD_OPTIONS_6919": + return BUILD_OPTIONS + case "COMMON_COMPILER_OPTIONS_6920": + return COMMON_COMPILER_OPTIONS + case "COMMAND_LINE_FLAGS_6921": + return COMMAND_LINE_FLAGS + case "tsc_Colon_The_TypeScript_Compiler_6922": + return X_tsc_Colon_The_TypeScript_Compiler + case "Compiles_the_current_project_tsconfig_json_in_the_working_directory_6923": + return Compiles_the_current_project_tsconfig_json_in_the_working_directory + case "Ignoring_tsconfig_json_compiles_the_specified_files_with_default_compiler_options_6924": + return Ignoring_tsconfig_json_compiles_the_specified_files_with_default_compiler_options + case "Build_a_composite_project_in_the_working_directory_6925": + return Build_a_composite_project_in_the_working_directory + case "Creates_a_tsconfig_json_with_the_recommended_settings_in_the_working_directory_6926": + return Creates_a_tsconfig_json_with_the_recommended_settings_in_the_working_directory + case "Compiles_the_TypeScript_project_located_at_the_specified_path_6927": + return Compiles_the_TypeScript_project_located_at_the_specified_path + case "An_expanded_version_of_this_information_showing_all_possible_compiler_options_6928": + return An_expanded_version_of_this_information_showing_all_possible_compiler_options + case "Compiles_the_current_project_with_additional_settings_6929": + return Compiles_the_current_project_with_additional_settings + case "true_for_ES2022_and_above_including_ESNext_6930": + return X_true_for_ES2022_and_above_including_ESNext + case "List_of_file_name_suffixes_to_search_when_resolving_a_module_6931": + return List_of_file_name_suffixes_to_search_when_resolving_a_module + case "Variable_0_implicitly_has_an_1_type_7005": + return Variable_0_implicitly_has_an_1_type + case "Parameter_0_implicitly_has_an_1_type_7006": + return Parameter_0_implicitly_has_an_1_type + case "Member_0_implicitly_has_an_1_type_7008": + return Member_0_implicitly_has_an_1_type + case "new_expression_whose_target_lacks_a_construct_signature_implicitly_has_an_any_type_7009": + return X_new_expression_whose_target_lacks_a_construct_signature_implicitly_has_an_any_type + case "_0_which_lacks_return_type_annotation_implicitly_has_an_1_return_type_7010": + return X_0_which_lacks_return_type_annotation_implicitly_has_an_1_return_type + case "Function_expression_which_lacks_return_type_annotation_implicitly_has_an_0_return_type_7011": + return Function_expression_which_lacks_return_type_annotation_implicitly_has_an_0_return_type + case "This_overload_implicitly_returns_the_type_0_because_it_lacks_a_return_type_annotation_7012": + return This_overload_implicitly_returns_the_type_0_because_it_lacks_a_return_type_annotation + case "Construct_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type_7013": + return Construct_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type + case "Function_type_which_lacks_return_type_annotation_implicitly_has_an_0_return_type_7014": + return Function_type_which_lacks_return_type_annotation_implicitly_has_an_0_return_type + case "Element_implicitly_has_an_any_type_because_index_expression_is_not_of_type_number_7015": + return Element_implicitly_has_an_any_type_because_index_expression_is_not_of_type_number + case "Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016": + return Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type + case "Element_implicitly_has_an_any_type_because_type_0_has_no_index_signature_7017": + return Element_implicitly_has_an_any_type_because_type_0_has_no_index_signature + case "Object_literal_s_property_0_implicitly_has_an_1_type_7018": + return Object_literal_s_property_0_implicitly_has_an_1_type + case "Rest_parameter_0_implicitly_has_an_any_type_7019": + return Rest_parameter_0_implicitly_has_an_any_type + case "Call_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type_7020": + return Call_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type + case "_0_implicitly_has_type_any_because_it_does_not_have_a_type_annotation_and_is_referenced_directly_or__7022": + return X_0_implicitly_has_type_any_because_it_does_not_have_a_type_annotation_and_is_referenced_directly_or_indirectly_in_its_own_initializer + case "_0_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_reference_7023": + return X_0_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_referenced_directly_or_indirectly_in_one_of_its_return_expressions + case "Function_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_ref_7024": + return Function_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_referenced_directly_or_indirectly_in_one_of_its_return_expressions + case "Generator_implicitly_has_yield_type_0_Consider_supplying_a_return_type_annotation_7025": + return Generator_implicitly_has_yield_type_0_Consider_supplying_a_return_type_annotation + case "JSX_element_implicitly_has_type_any_because_no_interface_JSX_0_exists_7026": + return JSX_element_implicitly_has_type_any_because_no_interface_JSX_0_exists + case "Unreachable_code_detected_7027": + return Unreachable_code_detected + case "Unused_label_7028": + return Unused_label + case "Fallthrough_case_in_switch_7029": + return Fallthrough_case_in_switch + case "Not_all_code_paths_return_a_value_7030": + return Not_all_code_paths_return_a_value + case "Binding_element_0_implicitly_has_an_1_type_7031": + return Binding_element_0_implicitly_has_an_1_type + case "Property_0_implicitly_has_type_any_because_its_set_accessor_lacks_a_parameter_type_annotation_7032": + return Property_0_implicitly_has_type_any_because_its_set_accessor_lacks_a_parameter_type_annotation + case "Property_0_implicitly_has_type_any_because_its_get_accessor_lacks_a_return_type_annotation_7033": + return Property_0_implicitly_has_type_any_because_its_get_accessor_lacks_a_return_type_annotation + case "Variable_0_implicitly_has_type_1_in_some_locations_where_its_type_cannot_be_determined_7034": + return Variable_0_implicitly_has_type_1_in_some_locations_where_its_type_cannot_be_determined + case "Try_npm_i_save_dev_types_Slash_1_if_it_exists_or_add_a_new_declaration_d_ts_file_containing_declare__7035": + return Try_npm_i_save_dev_types_Slash_1_if_it_exists_or_add_a_new_declaration_d_ts_file_containing_declare_module_0 + case "Dynamic_import_s_specifier_must_be_of_type_string_but_here_has_type_0_7036": + return Dynamic_import_s_specifier_must_be_of_type_string_but_here_has_type_0 + case "Enables_emit_interoperability_between_CommonJS_and_ES_Modules_via_creation_of_namespace_objects_for__7037": + return Enables_emit_interoperability_between_CommonJS_and_ES_Modules_via_creation_of_namespace_objects_for_all_imports_Implies_allowSyntheticDefaultImports + case "Type_originates_at_this_import_A_namespace_style_import_cannot_be_called_or_constructed_and_will_cau_7038": + return Type_originates_at_this_import_A_namespace_style_import_cannot_be_called_or_constructed_and_will_cause_a_failure_at_runtime_Consider_using_a_default_import_or_import_require_here_instead + case "Mapped_object_type_implicitly_has_an_any_template_type_7039": + return Mapped_object_type_implicitly_has_an_any_template_type + case "If_the_0_package_actually_exposes_this_module_consider_sending_a_pull_request_to_amend_https_Colon_S_7040": + return If_the_0_package_actually_exposes_this_module_consider_sending_a_pull_request_to_amend_https_Colon_Slash_Slashgithub_com_SlashDefinitelyTyped_SlashDefinitelyTyped_Slashtree_Slashmaster_Slashtypes_Slash_1 + case "The_containing_arrow_function_captures_the_global_value_of_this_7041": + return The_containing_arrow_function_captures_the_global_value_of_this + case "Module_0_was_resolved_to_1_but_resolveJsonModule_is_not_used_7042": + return Module_0_was_resolved_to_1_but_resolveJsonModule_is_not_used + case "Variable_0_implicitly_has_an_1_type_but_a_better_type_may_be_inferred_from_usage_7043": + return Variable_0_implicitly_has_an_1_type_but_a_better_type_may_be_inferred_from_usage + case "Parameter_0_implicitly_has_an_1_type_but_a_better_type_may_be_inferred_from_usage_7044": + return Parameter_0_implicitly_has_an_1_type_but_a_better_type_may_be_inferred_from_usage + case "Member_0_implicitly_has_an_1_type_but_a_better_type_may_be_inferred_from_usage_7045": + return Member_0_implicitly_has_an_1_type_but_a_better_type_may_be_inferred_from_usage + case "Variable_0_implicitly_has_type_1_in_some_locations_but_a_better_type_may_be_inferred_from_usage_7046": + return Variable_0_implicitly_has_type_1_in_some_locations_but_a_better_type_may_be_inferred_from_usage + case "Rest_parameter_0_implicitly_has_an_any_type_but_a_better_type_may_be_inferred_from_usage_7047": + return Rest_parameter_0_implicitly_has_an_any_type_but_a_better_type_may_be_inferred_from_usage + case "Property_0_implicitly_has_type_any_but_a_better_type_for_its_get_accessor_may_be_inferred_from_usage_7048": + return Property_0_implicitly_has_type_any_but_a_better_type_for_its_get_accessor_may_be_inferred_from_usage + case "Property_0_implicitly_has_type_any_but_a_better_type_for_its_set_accessor_may_be_inferred_from_usage_7049": + return Property_0_implicitly_has_type_any_but_a_better_type_for_its_set_accessor_may_be_inferred_from_usage + case "_0_implicitly_has_an_1_return_type_but_a_better_type_may_be_inferred_from_usage_7050": + return X_0_implicitly_has_an_1_return_type_but_a_better_type_may_be_inferred_from_usage + case "Parameter_has_a_name_but_no_type_Did_you_mean_0_Colon_1_7051": + return Parameter_has_a_name_but_no_type_Did_you_mean_0_Colon_1 + case "Element_implicitly_has_an_any_type_because_type_0_has_no_index_signature_Did_you_mean_to_call_1_7052": + return Element_implicitly_has_an_any_type_because_type_0_has_no_index_signature_Did_you_mean_to_call_1 + case "Element_implicitly_has_an_any_type_because_expression_of_type_0_can_t_be_used_to_index_type_1_7053": + return Element_implicitly_has_an_any_type_because_expression_of_type_0_can_t_be_used_to_index_type_1 + case "No_index_signature_with_a_parameter_of_type_0_was_found_on_type_1_7054": + return No_index_signature_with_a_parameter_of_type_0_was_found_on_type_1 + case "_0_which_lacks_return_type_annotation_implicitly_has_an_1_yield_type_7055": + return X_0_which_lacks_return_type_annotation_implicitly_has_an_1_yield_type + case "The_inferred_type_of_this_node_exceeds_the_maximum_length_the_compiler_will_serialize_An_explicit_ty_7056": + return The_inferred_type_of_this_node_exceeds_the_maximum_length_the_compiler_will_serialize_An_explicit_type_annotation_is_needed + case "yield_expression_implicitly_results_in_an_any_type_because_its_containing_generator_lacks_a_return_t_7057": + return X_yield_expression_implicitly_results_in_an_any_type_because_its_containing_generator_lacks_a_return_type_annotation + case "If_the_0_package_actually_exposes_this_module_try_adding_a_new_declaration_d_ts_file_containing_decl_7058": + return If_the_0_package_actually_exposes_this_module_try_adding_a_new_declaration_d_ts_file_containing_declare_module_1 + case "This_syntax_is_reserved_in_files_with_the_mts_or_cts_extension_Use_an_as_expression_instead_7059": + return This_syntax_is_reserved_in_files_with_the_mts_or_cts_extension_Use_an_as_expression_instead + case "This_syntax_is_reserved_in_files_with_the_mts_or_cts_extension_Add_a_trailing_comma_or_explicit_cons_7060": + return This_syntax_is_reserved_in_files_with_the_mts_or_cts_extension_Add_a_trailing_comma_or_explicit_constraint + case "A_mapped_type_may_not_declare_properties_or_methods_7061": + return A_mapped_type_may_not_declare_properties_or_methods + case "You_cannot_rename_this_element_8000": + return You_cannot_rename_this_element + case "You_cannot_rename_elements_that_are_defined_in_the_standard_TypeScript_library_8001": + return You_cannot_rename_elements_that_are_defined_in_the_standard_TypeScript_library + case "import_can_only_be_used_in_TypeScript_files_8002": + return X_import_can_only_be_used_in_TypeScript_files + case "export_can_only_be_used_in_TypeScript_files_8003": + return X_export_can_only_be_used_in_TypeScript_files + case "Type_parameter_declarations_can_only_be_used_in_TypeScript_files_8004": + return Type_parameter_declarations_can_only_be_used_in_TypeScript_files + case "implements_clauses_can_only_be_used_in_TypeScript_files_8005": + return X_implements_clauses_can_only_be_used_in_TypeScript_files + case "_0_declarations_can_only_be_used_in_TypeScript_files_8006": + return X_0_declarations_can_only_be_used_in_TypeScript_files + case "Type_aliases_can_only_be_used_in_TypeScript_files_8008": + return Type_aliases_can_only_be_used_in_TypeScript_files + case "The_0_modifier_can_only_be_used_in_TypeScript_files_8009": + return The_0_modifier_can_only_be_used_in_TypeScript_files + case "Type_annotations_can_only_be_used_in_TypeScript_files_8010": + return Type_annotations_can_only_be_used_in_TypeScript_files + case "Type_arguments_can_only_be_used_in_TypeScript_files_8011": + return Type_arguments_can_only_be_used_in_TypeScript_files + case "Parameter_modifiers_can_only_be_used_in_TypeScript_files_8012": + return Parameter_modifiers_can_only_be_used_in_TypeScript_files + case "Non_null_assertions_can_only_be_used_in_TypeScript_files_8013": + return Non_null_assertions_can_only_be_used_in_TypeScript_files + case "Type_assertion_expressions_can_only_be_used_in_TypeScript_files_8016": + return Type_assertion_expressions_can_only_be_used_in_TypeScript_files + case "Signature_declarations_can_only_be_used_in_TypeScript_files_8017": + return Signature_declarations_can_only_be_used_in_TypeScript_files + case "Report_errors_in_js_files_8019": + return Report_errors_in_js_files + case "JSDoc_types_can_only_be_used_inside_documentation_comments_8020": + return JSDoc_types_can_only_be_used_inside_documentation_comments + case "JSDoc_typedef_tag_should_either_have_a_type_annotation_or_be_followed_by_property_or_member_tags_8021": + return JSDoc_typedef_tag_should_either_have_a_type_annotation_or_be_followed_by_property_or_member_tags + case "JSDoc_0_is_not_attached_to_a_class_8022": + return JSDoc_0_is_not_attached_to_a_class + case "JSDoc_0_1_does_not_match_the_extends_2_clause_8023": + return JSDoc_0_1_does_not_match_the_extends_2_clause + case "JSDoc_param_tag_has_name_0_but_there_is_no_parameter_with_that_name_8024": + return JSDoc_param_tag_has_name_0_but_there_is_no_parameter_with_that_name + case "Class_declarations_cannot_have_more_than_one_augments_or_extends_tag_8025": + return Class_declarations_cannot_have_more_than_one_augments_or_extends_tag + case "Expected_0_type_arguments_provide_these_with_an_extends_tag_8026": + return Expected_0_type_arguments_provide_these_with_an_extends_tag + case "Expected_0_1_type_arguments_provide_these_with_an_extends_tag_8027": + return Expected_0_1_type_arguments_provide_these_with_an_extends_tag + case "JSDoc_may_only_appear_in_the_last_parameter_of_a_signature_8028": + return JSDoc_may_only_appear_in_the_last_parameter_of_a_signature + case "JSDoc_param_tag_has_name_0_but_there_is_no_parameter_with_that_name_It_would_match_arguments_if_it_h_8029": + return JSDoc_param_tag_has_name_0_but_there_is_no_parameter_with_that_name_It_would_match_arguments_if_it_had_an_array_type + case "A_JSDoc_type_tag_on_a_function_must_have_a_signature_with_the_correct_number_of_arguments_8030": + return A_JSDoc_type_tag_on_a_function_must_have_a_signature_with_the_correct_number_of_arguments + case "You_cannot_rename_a_module_via_a_global_import_8031": + return You_cannot_rename_a_module_via_a_global_import + case "Qualified_name_0_is_not_allowed_without_a_leading_param_object_1_8032": + return Qualified_name_0_is_not_allowed_without_a_leading_param_object_1 + case "A_JSDoc_typedef_comment_may_not_contain_multiple_type_tags_8033": + return A_JSDoc_typedef_comment_may_not_contain_multiple_type_tags + case "The_tag_was_first_specified_here_8034": + return The_tag_was_first_specified_here + case "You_cannot_rename_elements_that_are_defined_in_a_node_modules_folder_8035": + return You_cannot_rename_elements_that_are_defined_in_a_node_modules_folder + case "You_cannot_rename_elements_that_are_defined_in_another_node_modules_folder_8036": + return You_cannot_rename_elements_that_are_defined_in_another_node_modules_folder + case "Type_satisfaction_expressions_can_only_be_used_in_TypeScript_files_8037": + return Type_satisfaction_expressions_can_only_be_used_in_TypeScript_files + case "Decorators_may_not_appear_after_export_or_export_default_if_they_also_appear_before_export_8038": + return Decorators_may_not_appear_after_export_or_export_default_if_they_also_appear_before_export + case "A_JSDoc_template_tag_may_not_follow_a_typedef_callback_or_overload_tag_8039": + return A_JSDoc_template_tag_may_not_follow_a_typedef_callback_or_overload_tag + case "Declaration_emit_for_this_file_requires_using_private_name_0_An_explicit_type_annotation_may_unblock_9005": + return Declaration_emit_for_this_file_requires_using_private_name_0_An_explicit_type_annotation_may_unblock_declaration_emit + case "Declaration_emit_for_this_file_requires_using_private_name_0_from_module_1_An_explicit_type_annotati_9006": + return Declaration_emit_for_this_file_requires_using_private_name_0_from_module_1_An_explicit_type_annotation_may_unblock_declaration_emit + case "Function_must_have_an_explicit_return_type_annotation_with_isolatedDeclarations_9007": + return Function_must_have_an_explicit_return_type_annotation_with_isolatedDeclarations + case "Method_must_have_an_explicit_return_type_annotation_with_isolatedDeclarations_9008": + return Method_must_have_an_explicit_return_type_annotation_with_isolatedDeclarations + case "At_least_one_accessor_must_have_an_explicit_type_annotation_with_isolatedDeclarations_9009": + return At_least_one_accessor_must_have_an_explicit_type_annotation_with_isolatedDeclarations + case "Variable_must_have_an_explicit_type_annotation_with_isolatedDeclarations_9010": + return Variable_must_have_an_explicit_type_annotation_with_isolatedDeclarations + case "Parameter_must_have_an_explicit_type_annotation_with_isolatedDeclarations_9011": + return Parameter_must_have_an_explicit_type_annotation_with_isolatedDeclarations + case "Property_must_have_an_explicit_type_annotation_with_isolatedDeclarations_9012": + return Property_must_have_an_explicit_type_annotation_with_isolatedDeclarations + case "Expression_type_can_t_be_inferred_with_isolatedDeclarations_9013": + return Expression_type_can_t_be_inferred_with_isolatedDeclarations + case "Computed_properties_must_be_number_or_string_literals_variables_or_dotted_expressions_with_isolatedD_9014": + return Computed_properties_must_be_number_or_string_literals_variables_or_dotted_expressions_with_isolatedDeclarations + case "Objects_that_contain_spread_assignments_can_t_be_inferred_with_isolatedDeclarations_9015": + return Objects_that_contain_spread_assignments_can_t_be_inferred_with_isolatedDeclarations + case "Objects_that_contain_shorthand_properties_can_t_be_inferred_with_isolatedDeclarations_9016": + return Objects_that_contain_shorthand_properties_can_t_be_inferred_with_isolatedDeclarations + case "Only_const_arrays_can_be_inferred_with_isolatedDeclarations_9017": + return Only_const_arrays_can_be_inferred_with_isolatedDeclarations + case "Arrays_with_spread_elements_can_t_inferred_with_isolatedDeclarations_9018": + return Arrays_with_spread_elements_can_t_inferred_with_isolatedDeclarations + case "Binding_elements_can_t_be_exported_directly_with_isolatedDeclarations_9019": + return Binding_elements_can_t_be_exported_directly_with_isolatedDeclarations + case "Enum_member_initializers_must_be_computable_without_references_to_external_symbols_with_isolatedDecl_9020": + return Enum_member_initializers_must_be_computable_without_references_to_external_symbols_with_isolatedDeclarations + case "Extends_clause_can_t_contain_an_expression_with_isolatedDeclarations_9021": + return Extends_clause_can_t_contain_an_expression_with_isolatedDeclarations + case "Inference_from_class_expressions_is_not_supported_with_isolatedDeclarations_9022": + return Inference_from_class_expressions_is_not_supported_with_isolatedDeclarations + case "Assigning_properties_to_functions_without_declaring_them_is_not_supported_with_isolatedDeclarations__9023": + return Assigning_properties_to_functions_without_declaring_them_is_not_supported_with_isolatedDeclarations_Add_an_explicit_declaration_for_the_properties_assigned_to_this_function + case "Declaration_emit_for_this_parameter_requires_implicitly_adding_undefined_to_its_type_This_is_not_sup_9025": + return Declaration_emit_for_this_parameter_requires_implicitly_adding_undefined_to_its_type_This_is_not_supported_with_isolatedDeclarations + case "Declaration_emit_for_this_file_requires_preserving_this_import_for_augmentations_This_is_not_support_9026": + return Declaration_emit_for_this_file_requires_preserving_this_import_for_augmentations_This_is_not_supported_with_isolatedDeclarations + case "Add_a_type_annotation_to_the_variable_0_9027": + return Add_a_type_annotation_to_the_variable_0 + case "Add_a_type_annotation_to_the_parameter_0_9028": + return Add_a_type_annotation_to_the_parameter_0 + case "Add_a_type_annotation_to_the_property_0_9029": + return Add_a_type_annotation_to_the_property_0 + case "Add_a_return_type_to_the_function_expression_9030": + return Add_a_return_type_to_the_function_expression + case "Add_a_return_type_to_the_function_declaration_9031": + return Add_a_return_type_to_the_function_declaration + case "Add_a_return_type_to_the_get_accessor_declaration_9032": + return Add_a_return_type_to_the_get_accessor_declaration + case "Add_a_type_to_parameter_of_the_set_accessor_declaration_9033": + return Add_a_type_to_parameter_of_the_set_accessor_declaration + case "Add_a_return_type_to_the_method_9034": + return Add_a_return_type_to_the_method + case "Add_satisfies_and_a_type_assertion_to_this_expression_satisfies_T_as_T_to_make_the_type_explicit_9035": + return Add_satisfies_and_a_type_assertion_to_this_expression_satisfies_T_as_T_to_make_the_type_explicit + case "Move_the_expression_in_default_export_to_a_variable_and_add_a_type_annotation_to_it_9036": + return Move_the_expression_in_default_export_to_a_variable_and_add_a_type_annotation_to_it + case "Default_exports_can_t_be_inferred_with_isolatedDeclarations_9037": + return Default_exports_can_t_be_inferred_with_isolatedDeclarations + case "Computed_property_names_on_class_or_object_literals_cannot_be_inferred_with_isolatedDeclarations_9038": + return Computed_property_names_on_class_or_object_literals_cannot_be_inferred_with_isolatedDeclarations + case "Type_containing_private_name_0_can_t_be_used_with_isolatedDeclarations_9039": + return Type_containing_private_name_0_can_t_be_used_with_isolatedDeclarations + case "JSX_attributes_must_only_be_assigned_a_non_empty_expression_17000": + return JSX_attributes_must_only_be_assigned_a_non_empty_expression + case "JSX_elements_cannot_have_multiple_attributes_with_the_same_name_17001": + return JSX_elements_cannot_have_multiple_attributes_with_the_same_name + case "Expected_corresponding_JSX_closing_tag_for_0_17002": + return Expected_corresponding_JSX_closing_tag_for_0 + case "Cannot_use_JSX_unless_the_jsx_flag_is_provided_17004": + return Cannot_use_JSX_unless_the_jsx_flag_is_provided + case "A_constructor_cannot_contain_a_super_call_when_its_class_extends_null_17005": + return A_constructor_cannot_contain_a_super_call_when_its_class_extends_null + case "An_unary_expression_with_the_0_operator_is_not_allowed_in_the_left_hand_side_of_an_exponentiation_ex_17006": + return An_unary_expression_with_the_0_operator_is_not_allowed_in_the_left_hand_side_of_an_exponentiation_expression_Consider_enclosing_the_expression_in_parentheses + case "A_type_assertion_expression_is_not_allowed_in_the_left_hand_side_of_an_exponentiation_expression_Con_17007": + return A_type_assertion_expression_is_not_allowed_in_the_left_hand_side_of_an_exponentiation_expression_Consider_enclosing_the_expression_in_parentheses + case "JSX_element_0_has_no_corresponding_closing_tag_17008": + return JSX_element_0_has_no_corresponding_closing_tag + case "super_must_be_called_before_accessing_this_in_the_constructor_of_a_derived_class_17009": + return X_super_must_be_called_before_accessing_this_in_the_constructor_of_a_derived_class + case "Unknown_type_acquisition_option_0_17010": + return Unknown_type_acquisition_option_0 + case "super_must_be_called_before_accessing_a_property_of_super_in_the_constructor_of_a_derived_class_17011": + return X_super_must_be_called_before_accessing_a_property_of_super_in_the_constructor_of_a_derived_class + case "_0_is_not_a_valid_meta_property_for_keyword_1_Did_you_mean_2_17012": + return X_0_is_not_a_valid_meta_property_for_keyword_1_Did_you_mean_2 + case "Meta_property_0_is_only_allowed_in_the_body_of_a_function_declaration_function_expression_or_constru_17013": + return Meta_property_0_is_only_allowed_in_the_body_of_a_function_declaration_function_expression_or_constructor + case "JSX_fragment_has_no_corresponding_closing_tag_17014": + return JSX_fragment_has_no_corresponding_closing_tag + case "Expected_corresponding_closing_tag_for_JSX_fragment_17015": + return Expected_corresponding_closing_tag_for_JSX_fragment + case "The_jsxFragmentFactory_compiler_option_must_be_provided_to_use_JSX_fragments_with_the_jsxFactory_com_17016": + return The_jsxFragmentFactory_compiler_option_must_be_provided_to_use_JSX_fragments_with_the_jsxFactory_compiler_option + case "An_jsxFrag_pragma_is_required_when_using_an_jsx_pragma_with_JSX_fragments_17017": + return An_jsxFrag_pragma_is_required_when_using_an_jsx_pragma_with_JSX_fragments + case "Unknown_type_acquisition_option_0_Did_you_mean_1_17018": + return Unknown_type_acquisition_option_0_Did_you_mean_1 + case "_0_at_the_end_of_a_type_is_not_valid_TypeScript_syntax_Did_you_mean_to_write_1_17019": + return X_0_at_the_end_of_a_type_is_not_valid_TypeScript_syntax_Did_you_mean_to_write_1 + case "_0_at_the_start_of_a_type_is_not_valid_TypeScript_syntax_Did_you_mean_to_write_1_17020": + return X_0_at_the_start_of_a_type_is_not_valid_TypeScript_syntax_Did_you_mean_to_write_1 + case "Unicode_escape_sequence_cannot_appear_here_17021": + return Unicode_escape_sequence_cannot_appear_here + case "Circularity_detected_while_resolving_configuration_Colon_0_18000": + return Circularity_detected_while_resolving_configuration_Colon_0 + case "The_files_list_in_config_file_0_is_empty_18002": + return The_files_list_in_config_file_0_is_empty + case "No_inputs_were_found_in_config_file_0_Specified_include_paths_were_1_and_exclude_paths_were_2_18003": + return No_inputs_were_found_in_config_file_0_Specified_include_paths_were_1_and_exclude_paths_were_2 + case "No_value_exists_in_scope_for_the_shorthand_property_0_Either_declare_one_or_provide_an_initializer_18004": + return No_value_exists_in_scope_for_the_shorthand_property_0_Either_declare_one_or_provide_an_initializer + case "Classes_may_not_have_a_field_named_constructor_18006": + return Classes_may_not_have_a_field_named_constructor + case "JSX_expressions_may_not_use_the_comma_operator_Did_you_mean_to_write_an_array_18007": + return JSX_expressions_may_not_use_the_comma_operator_Did_you_mean_to_write_an_array + case "Private_identifiers_cannot_be_used_as_parameters_18009": + return Private_identifiers_cannot_be_used_as_parameters + case "An_accessibility_modifier_cannot_be_used_with_a_private_identifier_18010": + return An_accessibility_modifier_cannot_be_used_with_a_private_identifier + case "The_operand_of_a_delete_operator_cannot_be_a_private_identifier_18011": + return The_operand_of_a_delete_operator_cannot_be_a_private_identifier + case "constructor_is_a_reserved_word_18012": + return X_constructor_is_a_reserved_word + case "Property_0_is_not_accessible_outside_class_1_because_it_has_a_private_identifier_18013": + return Property_0_is_not_accessible_outside_class_1_because_it_has_a_private_identifier + case "The_property_0_cannot_be_accessed_on_type_1_within_this_class_because_it_is_shadowed_by_another_priv_18014": + return The_property_0_cannot_be_accessed_on_type_1_within_this_class_because_it_is_shadowed_by_another_private_identifier_with_the_same_spelling + case "Property_0_in_type_1_refers_to_a_different_member_that_cannot_be_accessed_from_within_type_2_18015": + return Property_0_in_type_1_refers_to_a_different_member_that_cannot_be_accessed_from_within_type_2 + case "Private_identifiers_are_not_allowed_outside_class_bodies_18016": + return Private_identifiers_are_not_allowed_outside_class_bodies + case "The_shadowing_declaration_of_0_is_defined_here_18017": + return The_shadowing_declaration_of_0_is_defined_here + case "The_declaration_of_0_that_you_probably_intended_to_use_is_defined_here_18018": + return The_declaration_of_0_that_you_probably_intended_to_use_is_defined_here + case "_0_modifier_cannot_be_used_with_a_private_identifier_18019": + return X_0_modifier_cannot_be_used_with_a_private_identifier + case "An_enum_member_cannot_be_named_with_a_private_identifier_18024": + return An_enum_member_cannot_be_named_with_a_private_identifier + case "can_only_be_used_at_the_start_of_a_file_18026": + return X_can_only_be_used_at_the_start_of_a_file + case "Compiler_reserves_name_0_when_emitting_private_identifier_downlevel_18027": + return Compiler_reserves_name_0_when_emitting_private_identifier_downlevel + case "Private_identifiers_are_only_available_when_targeting_ECMAScript_2015_and_higher_18028": + return Private_identifiers_are_only_available_when_targeting_ECMAScript_2015_and_higher + case "Private_identifiers_are_not_allowed_in_variable_declarations_18029": + return Private_identifiers_are_not_allowed_in_variable_declarations + case "An_optional_chain_cannot_contain_private_identifiers_18030": + return An_optional_chain_cannot_contain_private_identifiers + case "The_intersection_0_was_reduced_to_never_because_property_1_has_conflicting_types_in_some_constituent_18031": + return The_intersection_0_was_reduced_to_never_because_property_1_has_conflicting_types_in_some_constituents + case "The_intersection_0_was_reduced_to_never_because_property_1_exists_in_multiple_constituents_and_is_pr_18032": + return The_intersection_0_was_reduced_to_never_because_property_1_exists_in_multiple_constituents_and_is_private_in_some + case "Type_0_is_not_assignable_to_type_1_as_required_for_computed_enum_member_values_18033": + return Type_0_is_not_assignable_to_type_1_as_required_for_computed_enum_member_values + case "Specify_the_JSX_fragment_factory_function_to_use_when_targeting_react_JSX_emit_with_jsxFactory_compi_18034": + return Specify_the_JSX_fragment_factory_function_to_use_when_targeting_react_JSX_emit_with_jsxFactory_compiler_option_is_specified_e_g_Fragment + case "Invalid_value_for_jsxFragmentFactory_0_is_not_a_valid_identifier_or_qualified_name_18035": + return Invalid_value_for_jsxFragmentFactory_0_is_not_a_valid_identifier_or_qualified_name + case "Class_decorators_can_t_be_used_with_static_private_identifier_Consider_removing_the_experimental_dec_18036": + return Class_decorators_can_t_be_used_with_static_private_identifier_Consider_removing_the_experimental_decorator + case "await_expression_cannot_be_used_inside_a_class_static_block_18037": + return X_await_expression_cannot_be_used_inside_a_class_static_block + case "for_await_loops_cannot_be_used_inside_a_class_static_block_18038": + return X_for_await_loops_cannot_be_used_inside_a_class_static_block + case "Invalid_use_of_0_It_cannot_be_used_inside_a_class_static_block_18039": + return Invalid_use_of_0_It_cannot_be_used_inside_a_class_static_block + case "A_return_statement_cannot_be_used_inside_a_class_static_block_18041": + return A_return_statement_cannot_be_used_inside_a_class_static_block + case "_0_is_a_type_and_cannot_be_imported_in_JavaScript_files_Use_1_in_a_JSDoc_type_annotation_18042": + return X_0_is_a_type_and_cannot_be_imported_in_JavaScript_files_Use_1_in_a_JSDoc_type_annotation + case "Types_cannot_appear_in_export_declarations_in_JavaScript_files_18043": + return Types_cannot_appear_in_export_declarations_in_JavaScript_files + case "_0_is_automatically_exported_here_18044": + return X_0_is_automatically_exported_here + case "Properties_with_the_accessor_modifier_are_only_available_when_targeting_ECMAScript_2015_and_higher_18045": + return Properties_with_the_accessor_modifier_are_only_available_when_targeting_ECMAScript_2015_and_higher + case "_0_is_of_type_unknown_18046": + return X_0_is_of_type_unknown + case "_0_is_possibly_null_18047": + return X_0_is_possibly_null + case "_0_is_possibly_undefined_18048": + return X_0_is_possibly_undefined + case "_0_is_possibly_null_or_undefined_18049": + return X_0_is_possibly_null_or_undefined + case "The_value_0_cannot_be_used_here_18050": + return The_value_0_cannot_be_used_here + case "Compiler_option_0_cannot_be_given_an_empty_string_18051": + return Compiler_option_0_cannot_be_given_an_empty_string + case "Its_type_0_is_not_a_valid_JSX_element_type_18053": + return Its_type_0_is_not_a_valid_JSX_element_type + case "await_using_statements_cannot_be_used_inside_a_class_static_block_18054": + return X_await_using_statements_cannot_be_used_inside_a_class_static_block + case "_0_has_a_string_type_but_must_have_syntactically_recognizable_string_syntax_when_isolatedModules_is__18055": + return X_0_has_a_string_type_but_must_have_syntactically_recognizable_string_syntax_when_isolatedModules_is_enabled + case "Enum_member_following_a_non_literal_numeric_member_must_have_an_initializer_when_isolatedModules_is__18056": + return Enum_member_following_a_non_literal_numeric_member_must_have_an_initializer_when_isolatedModules_is_enabled + case "String_literal_import_and_export_names_are_not_supported_when_the_module_flag_is_set_to_es2015_or_es_18057": + return String_literal_import_and_export_names_are_not_supported_when_the_module_flag_is_set_to_es2015_or_es2020 + case "Default_imports_are_not_allowed_in_a_deferred_import_18058": + return Default_imports_are_not_allowed_in_a_deferred_import + case "Named_imports_are_not_allowed_in_a_deferred_import_18059": + return Named_imports_are_not_allowed_in_a_deferred_import + case "Deferred_imports_are_only_supported_when_the_module_flag_is_set_to_esnext_or_preserve_18060": + return Deferred_imports_are_only_supported_when_the_module_flag_is_set_to_esnext_or_preserve + case "_0_is_not_a_valid_meta_property_for_keyword_import_Did_you_mean_meta_or_defer_18061": + return X_0_is_not_a_valid_meta_property_for_keyword_import_Did_you_mean_meta_or_defer + case "nodenext_if_module_is_nodenext_node16_if_module_is_node16_or_node18_otherwise_bundler_69010": + return X_nodenext_if_module_is_nodenext_node16_if_module_is_node16_or_node18_otherwise_bundler + case "File_is_a_CommonJS_module_it_may_be_converted_to_an_ES_module_80001": + return File_is_a_CommonJS_module_it_may_be_converted_to_an_ES_module + case "This_constructor_function_may_be_converted_to_a_class_declaration_80002": + return This_constructor_function_may_be_converted_to_a_class_declaration + case "Import_may_be_converted_to_a_default_import_80003": + return Import_may_be_converted_to_a_default_import + case "JSDoc_types_may_be_moved_to_TypeScript_types_80004": + return JSDoc_types_may_be_moved_to_TypeScript_types + case "require_call_may_be_converted_to_an_import_80005": + return X_require_call_may_be_converted_to_an_import + case "This_may_be_converted_to_an_async_function_80006": + return This_may_be_converted_to_an_async_function + case "await_has_no_effect_on_the_type_of_this_expression_80007": + return X_await_has_no_effect_on_the_type_of_this_expression + case "Numeric_literals_with_absolute_values_equal_to_2_53_or_greater_are_too_large_to_be_represented_accur_80008": + return Numeric_literals_with_absolute_values_equal_to_2_53_or_greater_are_too_large_to_be_represented_accurately_as_integers + case "JSDoc_typedef_may_be_converted_to_TypeScript_type_80009": + return JSDoc_typedef_may_be_converted_to_TypeScript_type + case "JSDoc_typedefs_may_be_converted_to_TypeScript_types_80010": + return JSDoc_typedefs_may_be_converted_to_TypeScript_types + case "Add_missing_super_call_90001": + return Add_missing_super_call + case "Make_super_call_the_first_statement_in_the_constructor_90002": + return Make_super_call_the_first_statement_in_the_constructor + case "Change_extends_to_implements_90003": + return Change_extends_to_implements + case "Remove_unused_declaration_for_Colon_0_90004": + return Remove_unused_declaration_for_Colon_0 + case "Remove_import_from_0_90005": + return Remove_import_from_0 + case "Implement_interface_0_90006": + return Implement_interface_0 + case "Implement_inherited_abstract_class_90007": + return Implement_inherited_abstract_class + case "Add_0_to_unresolved_variable_90008": + return Add_0_to_unresolved_variable + case "Remove_variable_statement_90010": + return Remove_variable_statement + case "Remove_template_tag_90011": + return Remove_template_tag + case "Remove_type_parameters_90012": + return Remove_type_parameters + case "Import_0_from_1_90013": + return Import_0_from_1 + case "Change_0_to_1_90014": + return Change_0_to_1 + case "Declare_property_0_90016": + return Declare_property_0 + case "Add_index_signature_for_property_0_90017": + return Add_index_signature_for_property_0 + case "Disable_checking_for_this_file_90018": + return Disable_checking_for_this_file + case "Ignore_this_error_message_90019": + return Ignore_this_error_message + case "Initialize_property_0_in_the_constructor_90020": + return Initialize_property_0_in_the_constructor + case "Initialize_static_property_0_90021": + return Initialize_static_property_0 + case "Change_spelling_to_0_90022": + return Change_spelling_to_0 + case "Declare_method_0_90023": + return Declare_method_0 + case "Declare_static_method_0_90024": + return Declare_static_method_0 + case "Prefix_0_with_an_underscore_90025": + return Prefix_0_with_an_underscore + case "Rewrite_as_the_indexed_access_type_0_90026": + return Rewrite_as_the_indexed_access_type_0 + case "Declare_static_property_0_90027": + return Declare_static_property_0 + case "Call_decorator_expression_90028": + return Call_decorator_expression + case "Add_async_modifier_to_containing_function_90029": + return Add_async_modifier_to_containing_function + case "Replace_infer_0_with_unknown_90030": + return Replace_infer_0_with_unknown + case "Replace_all_unused_infer_with_unknown_90031": + return Replace_all_unused_infer_with_unknown + case "Add_parameter_name_90034": + return Add_parameter_name + case "Declare_private_property_0_90035": + return Declare_private_property_0 + case "Replace_0_with_Promise_1_90036": + return Replace_0_with_Promise_1 + case "Fix_all_incorrect_return_type_of_an_async_functions_90037": + return Fix_all_incorrect_return_type_of_an_async_functions + case "Declare_private_method_0_90038": + return Declare_private_method_0 + case "Remove_unused_destructuring_declaration_90039": + return Remove_unused_destructuring_declaration + case "Remove_unused_declarations_for_Colon_0_90041": + return Remove_unused_declarations_for_Colon_0 + case "Declare_a_private_field_named_0_90053": + return Declare_a_private_field_named_0 + case "Includes_imports_of_types_referenced_by_0_90054": + return Includes_imports_of_types_referenced_by_0 + case "Remove_type_from_import_declaration_from_0_90055": + return Remove_type_from_import_declaration_from_0 + case "Remove_type_from_import_of_0_from_1_90056": + return Remove_type_from_import_of_0_from_1 + case "Add_import_from_0_90057": + return Add_import_from_0 + case "Update_import_from_0_90058": + return Update_import_from_0 + case "Export_0_from_module_1_90059": + return Export_0_from_module_1 + case "Export_all_referenced_locals_90060": + return Export_all_referenced_locals + case "Update_modifiers_of_0_90061": + return Update_modifiers_of_0 + case "Add_annotation_of_type_0_90062": + return Add_annotation_of_type_0 + case "Add_return_type_0_90063": + return Add_return_type_0 + case "Extract_base_class_to_variable_90064": + return Extract_base_class_to_variable + case "Extract_default_export_to_variable_90065": + return Extract_default_export_to_variable + case "Extract_binding_expressions_to_variable_90066": + return Extract_binding_expressions_to_variable + case "Add_all_missing_type_annotations_90067": + return Add_all_missing_type_annotations + case "Add_satisfies_and_an_inline_type_assertion_with_0_90068": + return Add_satisfies_and_an_inline_type_assertion_with_0 + case "Extract_to_variable_and_replace_with_0_as_typeof_0_90069": + return Extract_to_variable_and_replace_with_0_as_typeof_0 + case "Mark_array_literal_as_const_90070": + return Mark_array_literal_as_const + case "Annotate_types_of_properties_expando_function_in_a_namespace_90071": + return Annotate_types_of_properties_expando_function_in_a_namespace + case "Convert_function_to_an_ES2015_class_95001": + return Convert_function_to_an_ES2015_class + case "Convert_0_to_1_in_0_95003": + return Convert_0_to_1_in_0 + case "Extract_to_0_in_1_95004": + return Extract_to_0_in_1 + case "Extract_function_95005": + return Extract_function + case "Extract_constant_95006": + return Extract_constant + case "Extract_to_0_in_enclosing_scope_95007": + return Extract_to_0_in_enclosing_scope + case "Extract_to_0_in_1_scope_95008": + return Extract_to_0_in_1_scope + case "Annotate_with_type_from_JSDoc_95009": + return Annotate_with_type_from_JSDoc + case "Infer_type_of_0_from_usage_95011": + return Infer_type_of_0_from_usage + case "Infer_parameter_types_from_usage_95012": + return Infer_parameter_types_from_usage + case "Convert_to_default_import_95013": + return Convert_to_default_import + case "Install_0_95014": + return Install_0 + case "Replace_import_with_0_95015": + return Replace_import_with_0 + case "Use_synthetic_default_member_95016": + return Use_synthetic_default_member + case "Convert_to_ES_module_95017": + return Convert_to_ES_module + case "Add_undefined_type_to_property_0_95018": + return Add_undefined_type_to_property_0 + case "Add_initializer_to_property_0_95019": + return Add_initializer_to_property_0 + case "Add_definite_assignment_assertion_to_property_0_95020": + return Add_definite_assignment_assertion_to_property_0 + case "Convert_all_type_literals_to_mapped_type_95021": + return Convert_all_type_literals_to_mapped_type + case "Add_all_missing_members_95022": + return Add_all_missing_members + case "Infer_all_types_from_usage_95023": + return Infer_all_types_from_usage + case "Delete_all_unused_declarations_95024": + return Delete_all_unused_declarations + case "Prefix_all_unused_declarations_with_where_possible_95025": + return Prefix_all_unused_declarations_with_where_possible + case "Fix_all_detected_spelling_errors_95026": + return Fix_all_detected_spelling_errors + case "Add_initializers_to_all_uninitialized_properties_95027": + return Add_initializers_to_all_uninitialized_properties + case "Add_definite_assignment_assertions_to_all_uninitialized_properties_95028": + return Add_definite_assignment_assertions_to_all_uninitialized_properties + case "Add_undefined_type_to_all_uninitialized_properties_95029": + return Add_undefined_type_to_all_uninitialized_properties + case "Change_all_jsdoc_style_types_to_TypeScript_95030": + return Change_all_jsdoc_style_types_to_TypeScript + case "Change_all_jsdoc_style_types_to_TypeScript_and_add_undefined_to_nullable_types_95031": + return Change_all_jsdoc_style_types_to_TypeScript_and_add_undefined_to_nullable_types + case "Implement_all_unimplemented_interfaces_95032": + return Implement_all_unimplemented_interfaces + case "Install_all_missing_types_packages_95033": + return Install_all_missing_types_packages + case "Rewrite_all_as_indexed_access_types_95034": + return Rewrite_all_as_indexed_access_types + case "Convert_all_to_default_imports_95035": + return Convert_all_to_default_imports + case "Make_all_super_calls_the_first_statement_in_their_constructor_95036": + return Make_all_super_calls_the_first_statement_in_their_constructor + case "Add_qualifier_to_all_unresolved_variables_matching_a_member_name_95037": + return Add_qualifier_to_all_unresolved_variables_matching_a_member_name + case "Change_all_extended_interfaces_to_implements_95038": + return Change_all_extended_interfaces_to_implements + case "Add_all_missing_super_calls_95039": + return Add_all_missing_super_calls + case "Implement_all_inherited_abstract_classes_95040": + return Implement_all_inherited_abstract_classes + case "Add_all_missing_async_modifiers_95041": + return Add_all_missing_async_modifiers + case "Add_ts_ignore_to_all_error_messages_95042": + return Add_ts_ignore_to_all_error_messages + case "Annotate_everything_with_types_from_JSDoc_95043": + return Annotate_everything_with_types_from_JSDoc + case "Add_to_all_uncalled_decorators_95044": + return Add_to_all_uncalled_decorators + case "Convert_all_constructor_functions_to_classes_95045": + return Convert_all_constructor_functions_to_classes + case "Generate_get_and_set_accessors_95046": + return Generate_get_and_set_accessors + case "Convert_require_to_import_95047": + return Convert_require_to_import + case "Convert_all_require_to_import_95048": + return Convert_all_require_to_import + case "Move_to_a_new_file_95049": + return Move_to_a_new_file + case "Remove_unreachable_code_95050": + return Remove_unreachable_code + case "Remove_all_unreachable_code_95051": + return Remove_all_unreachable_code + case "Add_missing_typeof_95052": + return Add_missing_typeof + case "Remove_unused_label_95053": + return Remove_unused_label + case "Remove_all_unused_labels_95054": + return Remove_all_unused_labels + case "Convert_0_to_mapped_object_type_95055": + return Convert_0_to_mapped_object_type + case "Convert_namespace_import_to_named_imports_95056": + return Convert_namespace_import_to_named_imports + case "Convert_named_imports_to_namespace_import_95057": + return Convert_named_imports_to_namespace_import + case "Add_or_remove_braces_in_an_arrow_function_95058": + return Add_or_remove_braces_in_an_arrow_function + case "Add_braces_to_arrow_function_95059": + return Add_braces_to_arrow_function + case "Remove_braces_from_arrow_function_95060": + return Remove_braces_from_arrow_function + case "Convert_default_export_to_named_export_95061": + return Convert_default_export_to_named_export + case "Convert_named_export_to_default_export_95062": + return Convert_named_export_to_default_export + case "Add_missing_enum_member_0_95063": + return Add_missing_enum_member_0 + case "Add_all_missing_imports_95064": + return Add_all_missing_imports + case "Convert_to_async_function_95065": + return Convert_to_async_function + case "Convert_all_to_async_functions_95066": + return Convert_all_to_async_functions + case "Add_missing_call_parentheses_95067": + return Add_missing_call_parentheses + case "Add_all_missing_call_parentheses_95068": + return Add_all_missing_call_parentheses + case "Add_unknown_conversion_for_non_overlapping_types_95069": + return Add_unknown_conversion_for_non_overlapping_types + case "Add_unknown_to_all_conversions_of_non_overlapping_types_95070": + return Add_unknown_to_all_conversions_of_non_overlapping_types + case "Add_missing_new_operator_to_call_95071": + return Add_missing_new_operator_to_call + case "Add_missing_new_operator_to_all_calls_95072": + return Add_missing_new_operator_to_all_calls + case "Add_names_to_all_parameters_without_names_95073": + return Add_names_to_all_parameters_without_names + case "Enable_the_experimentalDecorators_option_in_your_configuration_file_95074": + return Enable_the_experimentalDecorators_option_in_your_configuration_file + case "Convert_parameters_to_destructured_object_95075": + return Convert_parameters_to_destructured_object + case "Extract_type_95077": + return Extract_type + case "Extract_to_type_alias_95078": + return Extract_to_type_alias + case "Extract_to_typedef_95079": + return Extract_to_typedef + case "Infer_this_type_of_0_from_usage_95080": + return Infer_this_type_of_0_from_usage + case "Add_const_to_unresolved_variable_95081": + return Add_const_to_unresolved_variable + case "Add_const_to_all_unresolved_variables_95082": + return Add_const_to_all_unresolved_variables + case "Add_await_95083": + return Add_await + case "Add_await_to_initializer_for_0_95084": + return Add_await_to_initializer_for_0 + case "Fix_all_expressions_possibly_missing_await_95085": + return Fix_all_expressions_possibly_missing_await + case "Remove_unnecessary_await_95086": + return Remove_unnecessary_await + case "Remove_all_unnecessary_uses_of_await_95087": + return Remove_all_unnecessary_uses_of_await + case "Enable_the_jsx_flag_in_your_configuration_file_95088": + return Enable_the_jsx_flag_in_your_configuration_file + case "Add_await_to_initializers_95089": + return Add_await_to_initializers + case "Extract_to_interface_95090": + return Extract_to_interface + case "Convert_to_a_bigint_numeric_literal_95091": + return Convert_to_a_bigint_numeric_literal + case "Convert_all_to_bigint_numeric_literals_95092": + return Convert_all_to_bigint_numeric_literals + case "Convert_const_to_let_95093": + return Convert_const_to_let + case "Prefix_with_declare_95094": + return Prefix_with_declare + case "Prefix_all_incorrect_property_declarations_with_declare_95095": + return Prefix_all_incorrect_property_declarations_with_declare + case "Convert_to_template_string_95096": + return Convert_to_template_string + case "Add_export_to_make_this_file_into_a_module_95097": + return Add_export_to_make_this_file_into_a_module + case "Set_the_target_option_in_your_configuration_file_to_0_95098": + return Set_the_target_option_in_your_configuration_file_to_0 + case "Set_the_module_option_in_your_configuration_file_to_0_95099": + return Set_the_module_option_in_your_configuration_file_to_0 + case "Convert_invalid_character_to_its_html_entity_code_95100": + return Convert_invalid_character_to_its_html_entity_code + case "Convert_all_invalid_characters_to_HTML_entity_code_95101": + return Convert_all_invalid_characters_to_HTML_entity_code + case "Convert_all_const_to_let_95102": + return Convert_all_const_to_let + case "Convert_function_expression_0_to_arrow_function_95105": + return Convert_function_expression_0_to_arrow_function + case "Convert_function_declaration_0_to_arrow_function_95106": + return Convert_function_declaration_0_to_arrow_function + case "Fix_all_implicit_this_errors_95107": + return Fix_all_implicit_this_errors + case "Wrap_invalid_character_in_an_expression_container_95108": + return Wrap_invalid_character_in_an_expression_container + case "Wrap_all_invalid_characters_in_an_expression_container_95109": + return Wrap_all_invalid_characters_in_an_expression_container + case "Visit_https_Colon_Slash_Slashaka_ms_Slashtsconfig_to_read_more_about_this_file_95110": + return Visit_https_Colon_Slash_Slashaka_ms_Slashtsconfig_to_read_more_about_this_file + case "Add_a_return_statement_95111": + return Add_a_return_statement + case "Remove_braces_from_arrow_function_body_95112": + return Remove_braces_from_arrow_function_body + case "Wrap_the_following_body_with_parentheses_which_should_be_an_object_literal_95113": + return Wrap_the_following_body_with_parentheses_which_should_be_an_object_literal + case "Add_all_missing_return_statement_95114": + return Add_all_missing_return_statement + case "Remove_braces_from_all_arrow_function_bodies_with_relevant_issues_95115": + return Remove_braces_from_all_arrow_function_bodies_with_relevant_issues + case "Wrap_all_object_literal_with_parentheses_95116": + return Wrap_all_object_literal_with_parentheses + case "Move_labeled_tuple_element_modifiers_to_labels_95117": + return Move_labeled_tuple_element_modifiers_to_labels + case "Convert_overload_list_to_single_signature_95118": + return Convert_overload_list_to_single_signature + case "Generate_get_and_set_accessors_for_all_overriding_properties_95119": + return Generate_get_and_set_accessors_for_all_overriding_properties + case "Wrap_in_JSX_fragment_95120": + return Wrap_in_JSX_fragment + case "Wrap_all_unparented_JSX_in_JSX_fragment_95121": + return Wrap_all_unparented_JSX_in_JSX_fragment + case "Convert_arrow_function_or_function_expression_95122": + return Convert_arrow_function_or_function_expression + case "Convert_to_anonymous_function_95123": + return Convert_to_anonymous_function + case "Convert_to_named_function_95124": + return Convert_to_named_function + case "Convert_to_arrow_function_95125": + return Convert_to_arrow_function + case "Remove_parentheses_95126": + return Remove_parentheses + case "Could_not_find_a_containing_arrow_function_95127": + return Could_not_find_a_containing_arrow_function + case "Containing_function_is_not_an_arrow_function_95128": + return Containing_function_is_not_an_arrow_function + case "Could_not_find_export_statement_95129": + return Could_not_find_export_statement + case "This_file_already_has_a_default_export_95130": + return This_file_already_has_a_default_export + case "Could_not_find_import_clause_95131": + return Could_not_find_import_clause + case "Could_not_find_namespace_import_or_named_imports_95132": + return Could_not_find_namespace_import_or_named_imports + case "Selection_is_not_a_valid_type_node_95133": + return Selection_is_not_a_valid_type_node + case "No_type_could_be_extracted_from_this_type_node_95134": + return No_type_could_be_extracted_from_this_type_node + case "Could_not_find_property_for_which_to_generate_accessor_95135": + return Could_not_find_property_for_which_to_generate_accessor + case "Name_is_not_valid_95136": + return Name_is_not_valid + case "Can_only_convert_property_with_modifier_95137": + return Can_only_convert_property_with_modifier + case "Switch_each_misused_0_to_1_95138": + return Switch_each_misused_0_to_1 + case "Convert_to_optional_chain_expression_95139": + return Convert_to_optional_chain_expression + case "Could_not_find_convertible_access_expression_95140": + return Could_not_find_convertible_access_expression + case "Could_not_find_matching_access_expressions_95141": + return Could_not_find_matching_access_expressions + case "Can_only_convert_logical_AND_access_chains_95142": + return Can_only_convert_logical_AND_access_chains + case "Add_void_to_Promise_resolved_without_a_value_95143": + return Add_void_to_Promise_resolved_without_a_value + case "Add_void_to_all_Promises_resolved_without_a_value_95144": + return Add_void_to_all_Promises_resolved_without_a_value + case "Use_element_access_for_0_95145": + return Use_element_access_for_0 + case "Use_element_access_for_all_undeclared_properties_95146": + return Use_element_access_for_all_undeclared_properties + case "Delete_all_unused_imports_95147": + return Delete_all_unused_imports + case "Infer_function_return_type_95148": + return Infer_function_return_type + case "Return_type_must_be_inferred_from_a_function_95149": + return Return_type_must_be_inferred_from_a_function + case "Could_not_determine_function_return_type_95150": + return Could_not_determine_function_return_type + case "Could_not_convert_to_arrow_function_95151": + return Could_not_convert_to_arrow_function + case "Could_not_convert_to_named_function_95152": + return Could_not_convert_to_named_function + case "Could_not_convert_to_anonymous_function_95153": + return Could_not_convert_to_anonymous_function + case "Can_only_convert_string_concatenations_and_string_literals_95154": + return Can_only_convert_string_concatenations_and_string_literals + case "Selection_is_not_a_valid_statement_or_statements_95155": + return Selection_is_not_a_valid_statement_or_statements + case "Add_missing_function_declaration_0_95156": + return Add_missing_function_declaration_0 + case "Add_all_missing_function_declarations_95157": + return Add_all_missing_function_declarations + case "Method_not_implemented_95158": + return Method_not_implemented + case "Function_not_implemented_95159": + return Function_not_implemented + case "Add_override_modifier_95160": + return Add_override_modifier + case "Remove_override_modifier_95161": + return Remove_override_modifier + case "Add_all_missing_override_modifiers_95162": + return Add_all_missing_override_modifiers + case "Remove_all_unnecessary_override_modifiers_95163": + return Remove_all_unnecessary_override_modifiers + case "Can_only_convert_named_export_95164": + return Can_only_convert_named_export + case "Add_missing_properties_95165": + return Add_missing_properties + case "Add_all_missing_properties_95166": + return Add_all_missing_properties + case "Add_missing_attributes_95167": + return Add_missing_attributes + case "Add_all_missing_attributes_95168": + return Add_all_missing_attributes + case "Add_undefined_to_optional_property_type_95169": + return Add_undefined_to_optional_property_type + case "Convert_named_imports_to_default_import_95170": + return Convert_named_imports_to_default_import + case "Delete_unused_param_tag_0_95171": + return Delete_unused_param_tag_0 + case "Delete_all_unused_param_tags_95172": + return Delete_all_unused_param_tags + case "Rename_param_tag_name_0_to_1_95173": + return Rename_param_tag_name_0_to_1 + case "Use_0_95174": + return Use_0 + case "Use_Number_isNaN_in_all_conditions_95175": + return Use_Number_isNaN_in_all_conditions + case "Convert_typedef_to_TypeScript_type_95176": + return Convert_typedef_to_TypeScript_type + case "Convert_all_typedef_to_TypeScript_types_95177": + return Convert_all_typedef_to_TypeScript_types + case "Move_to_file_95178": + return Move_to_file + case "Cannot_move_to_file_selected_file_is_invalid_95179": + return Cannot_move_to_file_selected_file_is_invalid + case "Use_import_type_95180": + return Use_import_type + case "Use_type_0_95181": + return Use_type_0 + case "Fix_all_with_type_only_imports_95182": + return Fix_all_with_type_only_imports + case "Cannot_move_statements_to_the_selected_file_95183": + return Cannot_move_statements_to_the_selected_file + case "Inline_variable_95184": + return Inline_variable + case "Could_not_find_variable_to_inline_95185": + return Could_not_find_variable_to_inline + case "Variables_with_multiple_declarations_cannot_be_inlined_95186": + return Variables_with_multiple_declarations_cannot_be_inlined + case "Add_missing_comma_for_object_member_completion_0_95187": + return Add_missing_comma_for_object_member_completion_0 + case "Add_missing_parameter_to_0_95188": + return Add_missing_parameter_to_0 + case "Add_missing_parameters_to_0_95189": + return Add_missing_parameters_to_0 + case "Add_all_missing_parameters_95190": + return Add_all_missing_parameters + case "Add_optional_parameter_to_0_95191": + return Add_optional_parameter_to_0 + case "Add_optional_parameters_to_0_95192": + return Add_optional_parameters_to_0 + case "Add_all_optional_parameters_95193": + return Add_all_optional_parameters + case "Wrap_in_parentheses_95194": + return Wrap_in_parentheses + case "Wrap_all_invalid_decorator_expressions_in_parentheses_95195": + return Wrap_all_invalid_decorator_expressions_in_parentheses + case "Add_resolution_mode_import_attribute_95196": + return Add_resolution_mode_import_attribute + case "Add_resolution_mode_import_attribute_to_all_type_only_imports_that_need_it_95197": + return Add_resolution_mode_import_attribute_to_all_type_only_imports_that_need_it + case "Do_not_print_diagnostics_100000": + return Do_not_print_diagnostics + case "Run_in_single_threaded_mode_100001": + return Run_in_single_threaded_mode + case "Generate_pprof_CPU_Slashmemory_profiles_to_the_given_directory_100002": + return Generate_pprof_CPU_Slashmemory_profiles_to_the_given_directory + case "Set_the_number_of_checkers_per_project_100003": + return Set_the_number_of_checkers_per_project + case "4_unless_singleThreaded_is_passed_100004": + return X_4_unless_singleThreaded_is_passed + default: + return nil + } +} diff --git a/internal/diagnostics/diagnostics_test.go b/internal/diagnostics/diagnostics_test.go new file mode 100644 index 0000000000..b93bedad3f --- /dev/null +++ b/internal/diagnostics/diagnostics_test.go @@ -0,0 +1,145 @@ +package diagnostics + +import ( + "testing" + + "github.com/microsoft/typescript-go/internal/locale" + "golang.org/x/text/language" + "gotest.tools/v3/assert" +) + +func TestLocalize(t *testing.T) { + t.Parallel() + + tests := []struct { + name string + message *Message + locale locale.Locale + args []any + expected string + }{ + { + name: "english default", + message: Identifier_expected, + locale: locale.Locale(language.English), + expected: "Identifier expected.", + }, + { + name: "undefined locale uses english", + message: Identifier_expected, + locale: locale.Locale(language.Und), + expected: "Identifier expected.", + }, + { + name: "with single argument", + message: X_0_expected, + locale: locale.Locale(language.English), + args: []any{")"}, + expected: "')' expected.", + }, + { + name: "with multiple arguments", + message: The_parser_expected_to_find_a_1_to_match_the_0_token_here, + locale: locale.Locale(language.English), + args: []any{"{", "}"}, + expected: "The parser expected to find a '}' to match the '{' token here.", + }, + { + name: "fallback to english for unknown locale", + message: Identifier_expected, + locale: locale.Locale(language.MustParse("af-ZA")), + expected: "Identifier expected.", + }, + { + name: "german", + message: Identifier_expected, + locale: locale.Locale(language.MustParse("de-DE")), + expected: "Es wurde ein Bezeichner erwartet.", + }, + { + name: "french", + message: Identifier_expected, + locale: locale.Locale(language.MustParse("fr-FR")), + expected: "Identificateur attendu.", + }, + { + name: "spanish", + message: Identifier_expected, + locale: locale.Locale(language.MustParse("es-ES")), + expected: "Se esperaba un identificador.", + }, + { + name: "japanese", + message: Identifier_expected, + locale: locale.Locale(language.MustParse("ja-JP")), + expected: "識別子が必要です。", + }, + { + name: "chinese simplified", + message: Identifier_expected, + locale: locale.Locale(language.MustParse("zh-CN")), + expected: "应为标识符。", + }, + { + name: "korean", + message: Identifier_expected, + locale: locale.Locale(language.MustParse("ko-KR")), + expected: "식별자가 필요합니다.", + }, + { + name: "russian", + message: Identifier_expected, + locale: locale.Locale(language.MustParse("ru-RU")), + expected: "Ожидался идентификатор.", + }, + { + name: "german with args", + message: X_0_expected, + locale: locale.Locale(language.MustParse("de-DE")), + args: []any{")"}, + expected: "\")\" wurde erwartet.", + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + t.Parallel() + result := tt.message.Localize(tt.locale, tt.args...) + assert.Equal(t, result, tt.expected) + }) + } +} + +func TestLocalize_ByKey(t *testing.T) { + t.Parallel() + + tests := []struct { + name string + key Key + locale locale.Locale + args []string + expected string + }{ + { + name: "by key without args", + key: "Identifier_expected_1003", + locale: locale.Locale(language.English), + expected: "Identifier expected.", + }, + { + name: "by key with args", + key: "_0_expected_1005", + locale: locale.Locale(language.English), + args: []string{")"}, + expected: "')' expected.", + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + t.Parallel() + result := Localize(tt.locale, nil, tt.key, tt.args...) + assert.Equal(t, result, tt.expected) + }) + } +} diff --git a/internal/diagnostics/extraDiagnosticMessages.json b/internal/diagnostics/extraDiagnosticMessages.json index edf9c5735b..aefd5c7426 100644 --- a/internal/diagnostics/extraDiagnosticMessages.json +++ b/internal/diagnostics/extraDiagnosticMessages.json @@ -42,5 +42,9 @@ "Project '{0}' is out of date because it has errors.": { "category": "Message", "code": 6423 + }, + "Locale must be an IETF BCP 47 language tag. Examples: '{0}', '{1}'.": { + "category": "Error", + "code": 6048 } } diff --git a/internal/diagnostics/generate.go b/internal/diagnostics/generate.go index 991d84dc1d..a66d4fde69 100644 --- a/internal/diagnostics/generate.go +++ b/internal/diagnostics/generate.go @@ -5,6 +5,8 @@ package main import ( "bytes" "cmp" + "compress/gzip" + "encoding/xml" "flag" "fmt" "go/format" @@ -21,7 +23,9 @@ import ( "unicode" "github.com/go-json-experiment/json" + "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/repo" + "golang.org/x/text/language" ) type diagnosticMessage struct { @@ -35,13 +39,44 @@ type diagnosticMessage struct { key string } +type LCX struct { + TgtCul string `xml:"TgtCul,attr"` + RootItems []RootItem `xml:"Item"` +} + +type RootItem struct { + ItemId string `xml:"ItemId,attr"` + Items []StringTableItem `xml:"Item"` +} + +type StringTableItem struct { + ItemId string `xml:"ItemId,attr"` + Items []LocalizedItem `xml:"Item"` +} + +type LocalizedItem struct { + ItemId string `xml:"ItemId,attr"` + Str Str `xml:"Str"` +} + +type Str struct { + Val string `xml:"Val"` + Tgt *Tgt `xml:"Tgt"` +} + +type Tgt struct { + Val string `xml:"Val"` +} + func main() { log.SetFlags(log.LstdFlags | log.Lshortfile) - output := flag.String("output", "", "path to the output diagnostics_generated.go file") + diagnosticsOutput := flag.String("diagnostics", "", "path to the output diagnostics_generated.go file") + locOutput := flag.String("loc", "", "path to the output loc_generated.go file") + locDir := flag.String("locdir", "", "directory to write locale .json.gz files") flag.Parse() - if *output == "" { + if *diagnosticsOutput == "" || *locOutput == "" || *locDir == "" { flag.Usage() return } @@ -63,6 +98,43 @@ func main() { return cmp.Compare(a.Code, b.Code) }) + // Collect known keys for filtering localizations + knownKeys := make(map[string]bool, len(diagnosticMessages)) + for _, m := range diagnosticMessages { + _, key := convertPropertyName(m.key, m.Code) + knownKeys[key] = true + } + + // Generate diagnostics file + diagnosticsBuf := generateDiagnostics(diagnosticMessages) + + formatted, err := format.Source(diagnosticsBuf.Bytes()) + if err != nil { + log.Fatalf("failed to format diagnostics output: %v", err) + return + } + + if err := os.WriteFile(*diagnosticsOutput, formatted, 0o666); err != nil { + log.Fatalf("failed to write diagnostics output: %v", err) + return + } + + // Generate localizations file + locBuf := generateLocalizations(knownKeys, *locDir) + + formatted, err = format.Source(locBuf.Bytes()) + if err != nil { + log.Fatalf("failed to format localizations output: %v", err) + return + } + + if err := os.WriteFile(*locOutput, formatted, 0o666); err != nil { + log.Fatalf("failed to write localizations output: %v", err) + return + } +} + +func generateDiagnostics(diagnosticMessages []*diagnosticMessage) *bytes.Buffer { var buf bytes.Buffer buf.WriteString("// Code generated by generate.go; DO NOT EDIT.\n") @@ -87,16 +159,182 @@ func main() { buf.WriteString("}\n\n") } - formatted, err := format.Source(buf.Bytes()) + buf.WriteString("func keyToMessage(key Key) *Message {\n") + buf.WriteString("\tswitch key {\n") + for _, m := range diagnosticMessages { + _, key := convertPropertyName(m.key, m.Code) + varName, _ := convertPropertyName(m.key, m.Code) + fmt.Fprintf(&buf, "\tcase %q:\n\t\treturn %s\n", key, varName) + } + buf.WriteString("\tdefault:\n\t\treturn nil\n") + buf.WriteString("\t}\n") + buf.WriteString("}\n") + + return &buf +} + +func generateLocalizations(knownKeys map[string]bool, locDir string) *bytes.Buffer { + var buf bytes.Buffer + + buf.WriteString("// Code generated by generate.go; DO NOT EDIT.\n") + buf.WriteString("\n") + buf.WriteString("package diagnostics\n") + buf.WriteString("\n") + buf.WriteString("import (\n") + buf.WriteString("\t\"compress/gzip\"\n") + buf.WriteString("\t_ \"embed\"\n") + buf.WriteString("\t\"strings\"\n") + buf.WriteString("\t\"sync\"\n") + buf.WriteString("\t\"golang.org/x/text/language\"\n") + buf.WriteString("\t\"github.com/go-json-experiment/json\"\n") + buf.WriteString(")\n") + + // Remove and recreate the loc directory for a clean state + if err := os.RemoveAll(locDir); err != nil { + log.Fatalf("failed to remove locale directory: %v", err) + } + if err := os.MkdirAll(locDir, 0o755); err != nil { + log.Fatalf("failed to create locale directory: %v", err) + } + + // Generate locale maps + localeFiles, err := filepath.Glob(filepath.Join(repo.TypeScriptSubmodulePath, "src", "loc", "lcl", "*", "diagnosticMessages", "diagnosticMessages.generated.json.lcl")) if err != nil { - log.Fatalf("failed to format output: %v", err) - return + log.Fatalf("failed to find locale files: %v", err) + } + if len(localeFiles) == 0 { + log.Fatalf("no locale files found in %s", filepath.Join(repo.TypeScriptSubmodulePath, "src", "loc", "lcl")) + } + slices.Sort(localeFiles) + + type localeInfo struct { + varName string + tgtCul string + canonical string // canonical lowercase form (e.g., "zh-cn", "pt-br") + lang string + messages map[string]string + filename string } - if err := os.WriteFile(*output, formatted, 0o666); err != nil { - log.Fatalf("failed to write output: %v", err) - return + var locales []localeInfo + + for _, localeFile := range localeFiles { + localizedMessages, tgtCul := readLocalizedMessages(localeFile) + if len(localizedMessages) == 0 { + continue + } + + // Filter to only known keys + for key := range localizedMessages { + if !knownKeys[key] { + delete(localizedMessages, key) + } + } + + if len(localizedMessages) == 0 { + continue + } + + // Convert locale code to valid Go identifier + localeVar := strings.ReplaceAll(strings.ReplaceAll(tgtCul, "-", ""), "_", "") + + // Parse the locale using language.Tag to get canonical forms + tag, err := language.Parse(tgtCul) + if err != nil { + log.Printf("failed to parse locale %q: %v", tgtCul, err) + continue + } + + base, _ := tag.Base() + lang := strings.ToLower(base.String()) + + // Get canonical form (lowercase with dash) + canonical := strings.ToLower(tgtCul) + + // Filename for the JSON.gz file (use the original tgtCul as standard language tag) + filename := fmt.Sprintf("%s.json.gz", tgtCul) + + // Write the JSON.gz file + // Convert map to OrderedMap with sorted keys for consistent ordering + keys := slices.Sorted(maps.Keys(localizedMessages)) + var orderedMessages collections.OrderedMap[string, string] + for _, key := range keys { + orderedMessages.Set(key, localizedMessages[key]) + } + jsonData, err := json.Marshal(&orderedMessages) + if err != nil { + log.Fatalf("failed to marshal locale %s: %v", tgtCul, err) + } + + var compressed bytes.Buffer + gzipWriter, err := gzip.NewWriterLevel(&compressed, gzip.BestCompression) + if err != nil { + log.Fatalf("failed to create gzip writer for locale %s: %v", tgtCul, err) + } + if _, err := gzipWriter.Write(jsonData); err != nil { + log.Fatalf("failed to compress locale %s: %v", tgtCul, err) + } + if err := gzipWriter.Close(); err != nil { + log.Fatalf("failed to close gzip writer for locale %s: %v", tgtCul, err) + } + + outputPath := filepath.Join(locDir, filename) + if err := os.WriteFile(outputPath, compressed.Bytes(), 0o644); err != nil { + log.Fatalf("failed to write locale file %s: %v", outputPath, err) + } + + locales = append(locales, localeInfo{ + varName: localeVar, + tgtCul: tgtCul, + canonical: canonical, + lang: lang, + messages: localizedMessages, + filename: filename, + }) + } + + // Generate matcher with inlined tags + // English is first (index 0) as the default/fallback with no translation needed + buf.WriteString("\nvar matcher = language.NewMatcher([]language.Tag{\n") + buf.WriteString("\tlanguage.English,\n") + for _, loc := range locales { + fmt.Fprintf(&buf, "\tlanguage.MustParse(%q),\n", loc.tgtCul) + } + buf.WriteString("})\n") + + // Generate index-to-function map for matcher results + // English (index 0) returns nil since we use the default English text + buf.WriteString("\nvar localeFuncs = []func() map[Key]string{\n") + buf.WriteString("\tnil, // English (default)\n") + for _, loc := range locales { + fmt.Fprintf(&buf, "\t%s,\n", loc.varName) + } + buf.WriteString("}\n") + + // Generate helper function for decompressing locale data + buf.WriteString("\nfunc loadLocaleData(data string) map[Key]string {\n") + buf.WriteString("\tgr, err := gzip.NewReader(strings.NewReader(data))\n") + buf.WriteString("\tif err != nil {\n") + buf.WriteString("\t\tpanic(\"failed to create gzip reader: \" + err.Error())\n") + buf.WriteString("\t}\n") + buf.WriteString("\tdefer gr.Close()\n") + buf.WriteString("\tvar result map[Key]string\n") + buf.WriteString("\tif err := json.UnmarshalRead(gr, &result); err != nil {\n") + buf.WriteString("\t\tpanic(\"failed to unmarshal locale data: \" + err.Error())\n") + buf.WriteString("\t}\n") + buf.WriteString("\treturn result\n") + buf.WriteString("}\n") + + // Generate embed directives, vars, and loader functions interleaved at the bottom + for _, loc := range locales { + fmt.Fprintf(&buf, "\n//go:embed loc/%s\n", loc.filename) + fmt.Fprintf(&buf, "var %sData string\n", loc.varName) + fmt.Fprintf(&buf, "\nvar %s = sync.OnceValue(func() map[Key]string {\n", loc.varName) + fmt.Fprintf(&buf, "\treturn loadLocaleData(%sData)\n", loc.varName) + buf.WriteString("})\n") } + + return &buf } func readRawMessages(p string) map[int]*diagnosticMessage { @@ -122,6 +360,45 @@ func readRawMessages(p string) map[int]*diagnosticMessage { return codeToMessage } +func readLocalizedMessages(p string) (map[string]string, string) { + file, err := os.Open(p) + if err != nil { + log.Printf("failed to open locale file %s: %v", p, err) + return nil, "" + } + defer file.Close() + + var lcx LCX + if err := xml.NewDecoder(file).Decode(&lcx); err != nil { + log.Printf("failed to decode locale file %s: %v", p, err) + return nil, "" + } + + messages := make(map[string]string) + + // Navigate the nested Item structure + for _, rootItem := range lcx.RootItems { + for _, stringTable := range rootItem.Items { + for _, item := range stringTable.Items { + // ItemId has format ";key_code", remove the leading semicolon + itemId := strings.TrimPrefix(item.ItemId, ";") + + // Get the localized text from Tgt if available, otherwise use Val + var text string + if item.Str.Tgt != nil && item.Str.Tgt.Val != "" { + text = item.Str.Tgt.Val + } else { + text = item.Str.Val + } + + messages[itemId] = text + } + } + } + + return messages, lcx.TgtCul +} + var ( multipleUnderscoreRegexp = regexp.MustCompile(`_+`) leadingUnderscoreUnlessDigitRegexp = regexp.MustCompile(`^_+(\D)`) diff --git a/internal/diagnostics/loc/cs-CZ.json.gz b/internal/diagnostics/loc/cs-CZ.json.gz new file mode 100644 index 0000000000..df21c307f0 Binary files /dev/null and b/internal/diagnostics/loc/cs-CZ.json.gz differ diff --git a/internal/diagnostics/loc/de-DE.json.gz b/internal/diagnostics/loc/de-DE.json.gz new file mode 100644 index 0000000000..5b398845ea Binary files /dev/null and b/internal/diagnostics/loc/de-DE.json.gz differ diff --git a/internal/diagnostics/loc/es-ES.json.gz b/internal/diagnostics/loc/es-ES.json.gz new file mode 100644 index 0000000000..d068162ce1 Binary files /dev/null and b/internal/diagnostics/loc/es-ES.json.gz differ diff --git a/internal/diagnostics/loc/fr-FR.json.gz b/internal/diagnostics/loc/fr-FR.json.gz new file mode 100644 index 0000000000..ac9536dbef Binary files /dev/null and b/internal/diagnostics/loc/fr-FR.json.gz differ diff --git a/internal/diagnostics/loc/it-IT.json.gz b/internal/diagnostics/loc/it-IT.json.gz new file mode 100644 index 0000000000..31328e9ee4 Binary files /dev/null and b/internal/diagnostics/loc/it-IT.json.gz differ diff --git a/internal/diagnostics/loc/ja-JP.json.gz b/internal/diagnostics/loc/ja-JP.json.gz new file mode 100644 index 0000000000..035a86ccce Binary files /dev/null and b/internal/diagnostics/loc/ja-JP.json.gz differ diff --git a/internal/diagnostics/loc/ko-KR.json.gz b/internal/diagnostics/loc/ko-KR.json.gz new file mode 100644 index 0000000000..05a48d3142 Binary files /dev/null and b/internal/diagnostics/loc/ko-KR.json.gz differ diff --git a/internal/diagnostics/loc/pl-PL.json.gz b/internal/diagnostics/loc/pl-PL.json.gz new file mode 100644 index 0000000000..33a6f2812b Binary files /dev/null and b/internal/diagnostics/loc/pl-PL.json.gz differ diff --git a/internal/diagnostics/loc/pt-BR.json.gz b/internal/diagnostics/loc/pt-BR.json.gz new file mode 100644 index 0000000000..2b8064be3e Binary files /dev/null and b/internal/diagnostics/loc/pt-BR.json.gz differ diff --git a/internal/diagnostics/loc/ru-RU.json.gz b/internal/diagnostics/loc/ru-RU.json.gz new file mode 100644 index 0000000000..0c31506b61 Binary files /dev/null and b/internal/diagnostics/loc/ru-RU.json.gz differ diff --git a/internal/diagnostics/loc/tr-TR.json.gz b/internal/diagnostics/loc/tr-TR.json.gz new file mode 100644 index 0000000000..4ef9c4594f Binary files /dev/null and b/internal/diagnostics/loc/tr-TR.json.gz differ diff --git a/internal/diagnostics/loc/zh-CN.json.gz b/internal/diagnostics/loc/zh-CN.json.gz new file mode 100644 index 0000000000..9498a59ae0 Binary files /dev/null and b/internal/diagnostics/loc/zh-CN.json.gz differ diff --git a/internal/diagnostics/loc/zh-TW.json.gz b/internal/diagnostics/loc/zh-TW.json.gz new file mode 100644 index 0000000000..d95f48c53a Binary files /dev/null and b/internal/diagnostics/loc/zh-TW.json.gz differ diff --git a/internal/diagnostics/loc_generated.go b/internal/diagnostics/loc_generated.go new file mode 100644 index 0000000000..c71b3dcfe4 --- /dev/null +++ b/internal/diagnostics/loc_generated.go @@ -0,0 +1,151 @@ +// Code generated by generate.go; DO NOT EDIT. + +package diagnostics + +import ( + "compress/gzip" + _ "embed" + "strings" + "sync" + + "github.com/go-json-experiment/json" + "golang.org/x/text/language" +) + +var matcher = language.NewMatcher([]language.Tag{ + language.English, + language.MustParse("zh-CN"), + language.MustParse("zh-TW"), + language.MustParse("cs-CZ"), + language.MustParse("de-DE"), + language.MustParse("es-ES"), + language.MustParse("fr-FR"), + language.MustParse("it-IT"), + language.MustParse("ja-JP"), + language.MustParse("ko-KR"), + language.MustParse("pl-PL"), + language.MustParse("pt-BR"), + language.MustParse("ru-RU"), + language.MustParse("tr-TR"), +}) + +var localeFuncs = []func() map[Key]string{ + nil, // English (default) + zhCN, + zhTW, + csCZ, + deDE, + esES, + frFR, + itIT, + jaJP, + koKR, + plPL, + ptBR, + ruRU, + trTR, +} + +func loadLocaleData(data string) map[Key]string { + gr, err := gzip.NewReader(strings.NewReader(data)) + if err != nil { + panic("failed to create gzip reader: " + err.Error()) + } + defer gr.Close() + var result map[Key]string + if err := json.UnmarshalRead(gr, &result); err != nil { + panic("failed to unmarshal locale data: " + err.Error()) + } + return result +} + +//go:embed loc/zh-CN.json.gz +var zhCNData string + +var zhCN = sync.OnceValue(func() map[Key]string { + return loadLocaleData(zhCNData) +}) + +//go:embed loc/zh-TW.json.gz +var zhTWData string + +var zhTW = sync.OnceValue(func() map[Key]string { + return loadLocaleData(zhTWData) +}) + +//go:embed loc/cs-CZ.json.gz +var csCZData string + +var csCZ = sync.OnceValue(func() map[Key]string { + return loadLocaleData(csCZData) +}) + +//go:embed loc/de-DE.json.gz +var deDEData string + +var deDE = sync.OnceValue(func() map[Key]string { + return loadLocaleData(deDEData) +}) + +//go:embed loc/es-ES.json.gz +var esESData string + +var esES = sync.OnceValue(func() map[Key]string { + return loadLocaleData(esESData) +}) + +//go:embed loc/fr-FR.json.gz +var frFRData string + +var frFR = sync.OnceValue(func() map[Key]string { + return loadLocaleData(frFRData) +}) + +//go:embed loc/it-IT.json.gz +var itITData string + +var itIT = sync.OnceValue(func() map[Key]string { + return loadLocaleData(itITData) +}) + +//go:embed loc/ja-JP.json.gz +var jaJPData string + +var jaJP = sync.OnceValue(func() map[Key]string { + return loadLocaleData(jaJPData) +}) + +//go:embed loc/ko-KR.json.gz +var koKRData string + +var koKR = sync.OnceValue(func() map[Key]string { + return loadLocaleData(koKRData) +}) + +//go:embed loc/pl-PL.json.gz +var plPLData string + +var plPL = sync.OnceValue(func() map[Key]string { + return loadLocaleData(plPLData) +}) + +//go:embed loc/pt-BR.json.gz +var ptBRData string + +var ptBR = sync.OnceValue(func() map[Key]string { + return loadLocaleData(ptBRData) +}) + +//go:embed loc/ru-RU.json.gz +var ruRUData string + +var ruRU = sync.OnceValue(func() map[Key]string { + return loadLocaleData(ruRUData) +}) + +//go:embed loc/tr-TR.json.gz +var trTRData string + +var trTR = sync.OnceValue(func() map[Key]string { + return loadLocaleData(trTRData) +}) diff --git a/internal/diagnosticwriter/diagnosticwriter.go b/internal/diagnosticwriter/diagnosticwriter.go index 9609aa3789..2ac8c2e268 100644 --- a/internal/diagnosticwriter/diagnosticwriter.go +++ b/internal/diagnosticwriter/diagnosticwriter.go @@ -12,6 +12,7 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnostics" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/scanner" "github.com/microsoft/typescript-go/internal/tspath" ) @@ -30,7 +31,7 @@ type Diagnostic interface { Len() int Code() int32 Category() diagnostics.Category - Message() string + Localize(locale locale.Locale) string MessageChain() []Diagnostic RelatedInformation() []Diagnostic } @@ -98,6 +99,7 @@ func CompareASTDiagnostics(a, b *ASTDiagnostic) int { } type FormattingOptions struct { + Locale locale.Locale tspath.ComparePathsOptions NewLine string } @@ -139,7 +141,7 @@ func FormatDiagnosticWithColorAndContext(output io.Writer, diagnostic Diagnostic writeWithStyleAndReset(output, diagnostic.Category().Name(), getCategoryFormat(diagnostic.Category())) fmt.Fprintf(output, "%s TS%d: %s", foregroundColorEscapeGrey, diagnostic.Code(), resetEscapeSequence) - WriteFlattenedDiagnosticMessage(output, diagnostic, formatOpts.NewLine) + WriteFlattenedDiagnosticMessage(output, diagnostic, formatOpts.NewLine, formatOpts.Locale) if diagnostic.File() != nil && diagnostic.Code() != diagnostics.File_appears_to_be_binary.Code() { fmt.Fprint(output, formatOpts.NewLine) @@ -156,7 +158,7 @@ func FormatDiagnosticWithColorAndContext(output io.Writer, diagnostic Diagnostic pos := relatedInformation.Pos() WriteLocation(output, file, pos, formatOpts, writeWithStyleAndReset) fmt.Fprint(output, " - ") - WriteFlattenedDiagnosticMessage(output, relatedInformation, formatOpts.NewLine) + WriteFlattenedDiagnosticMessage(output, relatedInformation, formatOpts.NewLine, formatOpts.Locale) writeCodeSnippet(output, file, pos, relatedInformation.Len(), foregroundColorEscapeCyan, " ", formatOpts) } fmt.Fprint(output, formatOpts.NewLine) @@ -248,33 +250,33 @@ func writeCodeSnippet(writer io.Writer, sourceFile FileLike, start int, length i } } -func FlattenDiagnosticMessage(d Diagnostic, newLine string) string { +func FlattenDiagnosticMessage(d Diagnostic, newLine string, locale locale.Locale) string { var output strings.Builder - WriteFlattenedDiagnosticMessage(&output, d, newLine) + WriteFlattenedDiagnosticMessage(&output, d, newLine, locale) return output.String() } -func WriteFlattenedASTDiagnosticMessage(writer io.Writer, diagnostic *ast.Diagnostic, newline string) { - WriteFlattenedDiagnosticMessage(writer, WrapASTDiagnostic(diagnostic), newline) +func WriteFlattenedASTDiagnosticMessage(writer io.Writer, diagnostic *ast.Diagnostic, newline string, locale locale.Locale) { + WriteFlattenedDiagnosticMessage(writer, WrapASTDiagnostic(diagnostic), newline, locale) } -func WriteFlattenedDiagnosticMessage(writer io.Writer, diagnostic Diagnostic, newline string) { - fmt.Fprint(writer, diagnostic.Message()) +func WriteFlattenedDiagnosticMessage(writer io.Writer, diagnostic Diagnostic, newline string, locale locale.Locale) { + fmt.Fprint(writer, diagnostic.Localize(locale)) for _, chain := range diagnostic.MessageChain() { - flattenDiagnosticMessageChain(writer, chain, newline, 1 /*level*/) + flattenDiagnosticMessageChain(writer, chain, newline, locale, 1 /*level*/) } } -func flattenDiagnosticMessageChain(writer io.Writer, chain Diagnostic, newLine string, level int) { +func flattenDiagnosticMessageChain(writer io.Writer, chain Diagnostic, newLine string, locale locale.Locale, level int) { fmt.Fprint(writer, newLine) for range level { fmt.Fprint(writer, " ") } - fmt.Fprint(writer, chain.Message()) + fmt.Fprint(writer, chain.Localize(locale)) for _, child := range chain.MessageChain() { - flattenDiagnosticMessageChain(writer, child, newLine, level+1) + flattenDiagnosticMessageChain(writer, child, newLine, locale, level+1) } } @@ -345,21 +347,21 @@ func WriteErrorSummaryText(output io.Writer, allDiagnostics []Diagnostic, format if totalErrorCount == 1 { // Special-case a single error. if len(errorSummary.GlobalErrors) > 0 || firstFileName == "" { - message = diagnostics.Found_1_error.Format() + message = diagnostics.Found_1_error.Localize(formatOpts.Locale) } else { - message = diagnostics.Found_1_error_in_0.Format(firstFileName) + message = diagnostics.Found_1_error_in_0.Localize(formatOpts.Locale, firstFileName) } } else { switch numErroringFiles { case 0: // No file-specific errors. - message = diagnostics.Found_0_errors.Format(totalErrorCount) + message = diagnostics.Found_0_errors.Localize(formatOpts.Locale, totalErrorCount) case 1: // One file with errors. - message = diagnostics.Found_0_errors_in_the_same_file_starting_at_Colon_1.Format(totalErrorCount, firstFileName) + message = diagnostics.Found_0_errors_in_the_same_file_starting_at_Colon_1.Localize(formatOpts.Locale, totalErrorCount, firstFileName) default: // Multiple files with errors. - message = diagnostics.Found_0_errors_in_1_files.Format(totalErrorCount, numErroringFiles) + message = diagnostics.Found_0_errors_in_1_files.Localize(formatOpts.Locale, totalErrorCount, numErroringFiles) } } fmt.Fprint(output, formatOpts.NewLine) @@ -418,7 +420,7 @@ func writeTabularErrorsDisplay(output io.Writer, errorSummary *ErrorSummary, for // !!! // TODO (drosen): This was never localized. // Should make this better. - headerRow := diagnostics.Errors_Files.Message() + headerRow := diagnostics.Errors_Files.Localize(formatOpts.Locale) leftColumnHeadingLength := len(strings.Split(headerRow, " ")[0]) lengthOfBiggestErrorCount := len(strconv.Itoa(maxErrors)) leftPaddingGoal := max(leftColumnHeadingLength, lengthOfBiggestErrorCount) @@ -470,7 +472,7 @@ func WriteFormatDiagnostic(output io.Writer, diagnostic Diagnostic, formatOpts * } fmt.Fprintf(output, "%s TS%d: ", diagnostic.Category().Name(), diagnostic.Code()) - WriteFlattenedDiagnosticMessage(output, diagnostic, formatOpts.NewLine) + WriteFlattenedDiagnosticMessage(output, diagnostic, formatOpts.NewLine, formatOpts.Locale) fmt.Fprint(output, formatOpts.NewLine) } @@ -478,12 +480,12 @@ func FormatDiagnosticsStatusWithColorAndTime(output io.Writer, time string, diag fmt.Fprint(output, "[") writeWithStyleAndReset(output, time, foregroundColorEscapeGrey) fmt.Fprint(output, "] ") - WriteFlattenedDiagnosticMessage(output, diag, formatOpts.NewLine) + WriteFlattenedDiagnosticMessage(output, diag, formatOpts.NewLine, formatOpts.Locale) } func FormatDiagnosticsStatusAndTime(output io.Writer, time string, diag Diagnostic, formatOpts *FormattingOptions) { fmt.Fprint(output, time, " - ") - WriteFlattenedDiagnosticMessage(output, diag, formatOpts.NewLine) + WriteFlattenedDiagnosticMessage(output, diag, formatOpts.NewLine, formatOpts.Locale) } var ScreenStartingCodes = []int32{ diff --git a/internal/execute/build/buildtask.go b/internal/execute/build/buildtask.go index 2638fd240a..3ead8e4fe2 100644 --- a/internal/execute/build/buildtask.go +++ b/internal/execute/build/buildtask.go @@ -220,7 +220,7 @@ func (t *BuildTask) compileAndEmit(orchestrator *Orchestrator, path tspath.Path) Config: t.resolved, Host: &compilerHost{ host: orchestrator.host, - trace: tsc.GetTraceWithWriterFromSys(&t.result.builder, orchestrator.opts.Testing), + trace: tsc.GetTraceWithWriterFromSys(&t.result.builder, orchestrator.opts.Command.Locale(), orchestrator.opts.Testing), }, JSDocParsingMode: ast.JSDocParsingModeParseForTypeErrors, }) diff --git a/internal/execute/build/compilerHost.go b/internal/execute/build/compilerHost.go index f11f06b9fc..3004c4cca7 100644 --- a/internal/execute/build/compilerHost.go +++ b/internal/execute/build/compilerHost.go @@ -3,6 +3,7 @@ package build import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/compiler" + "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/tsoptions" "github.com/microsoft/typescript-go/internal/tspath" "github.com/microsoft/typescript-go/internal/vfs" @@ -10,7 +11,7 @@ import ( type compilerHost struct { host *host - trace func(msg string) + trace func(msg *diagnostics.Message, args ...any) } var _ compiler.CompilerHost = (*compilerHost)(nil) @@ -27,8 +28,8 @@ func (h *compilerHost) GetCurrentDirectory() string { return h.host.GetCurrentDirectory() } -func (h *compilerHost) Trace(msg string) { - h.trace(msg) +func (h *compilerHost) Trace(msg *diagnostics.Message, args ...any) { + h.trace(msg, args...) } func (h *compilerHost) GetSourceFile(opts ast.SourceFileParseOptions) *ast.SourceFile { diff --git a/internal/execute/build/host.go b/internal/execute/build/host.go index 91f50aa59c..85e2a25e08 100644 --- a/internal/execute/build/host.go +++ b/internal/execute/build/host.go @@ -6,6 +6,7 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/compiler" + "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/execute/incremental" "github.com/microsoft/typescript-go/internal/execute/tsc" "github.com/microsoft/typescript-go/internal/tsoptions" @@ -45,7 +46,7 @@ func (h *host) GetCurrentDirectory() string { return h.host.GetCurrentDirectory() } -func (h *host) Trace(msg string) { +func (h *host) Trace(msg *diagnostics.Message, args ...any) { panic("build.Orchestrator.host does not support tracing, use a different host for tracing") } diff --git a/internal/execute/build/orchestrator.go b/internal/execute/build/orchestrator.go index f89f39d3f3..af59265532 100644 --- a/internal/execute/build/orchestrator.go +++ b/internal/execute/build/orchestrator.go @@ -364,11 +364,11 @@ func (o *Orchestrator) getWriter(task *BuildTask) io.Writer { } func (o *Orchestrator) createBuilderStatusReporter(task *BuildTask) tsc.DiagnosticReporter { - return tsc.CreateBuilderStatusReporter(o.opts.Sys, o.getWriter(task), o.opts.Command.CompilerOptions, o.opts.Testing) + return tsc.CreateBuilderStatusReporter(o.opts.Sys, o.getWriter(task), o.opts.Command.Locale(), o.opts.Command.CompilerOptions, o.opts.Testing) } func (o *Orchestrator) createDiagnosticReporter(task *BuildTask) tsc.DiagnosticReporter { - return tsc.CreateDiagnosticReporter(o.opts.Sys, o.getWriter(task), o.opts.Command.CompilerOptions) + return tsc.CreateDiagnosticReporter(o.opts.Sys, o.getWriter(task), o.opts.Command.Locale(), o.opts.Command.CompilerOptions) } func NewOrchestrator(opts Options) *Orchestrator { @@ -392,9 +392,9 @@ func NewOrchestrator(opts Options) *Orchestrator { mTimes: &collections.SyncMap[tspath.Path, time.Time]{}, } if opts.Command.CompilerOptions.Watch.IsTrue() { - orchestrator.watchStatusReporter = tsc.CreateWatchStatusReporter(opts.Sys, opts.Command.CompilerOptions, opts.Testing) + orchestrator.watchStatusReporter = tsc.CreateWatchStatusReporter(opts.Sys, opts.Command.Locale(), opts.Command.CompilerOptions, opts.Testing) } else { - orchestrator.errorSummaryReporter = tsc.CreateReportErrorSummary(opts.Sys, opts.Command.CompilerOptions) + orchestrator.errorSummaryReporter = tsc.CreateReportErrorSummary(opts.Sys, opts.Command.Locale(), opts.Command.CompilerOptions) } return orchestrator } diff --git a/internal/execute/incremental/buildInfo.go b/internal/execute/incremental/buildInfo.go index 36cfb0a9ca..73d9f0849a 100644 --- a/internal/execute/incremental/buildInfo.go +++ b/internal/execute/incremental/buildInfo.go @@ -201,7 +201,8 @@ type BuildInfoDiagnostic struct { End int `json:"end,omitzero"` Code int32 `json:"code,omitzero"` Category diagnostics.Category `json:"category,omitzero"` - Message string `json:"message,omitzero"` + MessageKey diagnostics.Key `json:"messageKey,omitzero"` + MessageArgs []string `json:"messageArgs,omitzero"` MessageChain []*BuildInfoDiagnostic `json:"messageChain,omitzero"` RelatedInformation []*BuildInfoDiagnostic `json:"relatedInformation,omitzero"` ReportsUnnecessary bool `json:"reportsUnnecessary,omitzero"` diff --git a/internal/execute/incremental/buildinfotosnapshot.go b/internal/execute/incremental/buildinfotosnapshot.go index ba11a95cc5..7a10212771 100644 --- a/internal/execute/incremental/buildinfotosnapshot.go +++ b/internal/execute/incremental/buildinfotosnapshot.go @@ -79,7 +79,8 @@ func (t *toSnapshot) toBuildInfoDiagnosticsWithFileName(diagnostics []*BuildInfo end: d.End, code: d.Code, category: d.Category, - message: d.Message, + messageKey: d.MessageKey, + messageArgs: d.MessageArgs, messageChain: t.toBuildInfoDiagnosticsWithFileName(d.MessageChain), relatedInformation: t.toBuildInfoDiagnosticsWithFileName(d.RelatedInformation), reportsUnnecessary: d.ReportsUnnecessary, diff --git a/internal/execute/incremental/snapshot.go b/internal/execute/incremental/snapshot.go index 9ef4fdd0d8..33e2351a3e 100644 --- a/internal/execute/incremental/snapshot.go +++ b/internal/execute/incremental/snapshot.go @@ -137,7 +137,8 @@ type buildInfoDiagnosticWithFileName struct { end int code int32 category diagnostics.Category - message string + messageKey diagnostics.Key + messageArgs []string messageChain []*buildInfoDiagnosticWithFileName relatedInformation []*buildInfoDiagnosticWithFileName reportsUnnecessary bool @@ -165,12 +166,13 @@ func (b *buildInfoDiagnosticWithFileName) toDiagnostic(p *compiler.Program, file for _, info := range b.relatedInformation { relatedInformation = append(relatedInformation, info.toDiagnostic(p, fileForDiagnostic)) } - return ast.NewDiagnosticWith( + return ast.NewDiagnosticFromSerialized( fileForDiagnostic, core.NewTextRange(b.pos, b.end), b.code, b.category, - b.message, + b.messageKey, + b.messageArgs, messageChain, relatedInformation, b.reportsUnnecessary, @@ -301,7 +303,12 @@ func diagnosticToStringBuilder(diagnostic *ast.Diagnostic, file *ast.SourceFile, } builder.WriteString(diagnostic.Category().Name()) builder.WriteString(fmt.Sprintf("%d: ", diagnostic.Code())) - builder.WriteString(diagnostic.Message()) + builder.WriteString(string(diagnostic.MessageKey())) + builder.WriteString("\n") + for _, arg := range diagnostic.MessageArgs() { + builder.WriteString(arg) + builder.WriteString("\n") + } for _, chain := range diagnostic.MessageChain() { diagnosticToStringBuilder(chain, file, builder) } diff --git a/internal/execute/incremental/snapshottobuildinfo.go b/internal/execute/incremental/snapshottobuildinfo.go index 57896db66d..fc83153362 100644 --- a/internal/execute/incremental/snapshottobuildinfo.go +++ b/internal/execute/incremental/snapshottobuildinfo.go @@ -128,7 +128,8 @@ func (t *toBuildInfo) toBuildInfoDiagnosticsFromFileNameDiagnostics(diagnostics End: d.end, Code: d.code, Category: d.category, - Message: d.message, + MessageKey: d.messageKey, + MessageArgs: d.messageArgs, MessageChain: t.toBuildInfoDiagnosticsFromFileNameDiagnostics(d.messageChain), RelatedInformation: t.toBuildInfoDiagnosticsFromFileNameDiagnostics(d.relatedInformation), ReportsUnnecessary: d.reportsUnnecessary, @@ -154,7 +155,8 @@ func (t *toBuildInfo) toBuildInfoDiagnosticsFromDiagnostics(filePath tspath.Path End: d.Loc().End(), Code: d.Code(), Category: d.Category(), - Message: d.Message(), + MessageKey: d.MessageKey(), + MessageArgs: d.MessageArgs(), MessageChain: t.toBuildInfoDiagnosticsFromDiagnostics(filePath, d.MessageChain()), RelatedInformation: t.toBuildInfoDiagnosticsFromDiagnostics(filePath, d.RelatedInformation()), ReportsUnnecessary: d.ReportsUnnecessary(), diff --git a/internal/execute/tsc.go b/internal/execute/tsc.go index 48dc1deb83..d68a31e3a3 100644 --- a/internal/execute/tsc.go +++ b/internal/execute/tsc.go @@ -15,6 +15,7 @@ import ( "github.com/microsoft/typescript-go/internal/execute/tsc" "github.com/microsoft/typescript-go/internal/format" "github.com/microsoft/typescript-go/internal/jsonutil" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/parser" "github.com/microsoft/typescript-go/internal/pprof" "github.com/microsoft/typescript-go/internal/tsoptions" @@ -61,11 +62,8 @@ func fmtMain(sys tsc.System, input, output string) tsc.ExitStatus { } func tscBuildCompilation(sys tsc.System, buildCommand *tsoptions.ParsedBuildCommandLine, testing tsc.CommandLineTesting) tsc.CommandLineResult { - reportDiagnostic := tsc.CreateDiagnosticReporter(sys, sys.Writer(), buildCommand.CompilerOptions) - - // if (buildOptions.locale) { - // validateLocaleAndSetLanguage(buildOptions.locale, sys, errors); - // } + locale := buildCommand.Locale() + reportDiagnostic := tsc.CreateDiagnosticReporter(sys, sys.Writer(), locale, buildCommand.CompilerOptions) if len(buildCommand.Errors) > 0 { for _, err := range buildCommand.Errors { @@ -81,8 +79,8 @@ func tscBuildCompilation(sys tsc.System, buildCommand *tsoptions.ParsedBuildComm } if buildCommand.CompilerOptions.Help.IsTrue() { - tsc.PrintVersion(sys) - tsc.PrintBuildHelp(sys, tsoptions.BuildOpts) + tsc.PrintVersion(sys, locale) + tsc.PrintBuildHelp(sys, locale, tsoptions.BuildOpts) return tsc.CommandLineResult{Status: tsc.ExitStatusSuccess} } @@ -96,8 +94,8 @@ func tscBuildCompilation(sys tsc.System, buildCommand *tsoptions.ParsedBuildComm func tscCompilation(sys tsc.System, commandLine *tsoptions.ParsedCommandLine, testing tsc.CommandLineTesting) tsc.CommandLineResult { configFileName := "" - reportDiagnostic := tsc.CreateDiagnosticReporter(sys, sys.Writer(), commandLine.CompilerOptions()) - // if commandLine.Options().Locale != nil + locale := commandLine.Locale() + reportDiagnostic := tsc.CreateDiagnosticReporter(sys, sys.Writer(), locale, commandLine.CompilerOptions()) if len(commandLine.Errors) > 0 { for _, e := range commandLine.Errors { @@ -113,17 +111,17 @@ func tscCompilation(sys tsc.System, commandLine *tsoptions.ParsedCommandLine, te } if commandLine.CompilerOptions().Init.IsTrue() { - tsc.WriteConfigFile(sys, reportDiagnostic, commandLine.Raw.(*collections.OrderedMap[string, any])) + tsc.WriteConfigFile(sys, locale, reportDiagnostic, commandLine.Raw.(*collections.OrderedMap[string, any])) return tsc.CommandLineResult{Status: tsc.ExitStatusSuccess} } if commandLine.CompilerOptions().Version.IsTrue() { - tsc.PrintVersion(sys) + tsc.PrintVersion(sys, locale) return tsc.CommandLineResult{Status: tsc.ExitStatusSuccess} } if commandLine.CompilerOptions().Help.IsTrue() || commandLine.CompilerOptions().All.IsTrue() { - tsc.PrintHelp(sys, commandLine) + tsc.PrintHelp(sys, locale, commandLine) return tsc.CommandLineResult{Status: tsc.ExitStatusSuccess} } @@ -161,8 +159,8 @@ func tscCompilation(sys tsc.System, commandLine *tsoptions.ParsedCommandLine, te if commandLine.CompilerOptions().ShowConfig.IsTrue() { reportDiagnostic(ast.NewCompilerDiagnostic(diagnostics.Cannot_find_a_tsconfig_json_file_at_the_current_directory_Colon_0, tspath.NormalizePath(sys.GetCurrentDirectory()))) } else { - tsc.PrintVersion(sys) - tsc.PrintHelp(sys, commandLine) + tsc.PrintVersion(sys, locale) + tsc.PrintHelp(sys, locale, commandLine) } return tsc.CommandLineResult{Status: tsc.ExitStatusDiagnosticsPresent_OutputsSkipped} } @@ -185,10 +183,10 @@ func tscCompilation(sys tsc.System, commandLine *tsoptions.ParsedCommandLine, te } configForCompilation = configParseResult // Updater to reflect pretty - reportDiagnostic = tsc.CreateDiagnosticReporter(sys, sys.Writer(), commandLine.CompilerOptions()) + reportDiagnostic = tsc.CreateDiagnosticReporter(sys, sys.Writer(), locale, commandLine.CompilerOptions()) } - reportErrorSummary := tsc.CreateReportErrorSummary(sys, configForCompilation.CompilerOptions()) + reportErrorSummary := tsc.CreateReportErrorSummary(sys, locale, configForCompilation.CompilerOptions()) if compilerOptionsFromCommandLine.ShowConfig.IsTrue() { showConfig(sys, configForCompilation.CompilerOptions()) return tsc.CommandLineResult{Status: tsc.ExitStatusSuccess} @@ -240,8 +238,8 @@ func findConfigFile(searchPath string, fileExists func(string) bool, configName return result } -func getTraceFromSys(sys tsc.System, testing tsc.CommandLineTesting) func(msg string) { - return tsc.GetTraceWithWriterFromSys(sys.Writer(), testing) +func getTraceFromSys(sys tsc.System, locale locale.Locale, testing tsc.CommandLineTesting) func(msg *diagnostics.Message, args ...any) { + return tsc.GetTraceWithWriterFromSys(sys.Writer(), locale, testing) } func performIncrementalCompilation( @@ -253,7 +251,7 @@ func performIncrementalCompilation( compileTimes *tsc.CompileTimes, testing tsc.CommandLineTesting, ) tsc.CommandLineResult { - host := compiler.NewCachedFSCompilerHost(sys.GetCurrentDirectory(), sys.FS(), sys.DefaultLibraryPath(), extendedConfigCache, getTraceFromSys(sys, testing)) + host := compiler.NewCachedFSCompilerHost(sys.GetCurrentDirectory(), sys.FS(), sys.DefaultLibraryPath(), extendedConfigCache, getTraceFromSys(sys, config.Locale(), testing)) buildInfoReadStart := sys.Now() oldProgram := incremental.ReadBuildInfoProgram(config, incremental.NewBuildInfoReader(host), host) compileTimes.BuildInfoReadTime = sys.Now().Sub(buildInfoReadStart) @@ -296,7 +294,7 @@ func performCompilation( compileTimes *tsc.CompileTimes, testing tsc.CommandLineTesting, ) tsc.CommandLineResult { - host := compiler.NewCachedFSCompilerHost(sys.GetCurrentDirectory(), sys.FS(), sys.DefaultLibraryPath(), extendedConfigCache, getTraceFromSys(sys, testing)) + host := compiler.NewCachedFSCompilerHost(sys.GetCurrentDirectory(), sys.FS(), sys.DefaultLibraryPath(), extendedConfigCache, getTraceFromSys(sys, config.Locale(), testing)) // todo: cache, statistics, tracing parseStart := sys.Now() program := compiler.NewProgram(compiler.ProgramOptions{ diff --git a/internal/execute/tsc/compile.go b/internal/execute/tsc/compile.go index 4adc1df9e9..4fdd27f7c2 100644 --- a/internal/execute/tsc/compile.go +++ b/internal/execute/tsc/compile.go @@ -7,7 +7,9 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/compiler" + "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/execute/incremental" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/tspath" "github.com/microsoft/typescript-go/internal/vfs" ) @@ -56,7 +58,7 @@ type CommandLineTesting interface { OnBuildStatusReportEnd(w io.Writer) OnWatchStatusReportStart() OnWatchStatusReportEnd() - GetTrace(w io.Writer) func(msg string) + GetTrace(w io.Writer, locale locale.Locale) func(msg *diagnostics.Message, args ...any) OnProgram(program *incremental.Program) } diff --git a/internal/execute/tsc/diagnostics.go b/internal/execute/tsc/diagnostics.go index 76992e2417..5a3d752a02 100644 --- a/internal/execute/tsc/diagnostics.go +++ b/internal/execute/tsc/diagnostics.go @@ -8,16 +8,18 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnosticwriter" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/tspath" ) -func getFormatOptsOfSys(sys System) *diagnosticwriter.FormattingOptions { +func getFormatOptsOfSys(sys System, locale locale.Locale) *diagnosticwriter.FormattingOptions { return &diagnosticwriter.FormattingOptions{ NewLine: "\n", ComparePathsOptions: tspath.ComparePathsOptions{ CurrentDirectory: sys.GetCurrentDirectory(), UseCaseSensitiveFileNames: sys.FS().UseCaseSensitiveFileNames(), }, + Locale: locale, } } @@ -25,11 +27,11 @@ type DiagnosticReporter = func(*ast.Diagnostic) func QuietDiagnosticReporter(diagnostic *ast.Diagnostic) {} -func CreateDiagnosticReporter(sys System, w io.Writer, options *core.CompilerOptions) DiagnosticReporter { +func CreateDiagnosticReporter(sys System, w io.Writer, locale locale.Locale, options *core.CompilerOptions) DiagnosticReporter { if options.Quiet.IsTrue() { return QuietDiagnosticReporter } - formatOpts := getFormatOptsOfSys(sys) + formatOpts := getFormatOptsOfSys(sys, locale) if shouldBePretty(sys, options) { return func(diagnostic *ast.Diagnostic) { diagnosticwriter.FormatDiagnosticWithColorAndContext(w, diagnosticwriter.WrapASTDiagnostic(diagnostic), formatOpts) @@ -123,9 +125,9 @@ type DiagnosticsReporter = func(diagnostics []*ast.Diagnostic) func QuietDiagnosticsReporter(diagnostics []*ast.Diagnostic) {} -func CreateReportErrorSummary(sys System, options *core.CompilerOptions) DiagnosticsReporter { +func CreateReportErrorSummary(sys System, locale locale.Locale, options *core.CompilerOptions) DiagnosticsReporter { if shouldBePretty(sys, options) { - formatOpts := getFormatOptsOfSys(sys) + formatOpts := getFormatOptsOfSys(sys, locale) return func(diagnostics []*ast.Diagnostic) { diagnosticwriter.WriteErrorSummaryText(sys.Writer(), diagnosticwriter.FromASTDiagnostics(diagnostics), formatOpts) } @@ -133,12 +135,12 @@ func CreateReportErrorSummary(sys System, options *core.CompilerOptions) Diagnos return QuietDiagnosticsReporter } -func CreateBuilderStatusReporter(sys System, w io.Writer, options *core.CompilerOptions, testing CommandLineTesting) DiagnosticReporter { +func CreateBuilderStatusReporter(sys System, w io.Writer, locale locale.Locale, options *core.CompilerOptions, testing CommandLineTesting) DiagnosticReporter { if options.Quiet.IsTrue() { return QuietDiagnosticReporter } - formatOpts := getFormatOptsOfSys(sys) + formatOpts := getFormatOptsOfSys(sys, locale) writeStatus := core.IfElse(shouldBePretty(sys, options), diagnosticwriter.FormatDiagnosticsStatusWithColorAndTime, diagnosticwriter.FormatDiagnosticsStatusAndTime) return func(diagnostic *ast.Diagnostic) { writerDiagnostic := diagnosticwriter.WrapASTDiagnostic(diagnostic) @@ -151,8 +153,8 @@ func CreateBuilderStatusReporter(sys System, w io.Writer, options *core.Compiler } } -func CreateWatchStatusReporter(sys System, options *core.CompilerOptions, testing CommandLineTesting) DiagnosticReporter { - formatOpts := getFormatOptsOfSys(sys) +func CreateWatchStatusReporter(sys System, locale locale.Locale, options *core.CompilerOptions, testing CommandLineTesting) DiagnosticReporter { + formatOpts := getFormatOptsOfSys(sys, locale) writeStatus := core.IfElse(shouldBePretty(sys, options), diagnosticwriter.FormatDiagnosticsStatusWithColorAndTime, diagnosticwriter.FormatDiagnosticsStatusAndTime) return func(diagnostic *ast.Diagnostic) { writerDiagnostic := diagnosticwriter.WrapASTDiagnostic(diagnostic) diff --git a/internal/execute/tsc/emit.go b/internal/execute/tsc/emit.go index f03e25b14d..44dc673d96 100644 --- a/internal/execute/tsc/emit.go +++ b/internal/execute/tsc/emit.go @@ -10,17 +10,19 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/compiler" + "github.com/microsoft/typescript-go/internal/diagnostics" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/tsoptions" "github.com/microsoft/typescript-go/internal/tspath" ) -func GetTraceWithWriterFromSys(w io.Writer, testing CommandLineTesting) func(msg string) { +func GetTraceWithWriterFromSys(w io.Writer, locale locale.Locale, testing CommandLineTesting) func(msg *diagnostics.Message, args ...any) { if testing == nil { - return func(msg string) { - fmt.Fprintln(w, msg) + return func(msg *diagnostics.Message, args ...any) { + fmt.Fprintln(w, msg.Localize(locale, args...)) } } else { - return testing.GetTrace(w) + return testing.GetTrace(w, locale) } } @@ -133,7 +135,7 @@ func listFiles(input EmitInput, emitResult *compiler.EmitResult) { } } if options.ExplainFiles.IsTrue() { - input.Program.ExplainFiles(input.Writer) + input.Program.ExplainFiles(input.Writer, input.Config.Locale()) } else if options.ListFiles.IsTrue() || options.ListFilesOnly.IsTrue() { for _, file := range input.Program.GetSourceFiles() { fmt.Fprintln(input.Writer, file.FileName()) diff --git a/internal/execute/tsc/help.go b/internal/execute/tsc/help.go index a10eac843e..02e2b6d49c 100644 --- a/internal/execute/tsc/help.go +++ b/internal/execute/tsc/help.go @@ -8,18 +8,19 @@ import ( "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnostics" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/tsoptions" ) -func PrintVersion(sys System) { - fmt.Fprintln(sys.Writer(), diagnostics.Version_0.Format(core.Version())) +func PrintVersion(sys System, locale locale.Locale) { + fmt.Fprintln(sys.Writer(), diagnostics.Version_0.Localize(locale, core.Version())) } -func PrintHelp(sys System, commandLine *tsoptions.ParsedCommandLine) { +func PrintHelp(sys System, locale locale.Locale, commandLine *tsoptions.ParsedCommandLine) { if commandLine.CompilerOptions().All.IsFalseOrUnknown() { - printEasyHelp(sys, getOptionsForHelp(commandLine)) + printEasyHelp(sys, locale, getOptionsForHelp(commandLine)) } else { - printAllHelp(sys, getOptionsForHelp(commandLine)) + printAllHelp(sys, locale, getOptionsForHelp(commandLine)) } } @@ -63,20 +64,20 @@ func getHeader(sys System, message string) []string { return header } -func printEasyHelp(sys System, simpleOptions []*tsoptions.CommandLineOption) { +func printEasyHelp(sys System, locale locale.Locale, simpleOptions []*tsoptions.CommandLineOption) { colors := createColors(sys) var output []string example := func(examples []string, desc *diagnostics.Message) { for _, example := range examples { output = append(output, " ", colors.blue(example), "\n") } - output = append(output, " ", desc.Format(), "\n", "\n") + output = append(output, " ", desc.Localize(locale), "\n", "\n") } - msg := diagnostics.X_tsc_Colon_The_TypeScript_Compiler.Format() + " - " + diagnostics.Version_0.Format(core.Version()) + msg := diagnostics.X_tsc_Colon_The_TypeScript_Compiler.Localize(locale) + " - " + diagnostics.Version_0.Localize(locale, core.Version()) output = append(output, getHeader(sys, msg)...) - output = append(output, colors.bold(diagnostics.COMMON_COMMANDS.Format()), "\n", "\n") + output = append(output, colors.bold(diagnostics.COMMON_COMMANDS.Localize(locale)), "\n", "\n") example([]string{"tsc"}, diagnostics.Compiles_the_current_project_tsconfig_json_in_the_working_directory) example([]string{"tsc app.ts util.ts"}, diagnostics.Ignoring_tsconfig_json_compiles_the_specified_files_with_default_compiler_options) @@ -96,50 +97,49 @@ func printEasyHelp(sys System, simpleOptions []*tsoptions.CommandLineOption) { } } - output = append(output, generateSectionOptionsOutput(sys, diagnostics.COMMAND_LINE_FLAGS.Format(), cliCommands /*subCategory*/, false /*beforeOptionsDescription*/, nil /*afterOptionsDescription*/, nil)...) + output = append(output, generateSectionOptionsOutput(sys, locale, diagnostics.COMMAND_LINE_FLAGS.Localize(locale), cliCommands /*subCategory*/, false /*beforeOptionsDescription*/, nil /*afterOptionsDescription*/, nil)...) - // !!! locale formatMessage - after := diagnostics.You_can_learn_about_all_of_the_compiler_options_at_0.Format("https://aka.ms/tsc") - output = append(output, generateSectionOptionsOutput(sys, diagnostics.COMMON_COMPILER_OPTIONS.Format(), configOpts /*subCategory*/, false /*beforeOptionsDescription*/, nil, &after)...) + after := diagnostics.You_can_learn_about_all_of_the_compiler_options_at_0.Localize(locale, "https://aka.ms/tsc") + output = append(output, generateSectionOptionsOutput(sys, locale, diagnostics.COMMON_COMPILER_OPTIONS.Localize(locale), configOpts /*subCategory*/, false /*beforeOptionsDescription*/, nil, &after)...) for _, chunk := range output { fmt.Fprint(sys.Writer(), chunk) } } -func printAllHelp(sys System, options []*tsoptions.CommandLineOption) { +func printAllHelp(sys System, locale locale.Locale, options []*tsoptions.CommandLineOption) { var output []string - msg := diagnostics.X_tsc_Colon_The_TypeScript_Compiler.Format() + " - " + diagnostics.Version_0.Format(core.Version()) + msg := diagnostics.X_tsc_Colon_The_TypeScript_Compiler.Localize(locale) + " - " + diagnostics.Version_0.Localize(locale, core.Version()) output = append(output, getHeader(sys, msg)...) // ALL COMPILER OPTIONS section - afterCompilerOptions := diagnostics.You_can_learn_about_all_of_the_compiler_options_at_0.Format("https://aka.ms/tsc") - output = append(output, generateSectionOptionsOutput(sys, diagnostics.ALL_COMPILER_OPTIONS.Format(), options, true, nil, &afterCompilerOptions)...) + afterCompilerOptions := diagnostics.You_can_learn_about_all_of_the_compiler_options_at_0.Localize(locale, "https://aka.ms/tsc") + output = append(output, generateSectionOptionsOutput(sys, locale, diagnostics.ALL_COMPILER_OPTIONS.Localize(locale), options, true, nil, &afterCompilerOptions)...) // WATCH OPTIONS section - beforeWatchOptions := diagnostics.Including_watch_w_will_start_watching_the_current_project_for_the_file_changes_Once_set_you_can_config_watch_mode_with_Colon.Format() - output = append(output, generateSectionOptionsOutput(sys, diagnostics.WATCH_OPTIONS.Format(), tsoptions.OptionsForWatch, false, &beforeWatchOptions, nil)...) + beforeWatchOptions := diagnostics.Including_watch_w_will_start_watching_the_current_project_for_the_file_changes_Once_set_you_can_config_watch_mode_with_Colon.Localize(locale) + output = append(output, generateSectionOptionsOutput(sys, locale, diagnostics.WATCH_OPTIONS.Localize(locale), tsoptions.OptionsForWatch, false, &beforeWatchOptions, nil)...) // BUILD OPTIONS section - beforeBuildOptions := diagnostics.Using_build_b_will_make_tsc_behave_more_like_a_build_orchestrator_than_a_compiler_This_is_used_to_trigger_building_composite_projects_which_you_can_learn_more_about_at_0.Format("https://aka.ms/tsc-composite-builds") + beforeBuildOptions := diagnostics.Using_build_b_will_make_tsc_behave_more_like_a_build_orchestrator_than_a_compiler_This_is_used_to_trigger_building_composite_projects_which_you_can_learn_more_about_at_0.Localize(locale, "https://aka.ms/tsc-composite-builds") buildOptions := core.Filter(tsoptions.OptionsForBuild, func(option *tsoptions.CommandLineOption) bool { return option != &tsoptions.TscBuildOption }) - output = append(output, generateSectionOptionsOutput(sys, diagnostics.BUILD_OPTIONS.Format(), buildOptions, false, &beforeBuildOptions, nil)...) + output = append(output, generateSectionOptionsOutput(sys, locale, diagnostics.BUILD_OPTIONS.Localize(locale), buildOptions, false, &beforeBuildOptions, nil)...) for _, chunk := range output { fmt.Fprint(sys.Writer(), chunk) } } -func PrintBuildHelp(sys System, buildOptions []*tsoptions.CommandLineOption) { +func PrintBuildHelp(sys System, locale locale.Locale, buildOptions []*tsoptions.CommandLineOption) { var output []string - output = append(output, getHeader(sys, diagnostics.X_tsc_Colon_The_TypeScript_Compiler.Format()+" - "+diagnostics.Version_0.Format(core.Version()))...) - before := diagnostics.Using_build_b_will_make_tsc_behave_more_like_a_build_orchestrator_than_a_compiler_This_is_used_to_trigger_building_composite_projects_which_you_can_learn_more_about_at_0.Format("https://aka.ms/tsc-composite-builds") + output = append(output, getHeader(sys, diagnostics.X_tsc_Colon_The_TypeScript_Compiler.Localize(locale)+" - "+diagnostics.Version_0.Localize(locale, core.Version()))...) + before := diagnostics.Using_build_b_will_make_tsc_behave_more_like_a_build_orchestrator_than_a_compiler_This_is_used_to_trigger_building_composite_projects_which_you_can_learn_more_about_at_0.Localize(locale, "https://aka.ms/tsc-composite-builds") options := core.Filter(buildOptions, func(option *tsoptions.CommandLineOption) bool { return option != &tsoptions.TscBuildOption }) - output = append(output, generateSectionOptionsOutput(sys, diagnostics.BUILD_OPTIONS.Format(), options, false, &before, nil)...) + output = append(output, generateSectionOptionsOutput(sys, locale, diagnostics.BUILD_OPTIONS.Localize(locale), options, false, &before, nil)...) for _, chunk := range output { fmt.Fprint(sys.Writer(), chunk) @@ -148,6 +148,7 @@ func PrintBuildHelp(sys System, buildOptions []*tsoptions.CommandLineOption) { func generateSectionOptionsOutput( sys System, + locale locale.Locale, sectionName string, options []*tsoptions.CommandLineOption, subCategory bool, @@ -160,7 +161,7 @@ func generateSectionOptionsOutput( output = append(output, *beforeOptionsDescription, "\n", "\n") } if !subCategory { - output = append(output, generateGroupOptionOutput(sys, options)...) + output = append(output, generateGroupOptionOutput(sys, locale, options)...) if afterOptionsDescription != nil { output = append(output, *afterOptionsDescription, "\n", "\n") } @@ -172,7 +173,7 @@ func generateSectionOptionsOutput( if option.Category == nil { continue } - curCategory := option.Category.Format() + curCategory := option.Category.Localize(locale) if _, exists := categoryMap[curCategory]; !exists { categoryOrder = append(categoryOrder, curCategory) } @@ -181,7 +182,7 @@ func generateSectionOptionsOutput( for _, key := range categoryOrder { value := categoryMap[key] output = append(output, "### ", key, "\n", "\n") - output = append(output, generateGroupOptionOutput(sys, value)...) + output = append(output, generateGroupOptionOutput(sys, locale, value)...) } if afterOptionsDescription != nil { output = append(output, *afterOptionsDescription, "\n", "\n") @@ -190,7 +191,7 @@ func generateSectionOptionsOutput( return output } -func generateGroupOptionOutput(sys System, optionsList []*tsoptions.CommandLineOption) []string { +func generateGroupOptionOutput(sys System, locale locale.Locale, optionsList []*tsoptions.CommandLineOption) []string { var maxLength int for _, option := range optionsList { curLenght := len(getDisplayNameTextOfOption(option)) @@ -206,7 +207,7 @@ func generateGroupOptionOutput(sys System, optionsList []*tsoptions.CommandLineO var lines []string for _, option := range optionsList { - tmp := generateOptionOutput(sys, option, rightAlignOfLeftPart, leftAlignOfRightPart) + tmp := generateOptionOutput(sys, locale, option, rightAlignOfLeftPart, leftAlignOfRightPart) lines = append(lines, tmp...) } @@ -220,6 +221,7 @@ func generateGroupOptionOutput(sys System, optionsList []*tsoptions.CommandLineO func generateOptionOutput( sys System, + locale locale.Locale, option *tsoptions.CommandLineOption, rightAlignOfLeft, leftAlignOfRight int, ) []string { @@ -230,11 +232,11 @@ func generateOptionOutput( name := getDisplayNameTextOfOption(option) // value type and possible value - valueCandidates := getValueCandidate(option) + valueCandidates := getValueCandidate(sys, locale, option) var defaultValueDescription string if msg, ok := option.DefaultValueDescription.(*diagnostics.Message); ok && msg != nil { - defaultValueDescription = msg.Format() + defaultValueDescription = msg.Localize(locale) } else { defaultValueDescription = formatDefaultValue( option.DefaultValueDescription, @@ -250,7 +252,7 @@ func generateOptionOutput( if terminalWidth >= 80 { description := "" if option.Description != nil { - description = option.Description.Format() + description = option.Description.Localize(locale) } text = append(text, getPrettyOutput(colors, name, description, rightAlignOfLeft, leftAlignOfRight, terminalWidth, true /*colorLeft*/)...) text = append(text, "\n") @@ -260,7 +262,7 @@ func generateOptionOutput( text = append(text, "\n") } if defaultValueDescription != "" { - text = append(text, getPrettyOutput(colors, diagnostics.X_default_Colon.Format(), defaultValueDescription, rightAlignOfLeft, leftAlignOfRight, terminalWidth, false /*colorLeft*/)...) + text = append(text, getPrettyOutput(colors, diagnostics.X_default_Colon.Localize(locale), defaultValueDescription, rightAlignOfLeft, leftAlignOfRight, terminalWidth, false /*colorLeft*/)...) text = append(text, "\n") } } @@ -268,7 +270,7 @@ func generateOptionOutput( } else { text = append(text, colors.blue(name), "\n") if option.Description != nil { - text = append(text, option.Description.Format()) + text = append(text, option.Description.Localize(locale)) } text = append(text, "\n") if showAdditionalInfoOutput(valueCandidates, option) { @@ -279,7 +281,7 @@ func generateOptionOutput( if valueCandidates != nil { text = append(text, "\n") } - text = append(text, diagnostics.X_default_Colon.Format(), " ", defaultValueDescription) + text = append(text, diagnostics.X_default_Colon.Localize(locale), " ", defaultValueDescription) } text = append(text, "\n") @@ -327,7 +329,7 @@ func showAdditionalInfoOutput(valueCandidates *valueCandidate, option *tsoptions return true } -func getValueCandidate(option *tsoptions.CommandLineOption) *valueCandidate { +func getValueCandidate(sys System, locale locale.Locale, option *tsoptions.CommandLineOption) *valueCandidate { // option.type might be "string" | "number" | "boolean" | "object" | "list" | Map // string -- any of: string // number -- any of: number @@ -349,11 +351,11 @@ func getValueCandidate(option *tsoptions.CommandLineOption) *valueCandidate { case tsoptions.CommandLineOptionTypeString, tsoptions.CommandLineOptionTypeNumber, tsoptions.CommandLineOptionTypeBoolean: - res.valueType = diagnostics.X_type_Colon.Format() + res.valueType = diagnostics.X_type_Colon.Localize(locale) case tsoptions.CommandLineOptionTypeList: - res.valueType = diagnostics.X_one_or_more_Colon.Format() + res.valueType = diagnostics.X_one_or_more_Colon.Localize(locale) default: - res.valueType = diagnostics.X_one_of_Colon.Format() + res.valueType = diagnostics.X_one_of_Colon.Localize(locale) } res.possibleValues = getPossibleValues(option) diff --git a/internal/execute/tsc/init.go b/internal/execute/tsc/init.go index ebd012754f..035888fecb 100644 --- a/internal/execute/tsc/init.go +++ b/internal/execute/tsc/init.go @@ -11,17 +11,18 @@ import ( "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/jsonutil" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/tsoptions" "github.com/microsoft/typescript-go/internal/tspath" ) -func WriteConfigFile(sys System, reportDiagnostic DiagnosticReporter, options *collections.OrderedMap[string, any]) { +func WriteConfigFile(sys System, locale locale.Locale, reportDiagnostic DiagnosticReporter, options *collections.OrderedMap[string, any]) { getCurrentDirectory := sys.GetCurrentDirectory() file := tspath.NormalizePath(tspath.CombinePaths(getCurrentDirectory, "tsconfig.json")) if sys.FS().FileExists(file) { reportDiagnostic(ast.NewCompilerDiagnostic(diagnostics.A_tsconfig_json_file_is_already_defined_at_Colon_0, file)) } else { - _ = sys.FS().WriteFile(file, generateTSConfig(options), false) + _ = sys.FS().WriteFile(file, generateTSConfig(options, locale), false) output := []string{"\n"} output = append(output, getHeader(sys, "Created a new tsconfig.json")...) output = append(output, "You can learn more at https://aka.ms/tsconfig", "\n") @@ -29,7 +30,7 @@ func WriteConfigFile(sys System, reportDiagnostic DiagnosticReporter, options *c } } -func generateTSConfig(options *collections.OrderedMap[string, any]) string { +func generateTSConfig(options *collections.OrderedMap[string, any], locale locale.Locale) string { const tab = " " var result []string @@ -40,9 +41,8 @@ func generateTSConfig(options *collections.OrderedMap[string, any]) string { } } - // !!! locale getLocaleSpecificMessage emitHeader := func(header *diagnostics.Message) { - result = append(result, tab+tab+"// "+header.Format()) + result = append(result, tab+tab+"// "+header.Localize(locale)) } newline := func() { result = append(result, "") @@ -143,8 +143,7 @@ func generateTSConfig(options *collections.OrderedMap[string, any]) string { } push("{") - // !!! locale getLocaleSpecificMessage - push(tab + `// ` + diagnostics.Visit_https_Colon_Slash_Slashaka_ms_Slashtsconfig_to_read_more_about_this_file.Format()) + push(tab + `// ` + diagnostics.Visit_https_Colon_Slash_Slashaka_ms_Slashtsconfig_to_read_more_about_this_file.Localize(locale)) push(tab + `"compilerOptions": {`) emitHeader(diagnostics.File_Layout) diff --git a/internal/execute/tsctests/readablebuildinfo.go b/internal/execute/tsctests/readablebuildinfo.go index 3969ac5f75..cdc9688c9a 100644 --- a/internal/execute/tsctests/readablebuildinfo.go +++ b/internal/execute/tsctests/readablebuildinfo.go @@ -62,7 +62,8 @@ type readableBuildInfoDiagnostic struct { End int `json:"end,omitzero"` Code int32 `json:"code,omitzero"` Category diagnostics.Category `json:"category,omitzero"` - Message string `json:"message,omitzero"` + MessageKey diagnostics.Key `json:"messageKey,omitzero"` + MessageArgs []string `json:"messageArgs,omitzero"` MessageChain []*readableBuildInfoDiagnostic `json:"messageChain,omitzero"` RelatedInformation []*readableBuildInfoDiagnostic `json:"relatedInformation,omitzero"` ReportsUnnecessary bool `json:"reportsUnnecessary,omitzero"` @@ -254,7 +255,8 @@ func (r *readableBuildInfo) toReadableBuildInfoDiagnostic(diagnostics []*increme End: d.End, Code: d.Code, Category: d.Category, - Message: d.Message, + MessageKey: d.MessageKey, + MessageArgs: d.MessageArgs, MessageChain: r.toReadableBuildInfoDiagnostic(d.MessageChain), RelatedInformation: r.toReadableBuildInfoDiagnostic(d.RelatedInformation), ReportsUnnecessary: d.ReportsUnnecessary, diff --git a/internal/execute/tsctests/sys.go b/internal/execute/tsctests/sys.go index cd75405529..f0fceb4f52 100644 --- a/internal/execute/tsctests/sys.go +++ b/internal/execute/tsctests/sys.go @@ -12,9 +12,11 @@ import ( "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/compiler" "github.com/microsoft/typescript-go/internal/core" + "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/execute" "github.com/microsoft/typescript-go/internal/execute/incremental" "github.com/microsoft/typescript-go/internal/execute/tsc" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/testutil/fsbaselineutil" "github.com/microsoft/typescript-go/internal/testutil/harnessutil" "github.com/microsoft/typescript-go/internal/testutil/stringtestutil" @@ -23,6 +25,7 @@ import ( "github.com/microsoft/typescript-go/internal/vfs" "github.com/microsoft/typescript-go/internal/vfs/iovfs" "github.com/microsoft/typescript-go/internal/vfs/vfstest" + "golang.org/x/text/language" ) type FileMap map[string]any @@ -285,12 +288,13 @@ func (s *TestSys) OnWatchStatusReportEnd() { fmt.Fprintln(s.Writer(), watchStatusReportEnd) } -func (s *TestSys) GetTrace(w io.Writer) func(str string) { - return func(str string) { +func (s *TestSys) GetTrace(w io.Writer, locale locale.Locale) func(msg *diagnostics.Message, args ...any) { + return func(msg *diagnostics.Message, args ...any) { fmt.Fprintln(w, traceStart) defer fmt.Fprintln(w, traceEnd) // With tsc -b building projects in parallel we cannot serialize the package.json lookup trace // so trace as if it wasnt cached + str := msg.Localize(locale, args...) s.tracer.TraceWithWriter(w, str, w == s.Writer()) } } @@ -419,13 +423,18 @@ type outputSanitizer struct { outputLines []string } +var ( + englishVersion = diagnostics.Version_0.Localize(locale.Default, core.Version()) + fakeEnglishVersion = diagnostics.Version_0.Localize(locale.Default, harnessutil.FakeTSVersion) + czech = locale.Locale(language.MustParse("cs")) + czechVersion = diagnostics.Version_0.Localize(czech, core.Version()) + fakeCzechVersion = diagnostics.Version_0.Localize(czech, harnessutil.FakeTSVersion) +) + func (o *outputSanitizer) addOutputLine(s string) { - if change := strings.ReplaceAll(s, fmt.Sprintf("'%s'", core.Version()), fmt.Sprintf("'%s'", harnessutil.FakeTSVersion)); change != s { - s = change - } - if change := strings.ReplaceAll(s, "Version "+core.Version(), "Version "+harnessutil.FakeTSVersion); change != s { - s = change - } + s = strings.ReplaceAll(s, fmt.Sprintf("'%s'", core.Version()), fmt.Sprintf("'%s'", harnessutil.FakeTSVersion)) + s = strings.ReplaceAll(s, englishVersion, fakeEnglishVersion) + s = strings.ReplaceAll(s, czechVersion, fakeCzechVersion) o.outputLines = append(o.outputLines, s) } diff --git a/internal/execute/tsctests/tsc_test.go b/internal/execute/tsctests/tsc_test.go index b5f1858f6c..5efa3262de 100644 --- a/internal/execute/tsctests/tsc_test.go +++ b/internal/execute/tsctests/tsc_test.go @@ -205,6 +205,14 @@ func TestTscCommandline(t *testing.T) { }, commandLineArgs: []string{"-p", "."}, }, + { + subScenario: "locale", + commandLineArgs: []string{"--locale", "cs", "--version"}, + }, + { + subScenario: "bad locale", + commandLineArgs: []string{"--locale", "whoops", "--version"}, + }, } for _, testCase := range testCases { diff --git a/internal/execute/tsctests/tscbuild_test.go b/internal/execute/tsctests/tscbuild_test.go index 8454b6e100..4c556a459e 100644 --- a/internal/execute/tsctests/tscbuild_test.go +++ b/internal/execute/tsctests/tscbuild_test.go @@ -148,6 +148,16 @@ func TestBuildCommandLine(t *testing.T) { files: FileMap{}, commandLineArgs: []string{"--build", "--help"}, }, + { + subScenario: "locale", + files: FileMap{}, + commandLineArgs: []string{"--build", "--help", "--locale", "en"}, + }, + { + subScenario: "bad locale", + files: FileMap{}, + commandLineArgs: []string{"--build", "--help", "--locale", "whoops"}, + }, { subScenario: "different options", files: getBuildCommandLineDifferentOptionsMap("composite"), diff --git a/internal/execute/watcher.go b/internal/execute/watcher.go index 6324befcd4..03b19118a6 100644 --- a/internal/execute/watcher.go +++ b/internal/execute/watcher.go @@ -54,7 +54,7 @@ func createWatcher( } func (w *Watcher) start() { - w.host = compiler.NewCompilerHost(w.sys.GetCurrentDirectory(), w.sys.FS(), w.sys.DefaultLibraryPath(), nil, getTraceFromSys(w.sys, w.testing)) + w.host = compiler.NewCompilerHost(w.sys.GetCurrentDirectory(), w.sys.FS(), w.sys.DefaultLibraryPath(), nil, getTraceFromSys(w.sys, w.config.Locale(), w.testing)) w.program = incremental.ReadBuildInfoProgram(w.config, incremental.NewBuildInfoReader(w.host), w.host) if w.testing == nil { @@ -131,7 +131,7 @@ func (w *Watcher) hasErrorsInTsConfig() bool { } w.config = configParseResult } - w.host = compiler.NewCompilerHost(w.sys.GetCurrentDirectory(), w.sys.FS(), w.sys.DefaultLibraryPath(), extendedConfigCache, getTraceFromSys(w.sys, w.testing)) + w.host = compiler.NewCompilerHost(w.sys.GetCurrentDirectory(), w.sys.FS(), w.sys.DefaultLibraryPath(), extendedConfigCache, getTraceFromSys(w.sys, w.config.Locale(), w.testing)) return false } diff --git a/internal/fourslash/fourslash.go b/internal/fourslash/fourslash.go index 7d513be31c..2eb95dd18b 100644 --- a/internal/fourslash/fourslash.go +++ b/internal/fourslash/fourslash.go @@ -19,6 +19,7 @@ import ( "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/diagnosticwriter" "github.com/microsoft/typescript-go/internal/execute/tsctests" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/ls" "github.com/microsoft/typescript-go/internal/ls/lsconv" "github.com/microsoft/typescript-go/internal/ls/lsutil" @@ -2613,7 +2614,7 @@ func (d *fourslashDiagnostic) Category() diagnostics.Category { return d.category } -func (d *fourslashDiagnostic) Message() string { +func (d *fourslashDiagnostic) Localize(locale locale.Locale) string { return d.message } diff --git a/internal/locale/locale.go b/internal/locale/locale.go new file mode 100644 index 0000000000..20d6e14a3d --- /dev/null +++ b/internal/locale/locale.go @@ -0,0 +1,28 @@ +package locale + +import ( + "context" + + "golang.org/x/text/language" +) + +type contextKey int + +type Locale language.Tag + +var Default Locale + +func WithLocale(ctx context.Context, locale Locale) context.Context { + return context.WithValue(ctx, contextKey(0), locale) +} + +func FromContext(ctx context.Context) Locale { + locale, _ := ctx.Value(contextKey(0)).(Locale) + return locale +} + +func Parse(localeStr string) (locale Locale, ok bool) { + // Parse gracefully fails. + tag, err := language.Parse(localeStr) + return Locale(tag), err == nil +} diff --git a/internal/ls/autoimports.go b/internal/ls/autoimports.go index 5af25f33ad..d1bd867fb8 100644 --- a/internal/ls/autoimports.go +++ b/internal/ls/autoimports.go @@ -14,6 +14,7 @@ import ( "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/debug" "github.com/microsoft/typescript-go/internal/diagnostics" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/ls/change" "github.com/microsoft/typescript-go/internal/ls/lsutil" "github.com/microsoft/typescript-go/internal/lsp/lsproto" @@ -1439,25 +1440,28 @@ func (l *LanguageService) codeActionForFix( includeSymbolNameInDescription bool, ) codeAction { tracker := change.NewTracker(ctx, l.GetProgram().Options(), l.FormatOptions(), l.converters) // !!! changetracker.with - diag := l.codeActionForFixWorker(tracker, sourceFile, symbolName, fix, includeSymbolNameInDescription) + diag := l.codeActionForFixWorker(ctx, tracker, sourceFile, symbolName, fix, includeSymbolNameInDescription) changes := tracker.GetChanges()[sourceFile.FileName()] - return codeAction{description: diag.Message(), changes: changes} + return codeAction{description: diag, changes: changes} } func (l *LanguageService) codeActionForFixWorker( + ctx context.Context, changeTracker *change.Tracker, sourceFile *ast.SourceFile, symbolName string, fix *ImportFix, includeSymbolNameInDescription bool, -) *diagnostics.Message { +) string { + locale := locale.FromContext(ctx) + switch fix.kind { case ImportFixKindUseNamespace: addNamespaceQualifier(changeTracker, sourceFile, fix.qualification()) - return diagnostics.FormatMessage(diagnostics.Change_0_to_1, symbolName, fmt.Sprintf("%s.%s", *fix.namespacePrefix, symbolName)) + return diagnostics.Change_0_to_1.Localize(locale, symbolName, fmt.Sprintf("%s.%s", *fix.namespacePrefix, symbolName)) case ImportFixKindJsdocTypeImport: if fix.usagePosition == nil { - return nil + return "" } quotePreference := getQuotePreference(sourceFile, l.UserPreferences()) quoteChar := "\"" @@ -1466,7 +1470,7 @@ func (l *LanguageService) codeActionForFixWorker( } importTypePrefix := fmt.Sprintf("import(%s%s%s).", quoteChar, fix.moduleSpecifier, quoteChar) changeTracker.InsertText(sourceFile, *fix.usagePosition, importTypePrefix) - return diagnostics.FormatMessage(diagnostics.Change_0_to_1, symbolName, importTypePrefix+symbolName) + return diagnostics.Change_0_to_1.Localize(locale, symbolName, importTypePrefix+symbolName) case ImportFixKindAddToExisting: var defaultImport *Import var namedImports []*Import @@ -1484,9 +1488,9 @@ func (l *LanguageService) codeActionForFixWorker( ) moduleSpecifierWithoutQuotes := stringutil.StripQuotes(fix.moduleSpecifier) if includeSymbolNameInDescription { - return diagnostics.FormatMessage(diagnostics.Import_0_from_1, symbolName, moduleSpecifierWithoutQuotes) + return diagnostics.Import_0_from_1.Localize(locale, symbolName, moduleSpecifierWithoutQuotes) } - return diagnostics.FormatMessage(diagnostics.Update_import_from_0, moduleSpecifierWithoutQuotes) + return diagnostics.Update_import_from_0.Localize(locale, moduleSpecifierWithoutQuotes) case ImportFixKindAddNew: var declarations []*ast.Statement var defaultImport *Import @@ -1521,17 +1525,17 @@ func (l *LanguageService) codeActionForFixWorker( addNamespaceQualifier(changeTracker, sourceFile, qualification) } if includeSymbolNameInDescription { - return diagnostics.FormatMessage(diagnostics.Import_0_from_1, symbolName, fix.moduleSpecifier) + return diagnostics.Import_0_from_1.Localize(locale, symbolName, fix.moduleSpecifier) } - return diagnostics.FormatMessage(diagnostics.Add_import_from_0, fix.moduleSpecifier) + return diagnostics.Add_import_from_0.Localize(locale, fix.moduleSpecifier) case ImportFixKindPromoteTypeOnly: promotedDeclaration := promoteFromTypeOnly(changeTracker, fix.typeOnlyAliasDeclaration, l.GetProgram(), sourceFile, l) if promotedDeclaration.Kind == ast.KindImportSpecifier { moduleSpec := getModuleSpecifierText(promotedDeclaration.Parent.Parent) - return diagnostics.FormatMessage(diagnostics.Remove_type_from_import_of_0_from_1, symbolName, moduleSpec) + return diagnostics.Remove_type_from_import_of_0_from_1.Localize(locale, symbolName, moduleSpec) } moduleSpec := getModuleSpecifierText(promotedDeclaration) - return diagnostics.FormatMessage(diagnostics.Remove_type_from_import_declaration_from_0, moduleSpec) + return diagnostics.Remove_type_from_import_declaration_from_0.Localize(locale, moduleSpec) default: panic(fmt.Sprintf(`Unexpected fix kind %v`, fix.kind)) } diff --git a/internal/ls/codeactions_importfixes.go b/internal/ls/codeactions_importfixes.go index 23449bd365..96e9f0d59f 100644 --- a/internal/ls/codeactions_importfixes.go +++ b/internal/ls/codeactions_importfixes.go @@ -75,6 +75,7 @@ func getImportCodeActions(ctx context.Context, fixContext *CodeFixContext) []Cod for _, fixInfo := range info { tracker := change.NewTracker(ctx, fixContext.Program.Options(), fixContext.LS.FormatOptions(), fixContext.LS.converters) msg := fixContext.LS.codeActionForFixWorker( + ctx, tracker, fixContext.SourceFile, fixInfo.symbolName, @@ -82,7 +83,7 @@ func getImportCodeActions(ctx context.Context, fixContext *CodeFixContext) []Cod fixInfo.symbolName != fixInfo.errorIdentifierText, ) - if msg != nil { + if msg != "" { // Convert changes to LSP edits changes := tracker.GetChanges() var edits []*lsproto.TextEdit @@ -91,7 +92,7 @@ func getImportCodeActions(ctx context.Context, fixContext *CodeFixContext) []Cod } actions = append(actions, CodeAction{ - Description: msg.Message(), + Description: msg, Changes: edits, }) } diff --git a/internal/ls/lsconv/converters.go b/internal/ls/lsconv/converters.go index 051ffcbe52..406d713f88 100644 --- a/internal/ls/lsconv/converters.go +++ b/internal/ls/lsconv/converters.go @@ -14,6 +14,7 @@ import ( "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/diagnosticwriter" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/lsp/lsproto" "github.com/microsoft/typescript-go/internal/tspath" ) @@ -214,7 +215,7 @@ type diagnosticOptions struct { // DiagnosticToLSPPull converts a diagnostic for pull diagnostics (textDocument/diagnostic) func DiagnosticToLSPPull(ctx context.Context, converters *Converters, diagnostic *ast.Diagnostic, reportStyleChecksAsWarnings bool) *lsproto.Diagnostic { clientCaps := lsproto.GetClientCapabilities(ctx).TextDocument.Diagnostic - return diagnosticToLSP(converters, diagnostic, diagnosticOptions{ + return diagnosticToLSP(ctx, converters, diagnostic, diagnosticOptions{ reportStyleChecksAsWarnings: reportStyleChecksAsWarnings, // !!! get through context UserPreferences relatedInformation: clientCaps.RelatedInformation, tagValueSet: clientCaps.TagSupport.ValueSet, @@ -224,7 +225,7 @@ func DiagnosticToLSPPull(ctx context.Context, converters *Converters, diagnostic // DiagnosticToLSPPush converts a diagnostic for push diagnostics (textDocument/publishDiagnostics) func DiagnosticToLSPPush(ctx context.Context, converters *Converters, diagnostic *ast.Diagnostic) *lsproto.Diagnostic { clientCaps := lsproto.GetClientCapabilities(ctx).TextDocument.PublishDiagnostics - return diagnosticToLSP(converters, diagnostic, diagnosticOptions{ + return diagnosticToLSP(ctx, converters, diagnostic, diagnosticOptions{ relatedInformation: clientCaps.RelatedInformation, tagValueSet: clientCaps.TagSupport.ValueSet, }) @@ -242,7 +243,8 @@ var styleCheckDiagnostics = collections.NewSetFromItems( diagnostics.Not_all_code_paths_return_a_value.Code(), ) -func diagnosticToLSP(converters *Converters, diagnostic *ast.Diagnostic, opts diagnosticOptions) *lsproto.Diagnostic { +func diagnosticToLSP(ctx context.Context, converters *Converters, diagnostic *ast.Diagnostic, opts diagnosticOptions) *lsproto.Diagnostic { + locale := locale.FromContext(ctx) var severity lsproto.DiagnosticSeverity switch diagnostic.Category() { case diagnostics.CategorySuggestion: @@ -268,7 +270,7 @@ func diagnosticToLSP(converters *Converters, diagnostic *ast.Diagnostic, opts di Uri: FileNameToDocumentURI(related.File().FileName()), Range: converters.ToLSPRange(related.File(), related.Loc()), }, - Message: related.Message(), + Message: related.Localize(locale), }) } } @@ -296,19 +298,19 @@ func diagnosticToLSP(converters *Converters, diagnostic *ast.Diagnostic, opts di Integer: ptrTo(diagnostic.Code()), }, Severity: &severity, - Message: messageChainToString(diagnostic), + Message: messageChainToString(diagnostic, locale), Source: ptrTo("ts"), RelatedInformation: ptrToSliceIfNonEmpty(relatedInformation), Tags: ptrToSliceIfNonEmpty(tags), } } -func messageChainToString(diagnostic *ast.Diagnostic) string { +func messageChainToString(diagnostic *ast.Diagnostic, locale locale.Locale) string { if len(diagnostic.MessageChain()) == 0 { - return diagnostic.Message() + return diagnostic.Localize(locale) } var b strings.Builder - diagnosticwriter.WriteFlattenedASTDiagnosticMessage(&b, diagnostic, "\n") + diagnosticwriter.WriteFlattenedASTDiagnosticMessage(&b, diagnostic, "\n", locale) return b.String() } diff --git a/internal/lsp/server.go b/internal/lsp/server.go index 0c40de4c2f..e076bb27d4 100644 --- a/internal/lsp/server.go +++ b/internal/lsp/server.go @@ -17,6 +17,7 @@ import ( "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/jsonutil" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/ls" "github.com/microsoft/typescript-go/internal/ls/lsconv" "github.com/microsoft/typescript-go/internal/ls/lsutil" @@ -27,7 +28,6 @@ import ( "github.com/microsoft/typescript-go/internal/tspath" "github.com/microsoft/typescript-go/internal/vfs" "golang.org/x/sync/errgroup" - "golang.org/x/text/language" ) type ServerOptions struct { @@ -160,7 +160,7 @@ type Server struct { initializeParams *lsproto.InitializeParams clientCapabilities lsproto.ResolvedClientCapabilities positionEncoding lsproto.PositionEncodingKind - locale language.Tag + locale locale.Locale watchEnabled bool watcherID atomic.Uint32 @@ -365,7 +365,7 @@ func (s *Server) dispatchLoop(ctx context.Context) error { case <-ctx.Done(): return ctx.Err() case req := <-s.requestQueue: - requestCtx := core.WithLocale(ctx, s.locale) + requestCtx := locale.WithLocale(ctx, s.locale) if req.ID != nil { var cancel context.CancelFunc requestCtx, cancel = context.WithCancel(core.WithRequestID(requestCtx, req.ID.String())) @@ -866,11 +866,7 @@ func (s *Server) handleInitialize(ctx context.Context, params *lsproto.Initializ } if s.initializeParams.Locale != nil { - locale, err := language.Parse(*s.initializeParams.Locale) - if err != nil { - return nil, err - } - s.locale = locale + s.locale, _ = locale.Parse(*s.initializeParams.Locale) } if s.initializeParams.Trace != nil && *s.initializeParams.Trace == "verbose" { @@ -999,6 +995,7 @@ func (s *Server) handleInitialized(ctx context.Context, params *lsproto.Initiali LoggingEnabled: true, DebounceDelay: 500 * time.Millisecond, PushDiagnosticsEnabled: !disablePushDiagnostics, + Locale: s.locale, }, FS: s.fs, Logger: s.logger, diff --git a/internal/module/resolver.go b/internal/module/resolver.go index 4ee4a86b09..b2f0f7dbab 100644 --- a/internal/module/resolver.go +++ b/internal/module/resolver.go @@ -42,16 +42,21 @@ func unresolved() *resolved { type resolutionKindSpecificLoader = func(extensions extensions, candidate string, onlyRecordFailures bool) *resolved type tracer struct { - traces []string + traces []DiagAndArgs } -func (t *tracer) write(msg string) { +type DiagAndArgs struct { + Message *diagnostics.Message + Args []any +} + +func (t *tracer) write(diag *diagnostics.Message, args ...any) { if t != nil { - t.traces = append(t.traces, msg) + t.traces = append(t.traces, DiagAndArgs{Message: diag, Args: args}) } } -func (t *tracer) getTraces() []string { +func (t *tracer) getTraces() []DiagAndArgs { if t != nil { return t.traces } @@ -192,7 +197,7 @@ func (r *Resolver) GetPackageJsonScopeIfApplicable(path string) *packagejson.Inf func (r *tracer) traceResolutionUsingProjectReference(redirectedReference ResolvedProjectReference) { if redirectedReference != nil && redirectedReference.CompilerOptions() != nil { - r.write(diagnostics.Using_compiler_options_of_project_reference_redirect_0.Format(redirectedReference.ConfigName())) + r.write(diagnostics.Using_compiler_options_of_project_reference_redirect_0, redirectedReference.ConfigName()) } } @@ -201,7 +206,7 @@ func (r *Resolver) ResolveTypeReferenceDirective( containingFile string, resolutionMode core.ResolutionMode, redirectedReference ResolvedProjectReference, -) (*ResolvedTypeReferenceDirective, []string) { +) (*ResolvedTypeReferenceDirective, []DiagAndArgs) { traceBuilder := r.newTraceBuilder() compilerOptions := GetCompilerOptionsWithRedirect(r.compilerOptions, redirectedReference) @@ -209,7 +214,7 @@ func (r *Resolver) ResolveTypeReferenceDirective( typeRoots, fromConfig := compilerOptions.GetEffectiveTypeRoots(r.host.GetCurrentDirectory()) if traceBuilder != nil { - traceBuilder.write(diagnostics.Resolving_type_reference_directive_0_containing_file_1_root_directory_2.Format(typeReferenceDirectiveName, containingFile, strings.Join(typeRoots, ","))) + traceBuilder.write(diagnostics.Resolving_type_reference_directive_0_containing_file_1_root_directory_2, typeReferenceDirectiveName, containingFile, strings.Join(typeRoots, ",")) traceBuilder.traceResolutionUsingProjectReference(redirectedReference) } @@ -222,11 +227,11 @@ func (r *Resolver) ResolveTypeReferenceDirective( return result, traceBuilder.getTraces() } -func (r *Resolver) ResolveModuleName(moduleName string, containingFile string, resolutionMode core.ResolutionMode, redirectedReference ResolvedProjectReference) (*ResolvedModule, []string) { +func (r *Resolver) ResolveModuleName(moduleName string, containingFile string, resolutionMode core.ResolutionMode, redirectedReference ResolvedProjectReference) (*ResolvedModule, []DiagAndArgs) { traceBuilder := r.newTraceBuilder() compilerOptions := GetCompilerOptionsWithRedirect(r.compilerOptions, redirectedReference) if traceBuilder != nil { - traceBuilder.write(diagnostics.Resolving_module_0_from_1.Format(moduleName, containingFile)) + traceBuilder.write(diagnostics.Resolving_module_0_from_1, moduleName, containingFile) traceBuilder.traceResolutionUsingProjectReference(redirectedReference) } containingDirectory := tspath.GetDirectoryPath(containingFile) @@ -234,11 +239,11 @@ func (r *Resolver) ResolveModuleName(moduleName string, containingFile string, r moduleResolution := compilerOptions.GetModuleResolutionKind() if compilerOptions.ModuleResolution != moduleResolution { if traceBuilder != nil { - traceBuilder.write(diagnostics.Module_resolution_kind_is_not_specified_using_0.Format(moduleResolution.String())) + traceBuilder.write(diagnostics.Module_resolution_kind_is_not_specified_using_0, moduleResolution.String()) } } else { if traceBuilder != nil { - traceBuilder.write(diagnostics.Explicitly_specified_module_resolution_kind_Colon_0.Format(moduleResolution.String())) + traceBuilder.write(diagnostics.Explicitly_specified_module_resolution_kind_Colon_0, moduleResolution.String()) } } @@ -254,12 +259,12 @@ func (r *Resolver) ResolveModuleName(moduleName string, containingFile string, r if traceBuilder != nil { if result.IsResolved() { if result.PackageId.Name != "" { - traceBuilder.write(diagnostics.Module_name_0_was_successfully_resolved_to_1_with_Package_ID_2.Format(moduleName, result.ResolvedFileName, result.PackageId.String())) + traceBuilder.write(diagnostics.Module_name_0_was_successfully_resolved_to_1_with_Package_ID_2, moduleName, result.ResolvedFileName, result.PackageId.String()) } else { - traceBuilder.write(diagnostics.Module_name_0_was_successfully_resolved_to_1.Format(moduleName, result.ResolvedFileName)) + traceBuilder.write(diagnostics.Module_name_0_was_successfully_resolved_to_1, moduleName, result.ResolvedFileName) } } else { - traceBuilder.write(diagnostics.Module_name_0_was_not_resolved.Format(moduleName)) + traceBuilder.write(diagnostics.Module_name_0_was_not_resolved, moduleName) } } @@ -284,7 +289,7 @@ func (r *Resolver) tryResolveFromTypingsLocation(moduleName string, containingDi traceBuilder, ) if traceBuilder != nil { - traceBuilder.write(diagnostics.Auto_discovery_for_typings_is_enabled_in_project_0_Running_extra_resolution_pass_for_module_1_using_cache_location_2.Format(r.projectName, moduleName, r.typingsLocation)) + traceBuilder.write(diagnostics.Auto_discovery_for_typings_is_enabled_in_project_0_Running_extra_resolution_pass_for_module_1_using_cache_location_2, r.projectName, moduleName, r.typingsLocation) } globalResolved := state.loadModuleFromImmediateNodeModulesDirectory(extensionsDeclaration, r.typingsLocation, false) if globalResolved == nil { @@ -307,20 +312,20 @@ func (r *Resolver) resolveConfig(moduleName string, containingFile string) *Reso func (r *tracer) traceTypeReferenceDirectiveResult(typeReferenceDirectiveName string, result *ResolvedTypeReferenceDirective) { if !result.IsResolved() { - r.write(diagnostics.Type_reference_directive_0_was_not_resolved.Format(typeReferenceDirectiveName)) + r.write(diagnostics.Type_reference_directive_0_was_not_resolved, typeReferenceDirectiveName) } else if result.PackageId.Name != "" { - r.write(diagnostics.Type_reference_directive_0_was_successfully_resolved_to_1_with_Package_ID_2_primary_Colon_3.Format( + r.write(diagnostics.Type_reference_directive_0_was_successfully_resolved_to_1_with_Package_ID_2_primary_Colon_3, typeReferenceDirectiveName, result.ResolvedFileName, result.PackageId.String(), result.Primary, - )) + ) } else { - r.write(diagnostics.Type_reference_directive_0_was_successfully_resolved_to_1_primary_Colon_2.Format( + r.write(diagnostics.Type_reference_directive_0_was_successfully_resolved_to_1_primary_Colon_2, typeReferenceDirectiveName, result.ResolvedFileName, result.Primary, - )) + ) } } @@ -328,13 +333,13 @@ func (r *resolutionState) resolveTypeReferenceDirective(typeRoots []string, from // Primary lookup if len(typeRoots) > 0 { if r.tracer != nil { - r.tracer.write(diagnostics.Resolving_with_primary_search_path_0.Format(strings.Join(typeRoots, ", "))) + r.tracer.write(diagnostics.Resolving_with_primary_search_path_0, strings.Join(typeRoots, ", ")) } for _, typeRoot := range typeRoots { candidate := r.getCandidateFromTypeRoot(typeRoot) directoryExists := r.resolver.host.FS().DirectoryExists(candidate) if !directoryExists && r.tracer != nil { - r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it.Format(typeRoot)) + r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it, typeRoot) } if fromConfig { // Custom typeRoots resolve as file or directory just like we do modules @@ -351,14 +356,14 @@ func (r *resolutionState) resolveTypeReferenceDirective(typeRoots []string, from } } } else if r.tracer != nil { - r.tracer.write(diagnostics.Root_directory_cannot_be_determined_skipping_primary_search_paths.Format()) + r.tracer.write(diagnostics.Root_directory_cannot_be_determined_skipping_primary_search_paths) } // Secondary lookup var resolved *resolved if !fromConfig || !fromInferredTypesContainingFile { if r.tracer != nil { - r.tracer.write(diagnostics.Looking_up_in_node_modules_folder_initial_location_0.Format(r.containingDirectory)) + r.tracer.write(diagnostics.Looking_up_in_node_modules_folder_initial_location_0, r.containingDirectory) } if !tspath.IsExternalModuleNameRelative(r.name) { resolved = r.loadModuleFromNearestNodeModulesDirectory(false /*typesScopeOnly*/) @@ -367,7 +372,7 @@ func (r *resolutionState) resolveTypeReferenceDirective(typeRoots []string, from resolved = r.nodeLoadModuleByRelativeName(extensionsDeclaration, candidate, false /*onlyRecordFailures*/, true /*considerPackageJson*/) } } else if r.tracer != nil { - r.tracer.write(diagnostics.Resolving_type_reference_directive_for_program_that_specifies_custom_typeRoots_skipping_lookup_in_node_modules_folder.Format()) + r.tracer.write(diagnostics.Resolving_type_reference_directive_for_program_that_specifies_custom_typeRoots_skipping_lookup_in_node_modules_folder) } return r.createResolvedTypeReferenceDirective(resolved, false /*primary*/) } @@ -383,7 +388,7 @@ func (r *resolutionState) getCandidateFromTypeRoot(typeRoot string) string { func (r *resolutionState) mangleScopedPackageName(name string) string { mangled := MangleScopedPackageName(name) if r.tracer != nil && mangled != name { - r.tracer.write(diagnostics.Scoped_package_detected_looking_in_0.Format(mangled)) + r.tracer.write(diagnostics.Scoped_package_detected_looking_in_0, mangled) } return mangled } @@ -406,9 +411,9 @@ func (r *resolutionState) resolveNodeLike() *ResolvedModule { if r.tracer != nil { conditions := strings.Join(core.Map(r.conditions, func(c string) string { return `'` + c + `'` }), ", ") if r.esmMode { - r.tracer.write(diagnostics.Resolving_in_0_mode_with_conditions_1.Format("ESM", conditions)) + r.tracer.write(diagnostics.Resolving_in_0_mode_with_conditions_1, "ESM", conditions) } else { - r.tracer.write(diagnostics.Resolving_in_0_mode_with_conditions_1.Format("CJS", conditions)) + r.tracer.write(diagnostics.Resolving_in_0_mode_with_conditions_1, "CJS", conditions) } } result := r.resolveNodeLikeWorker() @@ -422,7 +427,7 @@ func (r *resolutionState) resolveNodeLike() *ResolvedModule { !extensionIsOk(extensionsTypeScript|extensionsDeclaration, result.Extension) && slices.Contains(r.conditions, "import") { if r.tracer != nil { - r.tracer.write(diagnostics.Resolution_of_non_relative_name_failed_trying_with_modern_Node_resolution_features_disabled_to_see_if_npm_library_needs_configuration_update.Format()) + r.tracer.write(diagnostics.Resolution_of_non_relative_name_failed_trying_with_modern_Node_resolution_features_disabled_to_see_if_npm_library_needs_configuration_update) } r.features = r.features & ^NodeResolutionFeaturesExports r.extensions = r.extensions & (extensionsTypeScript | extensionsDeclaration) @@ -453,12 +458,12 @@ func (r *resolutionState) resolveNodeLikeWorker() *ResolvedModule { } if strings.Contains(r.name, ":") { if r.tracer != nil { - r.tracer.write(diagnostics.Skipping_module_0_that_looks_like_an_absolute_URI_target_file_types_Colon_1.Format(r.name, r.extensions.String())) + r.tracer.write(diagnostics.Skipping_module_0_that_looks_like_an_absolute_URI_target_file_types_Colon_1, r.name, r.extensions.String()) } return r.createResolvedModule(nil, false) } if r.tracer != nil { - r.tracer.write(diagnostics.Loading_module_0_from_node_modules_folder_target_file_types_Colon_1.Format(r.name, r.extensions.String())) + r.tracer.write(diagnostics.Loading_module_0_from_node_modules_folder_target_file_types_Colon_1, r.name, r.extensions.String()) } if resolved := r.loadModuleFromNearestNodeModulesDirectory(false /*typesScopeOnly*/); !resolved.shouldContinueSearching() { return r.createResolvedModuleHandlingSymlink(resolved) @@ -530,7 +535,7 @@ func (r *resolutionState) loadModuleFromSelfNameReference() *resolved { func (r *resolutionState) loadModuleFromImports() *resolved { if r.name == "#" || strings.HasPrefix(r.name, "#/") { if r.tracer != nil { - r.tracer.write(diagnostics.Invalid_import_specifier_0_has_no_possible_resolutions.Format(r.name)) + r.tracer.write(diagnostics.Invalid_import_specifier_0_has_no_possible_resolutions, r.name) } return continueSearching() } @@ -538,7 +543,7 @@ func (r *resolutionState) loadModuleFromImports() *resolved { scope := r.getPackageScopeForPath(directoryPath) if !scope.Exists() { if r.tracer != nil { - r.tracer.write(diagnostics.Directory_0_has_no_containing_package_json_scope_Imports_will_not_resolve.Format(directoryPath)) + r.tracer.write(diagnostics.Directory_0_has_no_containing_package_json_scope_Imports_will_not_resolve, directoryPath) } return continueSearching() } @@ -546,7 +551,7 @@ func (r *resolutionState) loadModuleFromImports() *resolved { // !!! Old compiler only checks for undefined, but then assumes `imports` is an object if present. // Maybe should have a new diagnostic for imports of an invalid type. Also, array should be handled? if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_scope_0_has_no_imports_defined.Format(scope.PackageDirectory)) + r.tracer.write(diagnostics.X_package_json_scope_0_has_no_imports_defined, scope.PackageDirectory) } return continueSearching() } @@ -556,7 +561,7 @@ func (r *resolutionState) loadModuleFromImports() *resolved { } if r.tracer != nil { - r.tracer.write(diagnostics.Import_specifier_0_does_not_exist_in_package_json_scope_at_path_1.Format(r.name, scope.PackageDirectory)) + r.tracer.write(diagnostics.Import_specifier_0_does_not_exist_in_package_json_scope_at_path_1, r.name, scope.PackageDirectory) } return continueSearching() } @@ -589,7 +594,7 @@ func (r *resolutionState) loadModuleFromExports(packageInfo *packagejson.InfoCac } if r.tracer != nil { - r.tracer.write(diagnostics.Export_specifier_0_does_not_exist_in_package_json_scope_at_path_1.Format(subpath, packageInfo.PackageDirectory)) + r.tracer.write(diagnostics.Export_specifier_0_does_not_exist_in_package_json_scope_at_path_1, subpath, packageInfo.PackageDirectory) } return continueSearching() } @@ -641,7 +646,7 @@ func (r *resolutionState) loadModuleFromTargetExportOrImport(extensions extensio targetString, _ := target.Value.(string) if !isPattern && len(subpath) > 0 && !strings.HasSuffix(targetString, "/") { if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1.Format(scope.PackageDirectory, moduleName)) + r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1, scope.PackageDirectory, moduleName) } return continueSearching() } @@ -652,8 +657,8 @@ func (r *resolutionState) loadModuleFromTargetExportOrImport(extensions extensio combinedLookup = strings.ReplaceAll(targetString, "*", subpath) } if r.tracer != nil { - r.tracer.write(diagnostics.Using_0_subpath_1_with_target_2.Format("imports", key, combinedLookup)) - r.tracer.write(diagnostics.Resolving_module_0_from_1.Format(combinedLookup, scope.PackageDirectory+"/")) + r.tracer.write(diagnostics.Using_0_subpath_1_with_target_2, "imports", key, combinedLookup) + r.tracer.write(diagnostics.Resolving_module_0_from_1, combinedLookup, scope.PackageDirectory+"/") } name, containingDirectory := r.name, r.containingDirectory r.name, r.containingDirectory = combinedLookup, scope.PackageDirectory+"/" @@ -672,7 +677,7 @@ func (r *resolutionState) loadModuleFromTargetExportOrImport(extensions extensio return continueSearching() } if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1.Format(scope.PackageDirectory, moduleName)) + r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1, scope.PackageDirectory, moduleName) } return continueSearching() } @@ -685,7 +690,7 @@ func (r *resolutionState) loadModuleFromTargetExportOrImport(extensions extensio partsAfterFirst := parts[1:] if slices.Contains(partsAfterFirst, "..") || slices.Contains(partsAfterFirst, ".") || slices.Contains(partsAfterFirst, "node_modules") { if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1.Format(scope.PackageDirectory, moduleName)) + r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1, scope.PackageDirectory, moduleName) } return continueSearching() } @@ -695,7 +700,7 @@ func (r *resolutionState) loadModuleFromTargetExportOrImport(extensions extensio subpathParts := tspath.GetPathComponents(subpath, "") if slices.Contains(subpathParts, "..") || slices.Contains(subpathParts, ".") || slices.Contains(subpathParts, "node_modules") { if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1.Format(scope.PackageDirectory, moduleName)) + r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1, scope.PackageDirectory, moduleName) } return continueSearching() } @@ -707,7 +712,7 @@ func (r *resolutionState) loadModuleFromTargetExportOrImport(extensions extensio } else { messageTarget = targetString + subpath } - r.tracer.write(diagnostics.Using_0_subpath_1_with_target_2.Format(core.IfElse(isImports, "imports", "exports"), key, messageTarget)) + r.tracer.write(diagnostics.Using_0_subpath_1_with_target_2, core.IfElse(isImports, "imports", "exports"), key, messageTarget) } var finalPath string if isPattern { @@ -726,39 +731,39 @@ func (r *resolutionState) loadModuleFromTargetExportOrImport(extensions extensio case packagejson.JSONValueTypeObject: if r.tracer != nil { - r.tracer.write(diagnostics.Entering_conditional_exports.Format()) + r.tracer.write(diagnostics.Entering_conditional_exports) } for condition := range target.AsObject().Keys() { if r.conditionMatches(condition) { if r.tracer != nil { - r.tracer.write(diagnostics.Matched_0_condition_1.Format(core.IfElse(isImports, "imports", "exports"), condition)) + r.tracer.write(diagnostics.Matched_0_condition_1, core.IfElse(isImports, "imports", "exports"), condition) } subTarget, _ := target.AsObject().Get(condition) if result := r.loadModuleFromTargetExportOrImport(extensions, moduleName, scope, isImports, subTarget, subpath, isPattern, key); !result.shouldContinueSearching() { if r.tracer != nil { - r.tracer.write(diagnostics.Resolved_under_condition_0.Format(condition)) + r.tracer.write(diagnostics.Resolved_under_condition_0, condition) } if r.tracer != nil { - r.tracer.write(diagnostics.Exiting_conditional_exports.Format()) + r.tracer.write(diagnostics.Exiting_conditional_exports) } return result } else if r.tracer != nil { - r.tracer.write(diagnostics.Failed_to_resolve_under_condition_0.Format(condition)) + r.tracer.write(diagnostics.Failed_to_resolve_under_condition_0, condition) } } else { if r.tracer != nil { - r.tracer.write(diagnostics.Saw_non_matching_condition_0.Format(condition)) + r.tracer.write(diagnostics.Saw_non_matching_condition_0, condition) } } } if r.tracer != nil { - r.tracer.write(diagnostics.Exiting_conditional_exports.Format()) + r.tracer.write(diagnostics.Exiting_conditional_exports) } return continueSearching() case packagejson.JSONValueTypeArray: if len(target.AsArray()) == 0 { if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1.Format(scope.PackageDirectory, moduleName)) + r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1, scope.PackageDirectory, moduleName) } return continueSearching() } @@ -770,13 +775,13 @@ func (r *resolutionState) loadModuleFromTargetExportOrImport(extensions extensio case packagejson.JSONValueTypeNull: if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_scope_0_explicitly_maps_specifier_1_to_null.Format(scope.PackageDirectory, moduleName)) + r.tracer.write(diagnostics.X_package_json_scope_0_explicitly_maps_specifier_1_to_null, scope.PackageDirectory, moduleName) } return continueSearching() } if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1.Format(scope.PackageDirectory, moduleName)) + r.tracer.write(diagnostics.X_package_json_scope_0_has_invalid_type_for_target_of_specifier_1, scope.PackageDirectory, moduleName) } return continueSearching() } @@ -896,7 +901,7 @@ func (r *resolutionState) loadModuleFromNearestNodeModulesDirectory(typesScopeOn // (1) if priorityExtensions != 0 { if r.tracer != nil { - r.tracer.write(diagnostics.Searching_all_ancestor_node_modules_directories_for_preferred_extensions_Colon_0.Format(priorityExtensions.String())) + r.tracer.write(diagnostics.Searching_all_ancestor_node_modules_directories_for_preferred_extensions_Colon_0, priorityExtensions.String()) } if result := r.loadModuleFromNearestNodeModulesDirectoryWorker(priorityExtensions, mode, typesScopeOnly); !result.shouldContinueSearching() { return result @@ -905,7 +910,7 @@ func (r *resolutionState) loadModuleFromNearestNodeModulesDirectory(typesScopeOn // (2) if secondaryExtensions != 0 && !typesScopeOnly { if r.tracer != nil { - r.tracer.write(diagnostics.Searching_all_ancestor_node_modules_directories_for_fallback_extensions_Colon_0.Format(secondaryExtensions.String())) + r.tracer.write(diagnostics.Searching_all_ancestor_node_modules_directories_for_fallback_extensions_Colon_0, secondaryExtensions.String()) } return r.loadModuleFromNearestNodeModulesDirectoryWorker(secondaryExtensions, mode, typesScopeOnly) } @@ -931,7 +936,7 @@ func (r *resolutionState) loadModuleFromImmediateNodeModulesDirectory(extensions nodeModulesFolder := tspath.CombinePaths(directory, "node_modules") nodeModulesFolderExists := r.resolver.host.FS().DirectoryExists(nodeModulesFolder) if !nodeModulesFolderExists && r.tracer != nil { - r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it.Format(nodeModulesFolder)) + r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it, nodeModulesFolder) } if !typesScopeOnly { @@ -944,7 +949,7 @@ func (r *resolutionState) loadModuleFromImmediateNodeModulesDirectory(extensions nodeModulesAtTypes := tspath.CombinePaths(nodeModulesFolder, "@types") nodeModulesAtTypesExists := nodeModulesFolderExists && r.resolver.host.FS().DirectoryExists(nodeModulesAtTypes) if !nodeModulesAtTypesExists && r.tracer != nil { - r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it.Format(nodeModulesAtTypes)) + r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it, nodeModulesAtTypes) } return r.loadModuleFromSpecificNodeModulesDirectory(extensionsDeclaration, r.mangleScopedPackageName(r.name), nodeModulesAtTypes, nodeModulesAtTypesExists) } @@ -1021,7 +1026,7 @@ func (r *resolutionState) loadModuleFromSpecificNodeModulesDirectory(ext extensi versionPaths := packageInfo.Contents.GetVersionPaths(r.getTraceFunc()) if versionPaths.Exists() { if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2.Format(versionPaths.Version, core.Version(), rest)) + r.tracer.write(diagnostics.X_package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2, versionPaths.Version, core.Version(), rest) } packageDirectoryExists := nodeModulesDirectoryExists && r.resolver.host.FS().DirectoryExists(packageDirectory) pathPatterns := TryParsePatterns(versionPaths.GetPaths()) @@ -1136,7 +1141,7 @@ func (r *resolutionState) getParsedPatternsForPaths() *ParsedPatterns { func (r *resolutionState) tryLoadModuleUsingPathsIfEligible() *resolved { if r.compilerOptions.Paths.Size() > 0 && !tspath.PathIsRelative(r.name) { if r.tracer != nil { - r.tracer.write(diagnostics.X_paths_option_is_specified_looking_for_a_pattern_to_match_module_name_0.Format(r.name)) + r.tracer.write(diagnostics.X_paths_option_is_specified_looking_for_a_pattern_to_match_module_name_0, r.name) } } else { return continueSearching() @@ -1160,13 +1165,13 @@ func (r *resolutionState) tryLoadModuleUsingPaths(extensions extensions, moduleN if matchedPattern := MatchPatternOrExact(pathPatterns, moduleName); matchedPattern.IsValid() { matchedStar := matchedPattern.MatchedText(moduleName) if r.tracer != nil { - r.tracer.write(diagnostics.Module_name_0_matched_pattern_1.Format(moduleName, matchedPattern.Text)) + r.tracer.write(diagnostics.Module_name_0_matched_pattern_1, moduleName, matchedPattern.Text) } for _, subst := range paths.GetOrZero(matchedPattern.Text) { path := strings.Replace(subst, "*", matchedStar, 1) candidate := tspath.NormalizePath(tspath.CombinePaths(containingDirectory, path)) if r.tracer != nil { - r.tracer.write(diagnostics.Trying_substitution_0_candidate_module_location_Colon_1.Format(subst, path)) + r.tracer.write(diagnostics.Trying_substitution_0_candidate_module_location_Colon_1, subst, path) } // A path mapping may have an extension if extension := tspath.TryGetExtensionFromPath(subst); extension != "" { @@ -1191,7 +1196,7 @@ func (r *resolutionState) tryLoadModuleUsingRootDirs() *resolved { } if r.tracer != nil { - r.tracer.write(diagnostics.X_rootDirs_option_is_set_using_it_to_resolve_relative_module_name_0.Format(r.name)) + r.tracer.write(diagnostics.X_rootDirs_option_is_set_using_it_to_resolve_relative_module_name_0, r.name) } candidate := tspath.NormalizePath(tspath.CombinePaths(r.containingDirectory, r.name)) @@ -1210,7 +1215,7 @@ func (r *resolutionState) tryLoadModuleUsingRootDirs() *resolved { (matchedNormalizedPrefix == "" || len(matchedNormalizedPrefix) < len(normalizedRoot)) if r.tracer != nil { - r.tracer.write(diagnostics.Checking_if_0_is_the_longest_matching_prefix_for_1_2.Format(normalizedRoot, candidate, isLongestMatchingPrefix)) + r.tracer.write(diagnostics.Checking_if_0_is_the_longest_matching_prefix_for_1_2, normalizedRoot, candidate, isLongestMatchingPrefix) } if isLongestMatchingPrefix { @@ -1221,13 +1226,13 @@ func (r *resolutionState) tryLoadModuleUsingRootDirs() *resolved { if matchedNormalizedPrefix != "" { if r.tracer != nil { - r.tracer.write(diagnostics.Longest_matching_prefix_for_0_is_1.Format(candidate, matchedNormalizedPrefix)) + r.tracer.write(diagnostics.Longest_matching_prefix_for_0_is_1, candidate, matchedNormalizedPrefix) } suffix := candidate[len(matchedNormalizedPrefix):] // first - try to load from a initial location if r.tracer != nil { - r.tracer.write(diagnostics.Loading_0_from_the_root_dir_1_candidate_location_2.Format(suffix, matchedNormalizedPrefix, candidate)) + r.tracer.write(diagnostics.Loading_0_from_the_root_dir_1_candidate_location_2, suffix, matchedNormalizedPrefix, candidate) } loader := func(extensions extensions, candidate string, onlyRecordFailures bool) *resolved { return r.nodeLoadModuleByRelativeName(extensions, candidate, onlyRecordFailures, true /*considerPackageJson*/) @@ -1237,7 +1242,7 @@ func (r *resolutionState) tryLoadModuleUsingRootDirs() *resolved { } if r.tracer != nil { - r.tracer.write(diagnostics.Trying_other_entries_in_rootDirs.Format()) + r.tracer.write(diagnostics.Trying_other_entries_in_rootDirs) } // then try to resolve using remaining entries in rootDirs for _, rootDir := range r.compilerOptions.RootDirs { @@ -1247,7 +1252,7 @@ func (r *resolutionState) tryLoadModuleUsingRootDirs() *resolved { } candidate := tspath.CombinePaths(tspath.NormalizePath(rootDir), suffix) if r.tracer != nil { - r.tracer.write(diagnostics.Loading_0_from_the_root_dir_1_candidate_location_2.Format(suffix, rootDir, candidate)) + r.tracer.write(diagnostics.Loading_0_from_the_root_dir_1_candidate_location_2, suffix, rootDir, candidate) } baseDirectory := tspath.GetDirectoryPath(candidate) if resolvedFileName := loader(r.extensions, candidate, !r.resolver.host.FS().DirectoryExists(baseDirectory)); !resolvedFileName.shouldContinueSearching() { @@ -1255,7 +1260,7 @@ func (r *resolutionState) tryLoadModuleUsingRootDirs() *resolved { } } if r.tracer != nil { - r.tracer.write(diagnostics.Module_resolution_using_rootDirs_has_failed.Format()) + r.tracer.write(diagnostics.Module_resolution_using_rootDirs_has_failed) } } return continueSearching() @@ -1263,14 +1268,14 @@ func (r *resolutionState) tryLoadModuleUsingRootDirs() *resolved { func (r *resolutionState) nodeLoadModuleByRelativeName(extensions extensions, candidate string, onlyRecordFailures bool, considerPackageJson bool) *resolved { if r.tracer != nil { - r.tracer.write(diagnostics.Loading_module_as_file_Slash_folder_candidate_module_location_0_target_file_types_Colon_1.Format(candidate, extensions.String())) + r.tracer.write(diagnostics.Loading_module_as_file_Slash_folder_candidate_module_location_0_target_file_types_Colon_1, candidate, extensions.String()) } if !tspath.HasTrailingDirectorySeparator(candidate) { if !onlyRecordFailures { parentOfCandidate := tspath.GetDirectoryPath(candidate) if !r.resolver.host.FS().DirectoryExists(parentOfCandidate) { if r.tracer != nil { - r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it.Format(parentOfCandidate)) + r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it, parentOfCandidate) } onlyRecordFailures = true } @@ -1289,7 +1294,7 @@ func (r *resolutionState) nodeLoadModuleByRelativeName(extensions extensions, ca candidateExists := r.resolver.host.FS().DirectoryExists(candidate) if !candidateExists { if r.tracer != nil { - r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it.Format(candidate)) + r.tracer.write(diagnostics.Directory_0_does_not_exist_skipping_all_lookups_in_it, candidate) } onlyRecordFailures = true } @@ -1331,7 +1336,7 @@ func (r *resolutionState) loadModuleFromFileNoImplicitExtensions(extensions exte extension := candidate[len(extensionless):] if r.tracer != nil { - r.tracer.write(diagnostics.File_name_0_has_a_1_extension_stripping_it.Format(candidate, extension)) + r.tracer.write(diagnostics.File_name_0_has_a_1_extension_stripping_it, candidate, extension) } return r.tryAddingExtensions(extensionless, extensions, extension, onlyRecordFailures) } @@ -1485,11 +1490,11 @@ func (r *resolutionState) tryFileLookup(fileName string, onlyRecordFailures bool if !onlyRecordFailures { if r.resolver.host.FS().FileExists(fileName) { if r.tracer != nil { - r.tracer.write(diagnostics.File_0_exists_use_it_as_a_name_resolution_result.Format(fileName)) + r.tracer.write(diagnostics.File_0_exists_use_it_as_a_name_resolution_result, fileName) } return true } else if r.tracer != nil { - r.tracer.write(diagnostics.File_0_does_not_exist.Format(fileName)) + r.tracer.write(diagnostics.File_0_does_not_exist, fileName) } } r.failedLookupLocations = append(r.failedLookupLocations, fileName) @@ -1561,7 +1566,7 @@ func (r *resolutionState) loadNodeModuleFromDirectoryWorker(ext extensions, cand moduleName = tspath.GetRelativePathFromDirectory(candidate, indexPath, tspath.ComparePathsOptions{}) } if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2.Format(versionPaths.Version, core.Version(), moduleName)) + r.tracer.write(diagnostics.X_package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2, versionPaths.Version, core.Version(), moduleName) } pathPatterns := TryParsePatterns(versionPaths.GetPaths()) if result := r.tryLoadModuleUsingPaths(ext, moduleName, candidate, versionPaths.GetPaths(), pathPatterns, loader, onlyRecordFailuresForPackageFile); !result.shouldContinueSearching() { @@ -1649,7 +1654,7 @@ func (r *resolutionState) getPackageJsonInfo(packageDirectory string, onlyRecord if existing := r.resolver.packageJsonInfoCache.Get(packageJsonPath); existing != nil { if existing.Contents != nil { if r.tracer != nil { - r.tracer.write(diagnostics.File_0_exists_according_to_earlier_cached_lookups.Format(packageJsonPath)) + r.tracer.write(diagnostics.File_0_exists_according_to_earlier_cached_lookups, packageJsonPath) } r.affectingLocations = append(r.affectingLocations, packageJsonPath) if existing.PackageDirectory == packageDirectory { @@ -1663,7 +1668,7 @@ func (r *resolutionState) getPackageJsonInfo(packageDirectory string, onlyRecord } } else { if existing.DirectoryExists && r.tracer != nil { - r.tracer.write(diagnostics.File_0_does_not_exist_according_to_earlier_cached_lookups.Format(packageJsonPath)) + r.tracer.write(diagnostics.File_0_does_not_exist_according_to_earlier_cached_lookups, packageJsonPath) } r.failedLookupLocations = append(r.failedLookupLocations, packageJsonPath) return nil @@ -1676,7 +1681,7 @@ func (r *resolutionState) getPackageJsonInfo(packageDirectory string, onlyRecord contents, _ := r.resolver.host.FS().ReadFile(packageJsonPath) packageJsonContent, err := packagejson.Parse([]byte(contents)) if r.tracer != nil { - r.tracer.write(diagnostics.Found_package_json_at_0.Format(packageJsonPath)) + r.tracer.write(diagnostics.Found_package_json_at_0, packageJsonPath) } result := &packagejson.InfoCacheEntry{ PackageDirectory: packageDirectory, @@ -1691,7 +1696,7 @@ func (r *resolutionState) getPackageJsonInfo(packageDirectory string, onlyRecord return result } else { if directoryExists && r.tracer != nil { - r.tracer.write(diagnostics.File_0_does_not_exist.Format(packageJsonPath)) + r.tracer.write(diagnostics.File_0_does_not_exist, packageJsonPath) } _ = r.resolver.packageJsonInfoCache.Set(packageJsonPath, &packagejson.InfoCacheEntry{ PackageDirectory: packageDirectory, @@ -1730,7 +1735,7 @@ func (r *resolutionState) readPackageJsonPeerDependencies(packageJsonInfo *packa return "" } if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_has_a_peerDependencies_field.Message()) + r.tracer.write(diagnostics.X_package_json_has_a_peerDependencies_field) } packageDirectory := r.realPath(packageJsonInfo.PackageDirectory) nodeModulesIndex := strings.LastIndex(packageDirectory, "/node_modules") @@ -1748,10 +1753,10 @@ func (r *resolutionState) readPackageJsonPeerDependencies(packageJsonInfo *packa builder.WriteString("@") builder.WriteString(version) if r.tracer != nil { - r.tracer.write(diagnostics.Found_peerDependency_0_with_1_version.Format(name, version)) + r.tracer.write(diagnostics.Found_peerDependency_0_with_1_version, name, version) } } else if r.tracer != nil { - r.tracer.write(diagnostics.Failed_to_find_peerDependency_0.Format(name)) + r.tracer.write(diagnostics.Failed_to_find_peerDependency_0, name) } } return builder.String() @@ -1760,7 +1765,7 @@ func (r *resolutionState) readPackageJsonPeerDependencies(packageJsonInfo *packa func (r *resolutionState) realPath(path string) string { rp := tspath.NormalizePath(r.resolver.host.FS().Realpath(path)) if r.tracer != nil { - r.tracer.write(diagnostics.Resolving_real_path_for_0_result_1.Format(path, rp)) + r.tracer.write(diagnostics.Resolving_real_path_for_0_result_1, path, rp) } return rp } @@ -1771,11 +1776,11 @@ func (r *resolutionState) validatePackageJSONField(fieldName string, field packa return true } if r.tracer != nil { - r.tracer.write(diagnostics.Expected_type_of_0_field_in_package_json_to_be_1_got_2.Format(fieldName, field.ExpectedJSONType(), field.ActualJSONType())) + r.tracer.write(diagnostics.Expected_type_of_0_field_in_package_json_to_be_1_got_2, fieldName, field.ExpectedJSONType(), field.ActualJSONType()) } } if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_does_not_have_a_0_field.Format(fieldName)) + r.tracer.write(diagnostics.X_package_json_does_not_have_a_0_field, fieldName) } return false } @@ -1786,13 +1791,13 @@ func (r *resolutionState) getPackageJSONPathField(fieldName string, field *packa } if field.Value == "" { if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_had_a_falsy_0_field.Format(fieldName)) + r.tracer.write(diagnostics.X_package_json_had_a_falsy_0_field, fieldName) } return "", false } path := tspath.NormalizePath(tspath.CombinePaths(directory, field.Value)) if r.tracer != nil { - r.tracer.write(diagnostics.X_package_json_has_0_field_1_that_references_2.Format(fieldName, field.Value, path)) + r.tracer.write(diagnostics.X_package_json_has_0_field_1_that_references_2, fieldName, field.Value, path) } return path, true } @@ -1813,7 +1818,7 @@ func (r *resolutionState) conditionMatches(condition string) bool { return false } -func (r *resolutionState) getTraceFunc() func(string) { +func (r *resolutionState) getTraceFunc() func(m *diagnostics.Message, args ...any) { if r.tracer != nil { return r.tracer.write } diff --git a/internal/packagejson/cache.go b/internal/packagejson/cache.go index ecff10e365..0295e4e76f 100644 --- a/internal/packagejson/cache.go +++ b/internal/packagejson/cache.go @@ -16,32 +16,52 @@ type PackageJson struct { Fields Parseable bool versionPaths VersionPaths - versionTraces []string + versionTraces []diagnosticAndArgs once sync.Once } -func (p *PackageJson) GetVersionPaths(trace func(string)) VersionPaths { +type diagnosticAndArgs struct { + message *diagnostics.Message + args []any +} + +func (p *PackageJson) GetVersionPaths(trace func(m *diagnostics.Message, args ...any)) VersionPaths { p.once.Do(func() { if p.Fields.TypesVersions.Type == JSONValueTypeNotPresent { - p.versionTraces = append(p.versionTraces, diagnostics.X_package_json_does_not_have_a_0_field.Format("typesVersions")) + p.versionTraces = append(p.versionTraces, diagnosticAndArgs{ + diagnostics.X_package_json_does_not_have_a_0_field, + []any{"typesVersions"}, + }) return } if p.Fields.TypesVersions.Type != JSONValueTypeObject { - p.versionTraces = append(p.versionTraces, diagnostics.Expected_type_of_0_field_in_package_json_to_be_1_got_2.Format("typesVersions", "object", p.Fields.TypesVersions.Type.String())) + p.versionTraces = append(p.versionTraces, diagnosticAndArgs{ + diagnostics.Expected_type_of_0_field_in_package_json_to_be_1_got_2, + []any{"typesVersions", "object", p.Fields.TypesVersions.Type.String()}, + }) return } - p.versionTraces = append(p.versionTraces, diagnostics.X_package_json_has_a_typesVersions_field_with_version_specific_path_mappings.Format("typesVersions")) + p.versionTraces = append(p.versionTraces, diagnosticAndArgs{ + diagnostics.X_package_json_has_a_typesVersions_field_with_version_specific_path_mappings, + []any{"typesVersions"}, + }) for key, value := range p.Fields.TypesVersions.AsObject().Entries() { keyRange, ok := semver.TryParseVersionRange(key) if !ok { - p.versionTraces = append(p.versionTraces, diagnostics.X_package_json_has_a_typesVersions_entry_0_that_is_not_a_valid_semver_range.Format(key)) + p.versionTraces = append(p.versionTraces, diagnosticAndArgs{ + diagnostics.X_package_json_has_a_typesVersions_entry_0_that_is_not_a_valid_semver_range, + []any{key}, + }) continue } if keyRange.Test(&typeScriptVersion) { if value.Type != JSONValueTypeObject { - p.versionTraces = append(p.versionTraces, diagnostics.Expected_type_of_0_field_in_package_json_to_be_1_got_2.Format("typesVersions['"+key+"']", "object", value.Type.String())) + p.versionTraces = append(p.versionTraces, diagnosticAndArgs{ + diagnostics.Expected_type_of_0_field_in_package_json_to_be_1_got_2, + []any{"typesVersions['" + key + "']", "object", value.Type.String()}, + }) return } p.versionPaths = VersionPaths{ @@ -52,11 +72,14 @@ func (p *PackageJson) GetVersionPaths(trace func(string)) VersionPaths { } } - p.versionTraces = append(p.versionTraces, diagnostics.X_package_json_does_not_have_a_typesVersions_entry_that_matches_version_0.Format(core.VersionMajorMinor())) + p.versionTraces = append(p.versionTraces, diagnosticAndArgs{ + diagnostics.X_package_json_does_not_have_a_typesVersions_entry_that_matches_version_0, + []any{core.VersionMajorMinor()}, + }) }) if trace != nil { for _, msg := range p.versionTraces { - trace(msg) + trace(msg.message, msg.args...) } } return p.versionPaths diff --git a/internal/project/compilerhost.go b/internal/project/compilerhost.go index c6293c701c..30fa7a72b7 100644 --- a/internal/project/compilerhost.go +++ b/internal/project/compilerhost.go @@ -6,6 +6,7 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/compiler" + "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/project/logging" "github.com/microsoft/typescript-go/internal/tsoptions" "github.com/microsoft/typescript-go/internal/tspath" @@ -131,7 +132,7 @@ func (c *compilerHost) GetSourceFile(opts ast.SourceFileParseOptions) *ast.Sourc } // Trace implements compiler.CompilerHost. -func (c *compilerHost) Trace(msg string) { +func (c *compilerHost) Trace(msg *diagnostics.Message, args ...any) { panic("unimplemented") } diff --git a/internal/project/session.go b/internal/project/session.go index b360dc35e1..5c5a2c96bb 100644 --- a/internal/project/session.go +++ b/internal/project/session.go @@ -13,6 +13,7 @@ import ( "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/compiler" "github.com/microsoft/typescript-go/internal/core" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/ls" "github.com/microsoft/typescript-go/internal/ls/lsconv" "github.com/microsoft/typescript-go/internal/ls/lsutil" @@ -48,6 +49,7 @@ type SessionOptions struct { LoggingEnabled bool PushDiagnosticsEnabled bool DebounceDelay time.Duration + Locale locale.Locale } type SessionInit struct { diff --git a/internal/stringutil/format.go b/internal/stringutil/format.go deleted file mode 100644 index 3c52e36d4e..0000000000 --- a/internal/stringutil/format.go +++ /dev/null @@ -1,19 +0,0 @@ -package stringutil - -import ( - "fmt" - "regexp" - "strconv" -) - -var placeholderRegexp = regexp.MustCompile(`{(\d+)}`) - -func Format(text string, args []any) string { - return placeholderRegexp.ReplaceAllStringFunc(text, func(match string) string { - index, err := strconv.ParseInt(match[1:len(match)-1], 10, 0) - if err != nil || int(index) >= len(args) { - panic("Invalid formatting placeholder") - } - return fmt.Sprintf("%v", args[int(index)]) - }) -} diff --git a/internal/testutil/harnessutil/harnessutil.go b/internal/testutil/harnessutil/harnessutil.go index ae0d04f040..482552a77a 100644 --- a/internal/testutil/harnessutil/harnessutil.go +++ b/internal/testutil/harnessutil/harnessutil.go @@ -21,7 +21,9 @@ import ( "github.com/microsoft/typescript-go/internal/collections" "github.com/microsoft/typescript-go/internal/compiler" "github.com/microsoft/typescript-go/internal/core" + "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/execute/incremental" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/outputpaths" "github.com/microsoft/typescript-go/internal/parser" "github.com/microsoft/typescript-go/internal/repo" @@ -531,8 +533,8 @@ func NewTracerForBaselining(opts tspath.ComparePathsOptions, builder *strings.Bu } } -func (t *TracerForBaselining) Trace(msg string) { - t.TraceWithWriter(t.builder, msg, true) +func (t *TracerForBaselining) Trace(msg *diagnostics.Message, args ...any) { + t.TraceWithWriter(t.builder, msg.Localize(locale.Default, args...), true) } func (t *TracerForBaselining) TraceWithWriter(w io.Writer, msg string, usePackageJsonCache bool) { diff --git a/internal/testutil/tsbaseline/error_baseline.go b/internal/testutil/tsbaseline/error_baseline.go index b3e20f5093..9109a00c13 100644 --- a/internal/testutil/tsbaseline/error_baseline.go +++ b/internal/testutil/tsbaseline/error_baseline.go @@ -12,6 +12,7 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnosticwriter" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/testutil/baseline" "github.com/microsoft/typescript-go/internal/testutil/harnessutil" "github.com/microsoft/typescript-go/internal/tspath" @@ -91,7 +92,7 @@ func iterateErrorBaseline[T diagnosticwriter.Diagnostic](t *testing.T, inputFile var result []string outputErrorText := func(diag diagnosticwriter.Diagnostic) { - message := diagnosticwriter.FlattenDiagnosticMessage(diag, harnessNewLine) + message := diagnosticwriter.FlattenDiagnosticMessage(diag, harnessNewLine, locale.Default) var errLines []string for line := range strings.SplitSeq(removeTestPathPrefixes(message, false), "\n") { @@ -112,7 +113,7 @@ func iterateErrorBaseline[T diagnosticwriter.Diagnostic](t *testing.T, inputFile if len(location) > 0 && isDefaultLibraryFile(info.File().FileName()) { location = diagnosticsLocationPattern.ReplaceAllString(location, "$1:--:--") } - errLines = append(errLines, fmt.Sprintf("!!! related TS%d%s: %s", info.Code(), location, diagnosticwriter.FlattenDiagnosticMessage(info, harnessNewLine))) + errLines = append(errLines, fmt.Sprintf("!!! related TS%d%s: %s", info.Code(), location, diagnosticwriter.FlattenDiagnosticMessage(info, harnessNewLine, locale.Default))) } for _, e := range errLines { diff --git a/internal/tsoptions/commandlineoption.go b/internal/tsoptions/commandlineoption.go index 6377c316c3..ca771fdd11 100644 --- a/internal/tsoptions/commandlineoption.go +++ b/internal/tsoptions/commandlineoption.go @@ -35,8 +35,8 @@ type CommandLineOption struct { // used in output in serializing and generate tsconfig Category *diagnostics.Message - // a flag indicating whether `validateJsonOptionValue` should perform extra checks - extraValidation bool + // What kind of extra validation `validateJsonOptionValue` should do + extraValidation extraValidation // true or undefined // used for configDirTemplateSubstitutionOptions @@ -65,6 +65,14 @@ type CommandLineOption struct { ElementOptions CommandLineOptionNameMap } +type extraValidation string + +const ( + extraValidationNone extraValidation = "" + extraValidationSpec extraValidation = "spec" + extraValidationLocale extraValidation = "locale" +) + func (o *CommandLineOption) DeprecatedKeys() *collections.Set[string] { if o.Kind != CommandLineOptionTypeEnum { return nil @@ -149,13 +157,13 @@ var commandLineOptionElements = map[string]*CommandLineOption{ Name: "excludeDirectory", Kind: CommandLineOptionTypeString, IsFilePath: true, - extraValidation: true, + extraValidation: extraValidationSpec, }, "excludeFiles": { Name: "excludeFile", Kind: CommandLineOptionTypeString, IsFilePath: true, - extraValidation: true, + extraValidation: extraValidationSpec, }, // Test infra options "libFiles": { diff --git a/internal/tsoptions/declscompiler.go b/internal/tsoptions/declscompiler.go index 7ef3119264..f2584810aa 100644 --- a/internal/tsoptions/declscompiler.go +++ b/internal/tsoptions/declscompiler.go @@ -211,6 +211,7 @@ var commonOptionsWithBuild = []*CommandLineOption{ IsCommandLineOnly: true, Description: diagnostics.Set_the_language_of_the_messaging_from_TypeScript_This_does_not_affect_emit, DefaultValueDescription: diagnostics.Platform_specific, + extraValidation: extraValidationLocale, }, { diff --git a/internal/tsoptions/parsedbuildcommandline.go b/internal/tsoptions/parsedbuildcommandline.go index 8a777b8c15..f0e4ad55ca 100644 --- a/internal/tsoptions/parsedbuildcommandline.go +++ b/internal/tsoptions/parsedbuildcommandline.go @@ -5,6 +5,7 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/core" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/tspath" ) @@ -19,6 +20,9 @@ type ParsedBuildCommandLine struct { resolvedProjectPaths []string resolvedProjectPathsOnce sync.Once + + locale locale.Locale + localeOnce sync.Once } func (p *ParsedBuildCommandLine) ResolvedProjectPaths() []string { @@ -31,3 +35,10 @@ func (p *ParsedBuildCommandLine) ResolvedProjectPaths() []string { }) return p.resolvedProjectPaths } + +func (p *ParsedBuildCommandLine) Locale() locale.Locale { + p.localeOnce.Do(func() { + p.locale, _ = locale.Parse(p.CompilerOptions.Locale) + }) + return p.locale +} diff --git a/internal/tsoptions/parsedcommandline.go b/internal/tsoptions/parsedcommandline.go index e60649300b..a00e80854a 100644 --- a/internal/tsoptions/parsedcommandline.go +++ b/internal/tsoptions/parsedcommandline.go @@ -10,6 +10,7 @@ import ( "github.com/microsoft/typescript-go/internal/ast" "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/glob" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/module" "github.com/microsoft/typescript-go/internal/outputpaths" "github.com/microsoft/typescript-go/internal/tspath" @@ -49,6 +50,9 @@ type ParsedCommandLine struct { literalFileNamesLen int fileNamesByPath map[tspath.Path]string // maps file names to their paths, used for quick lookups fileNamesByPathOnce sync.Once + + locale locale.Locale + localeOnce sync.Once } func NewParsedCommandLine( @@ -379,3 +383,10 @@ func (p *ParsedCommandLine) ReloadFileNamesOfParsedCommandLine(fs vfs.FS) *Parse } return &parsedCommandLine } + +func (p *ParsedCommandLine) Locale() locale.Locale { + p.localeOnce.Do(func() { + p.locale, _ = locale.Parse(p.CompilerOptions().Locale) + }) + return p.locale +} diff --git a/internal/tsoptions/tsconfigparsing.go b/internal/tsoptions/tsconfigparsing.go index 5945359f3d..140c4a78fd 100644 --- a/internal/tsoptions/tsconfigparsing.go +++ b/internal/tsoptions/tsconfigparsing.go @@ -14,6 +14,7 @@ import ( "github.com/microsoft/typescript-go/internal/debug" "github.com/microsoft/typescript-go/internal/diagnostics" "github.com/microsoft/typescript-go/internal/jsnum" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/module" "github.com/microsoft/typescript-go/internal/parser" "github.com/microsoft/typescript-go/internal/tspath" @@ -359,13 +360,22 @@ func validateJsonOptionValue( if val == nil { return nil, nil } - errors := []*ast.Diagnostic{} - if opt.extraValidation { - diag := specToDiagnostic(val.(string), false) - if diag != nil { + + var errors []*ast.Diagnostic + + switch opt.extraValidation { + case extraValidationSpec: + if diag := specToDiagnostic(val.(string), false); diag != nil { errors = append(errors, CreateDiagnosticForNodeInSourceFileOrCompilerDiagnostic(sourceFile, valueExpression, diag)) - return nil, errors } + case extraValidationLocale: + if _, ok := locale.Parse(val.(string)); !ok { + errors = append(errors, CreateDiagnosticForNodeInSourceFileOrCompilerDiagnostic(sourceFile, valueExpression, diagnostics.Locale_must_be_an_IETF_BCP_47_language_tag_Examples_Colon_0_1, "en", "ja-jp")) + } + } + + if len(errors) > 0 { + return nil, errors } return val, nil } diff --git a/internal/tsoptions/tsconfigparsing_test.go b/internal/tsoptions/tsconfigparsing_test.go index 3e6fd35976..d25fb144cb 100644 --- a/internal/tsoptions/tsconfigparsing_test.go +++ b/internal/tsoptions/tsconfigparsing_test.go @@ -14,6 +14,7 @@ import ( "github.com/microsoft/typescript-go/internal/core" "github.com/microsoft/typescript-go/internal/diagnosticwriter" "github.com/microsoft/typescript-go/internal/jsonutil" + "github.com/microsoft/typescript-go/internal/locale" "github.com/microsoft/typescript-go/internal/parser" "github.com/microsoft/typescript-go/internal/repo" "github.com/microsoft/typescript-go/internal/testutil/baseline" @@ -1025,7 +1026,7 @@ func TestParseSrcCompiler(t *testing.T) { if len(parsed.Diagnostics()) > 0 { for _, error := range parsed.Diagnostics() { - t.Log(error.Message()) + t.Log(error.Localize(locale.Default)) } t.FailNow() } @@ -1047,7 +1048,7 @@ func TestParseSrcCompiler(t *testing.T) { if len(parseConfigFileContent.Errors) > 0 { for _, error := range parseConfigFileContent.Errors { - t.Log(error.Message()) + t.Log(error.Localize(locale.Default)) } t.FailNow() } diff --git a/testdata/baselines/reference/tsbuild/commandLine/bad-locale.js b/testdata/baselines/reference/tsbuild/commandLine/bad-locale.js new file mode 100644 index 0000000000..f85b09a8f9 --- /dev/null +++ b/testdata/baselines/reference/tsbuild/commandLine/bad-locale.js @@ -0,0 +1,9 @@ +currentDirectory::/home/src/workspaces/project +useCaseSensitiveFileNames::true +Input:: + +tsgo --build --help --locale whoops +ExitStatus:: DiagnosticsPresent_OutputsSkipped +Output:: +error TS6048: Locale must be an IETF BCP 47 language tag. Examples: 'en', 'ja-jp'. + diff --git a/testdata/baselines/reference/tsbuild/commandLine/locale.js b/testdata/baselines/reference/tsbuild/commandLine/locale.js new file mode 100644 index 0000000000..a870d55c02 --- /dev/null +++ b/testdata/baselines/reference/tsbuild/commandLine/locale.js @@ -0,0 +1,147 @@ +currentDirectory::/home/src/workspaces/project +useCaseSensitiveFileNames::true +Input:: + +tsgo --build --help --locale en +ExitStatus:: Success +Output:: +Version FakeTSVersion +tsc: The TypeScript Compiler - Version FakeTSVersion + +BUILD OPTIONS + +Using --build, -b will make tsc behave more like a build orchestrator than a compiler. This is used to trigger building composite projects which you can learn more about at https://aka.ms/tsc-composite-builds + +--help, -h +Print this message. + +--help, -? + + +--watch, -w +Watch input files. + +--preserveWatchOutput +Disable wiping the console in watch mode. +type: boolean +default: false + +--listFiles +Print all of the files read during the compilation. +type: boolean +default: false + +--explainFiles +Print files read during the compilation including why it was included. +type: boolean +default: false + +--listEmittedFiles +Print the names of emitted files after a compilation. +type: boolean +default: false + +--pretty +Enable color and formatting in TypeScript's output to make compiler errors easier to read. +type: boolean +default: true + +--traceResolution +Log paths used during the 'moduleResolution' process. +type: boolean +default: false + +--diagnostics +Output compiler performance information after building. +type: boolean +default: false + +--extendedDiagnostics +Output more detailed compiler performance information after building. +type: boolean +default: false + +--generateCpuProfile +Emit a v8 CPU profile of the compiler run for debugging. +type: string +default: profile.cpuprofile + +--generateTrace +Generates an event trace and a list of types. + +--incremental, -i +Save .tsbuildinfo files to allow for incremental compilation of projects. +type: boolean +default: `false`, unless `composite` is set + +--declaration, -d +Generate .d.ts files from TypeScript and JavaScript files in your project. +type: boolean +default: `false`, unless `composite` is set + +--declarationMap +Create sourcemaps for d.ts files. +type: boolean +default: false + +--emitDeclarationOnly +Only output d.ts files and not JavaScript files. +type: boolean +default: false + +--sourceMap +Create source map files for emitted JavaScript files. +type: boolean +default: false + +--inlineSourceMap +Include sourcemap files inside the emitted JavaScript. +type: boolean +default: false + +--noCheck +Disable full type checking (only critical parse and emit errors will be reported). +type: boolean +default: false + +--noEmit +Disable emitting files from a compilation. +type: boolean +default: false + +--assumeChangesOnlyAffectDirectDependencies +Have recompiles in projects that use 'incremental' and 'watch' mode assume that changes within a file will only affect files directly depending on it. +type: boolean +default: false + +--locale +Set the language of the messaging from TypeScript. This does not affect emit. + +--quiet, -q +Do not print diagnostics. + +--singleThreaded +Run in single threaded mode. + +--pprofDir +Generate pprof CPU/memory profiles to the given directory. + +--checkers +Set the number of checkers per project. + +--verbose, -v +Enable verbose logging. + +--dry, -d +Show what would be built (or deleted, if specified with '--clean') + +--force, -f +Build all projects, including those that appear to be up to date. + +--clean +Delete the outputs of all projects. + +--stopBuildOnErrors +Skip building downstream projects on error in upstream project. + + diff --git a/testdata/baselines/reference/tsbuild/declarationEmit/reports-dts-generation-errors-with-incremental.js b/testdata/baselines/reference/tsbuild/declarationEmit/reports-dts-generation-errors-with-incremental.js index a82f347c23..e4db762f75 100644 --- a/testdata/baselines/reference/tsbuild/declarationEmit/reports-dts-generation-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/declarationEmit/reports-dts-generation-errors-with-incremental.js @@ -95,7 +95,7 @@ import ky from 'ky'; export const api = ky.extend({}); //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[3],"fileNames":["lib.esnext.full.d.ts","./node_modules/ky/distribution/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"b9b50c37c18e43d94b0dd4fb43967f10-type KyInstance = {\n extend(options: Record): KyInstance;\n}\ndeclare const ky: KyInstance;\nexport default ky;","impliedNodeFormat":99},{"version":"0f5091e963c17913313e4969c59e6eb4-import ky from 'ky';\nexport const api = ky.extend({});","signature":"5816fe34b5cf354b0d0d19bc77874616-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named.","impliedNodeFormat":99}],"fileIdsList":[[2]],"options":{"composite":false,"declaration":true,"module":199,"skipLibCheck":true,"skipDefaultLibCheck":true},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":34,"end":37,"code":4023,"category":1,"message":"Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named."}]]]} +{"version":"FakeTSVersion","root":[3],"fileNames":["lib.esnext.full.d.ts","./node_modules/ky/distribution/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"b9b50c37c18e43d94b0dd4fb43967f10-type KyInstance = {\n extend(options: Record): KyInstance;\n}\ndeclare const ky: KyInstance;\nexport default ky;","impliedNodeFormat":99},{"version":"0f5091e963c17913313e4969c59e6eb4-import ky from 'ky';\nexport const api = ky.extend({});","signature":"80d0207a54fef9a805b5e009ed639094-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023\napi\nKyInstance\n\"/home/src/workspaces/project/node_modules/ky/distribution/index\"\n","impliedNodeFormat":99}],"fileIdsList":[[2]],"options":{"composite":false,"declaration":true,"module":199,"skipLibCheck":true,"skipDefaultLibCheck":true},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":34,"end":37,"code":4023,"category":1,"messageKey":"Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023","messageArgs":["api","KyInstance","\"/home/src/workspaces/project/node_modules/ky/distribution/index\""]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -138,11 +138,11 @@ export const api = ky.extend({}); { "fileName": "./index.ts", "version": "0f5091e963c17913313e4969c59e6eb4-import ky from 'ky';\nexport const api = ky.extend({});", - "signature": "5816fe34b5cf354b0d0d19bc77874616-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named.", + "signature": "80d0207a54fef9a805b5e009ed639094-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023\napi\nKyInstance\n\"/home/src/workspaces/project/node_modules/ky/distribution/index\"\n", "impliedNodeFormat": "ESNext", "original": { "version": "0f5091e963c17913313e4969c59e6eb4-import ky from 'ky';\nexport const api = ky.extend({});", - "signature": "5816fe34b5cf354b0d0d19bc77874616-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named.", + "signature": "80d0207a54fef9a805b5e009ed639094-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023\napi\nKyInstance\n\"/home/src/workspaces/project/node_modules/ky/distribution/index\"\n", "impliedNodeFormat": 99 } } @@ -173,12 +173,17 @@ export const api = ky.extend({}); "end": 37, "code": 4023, "category": 1, - "message": "Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named." + "messageKey": "Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023", + "messageArgs": [ + "api", + "KyInstance", + "\"/home/src/workspaces/project/node_modules/ky/distribution/index\"" + ] } ] ] ], - "size": 1983 + "size": 2025 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/demo/in-bad-ref-branch-reports-the-error-about-files-not-in-rootDir-at-the-import-location.js b/testdata/baselines/reference/tsbuild/demo/in-bad-ref-branch-reports-the-error-about-files-not-in-rootDir-at-the-import-location.js index 57c66f13c9..747675873f 100644 --- a/testdata/baselines/reference/tsbuild/demo/in-bad-ref-branch-reports-the-error-about-files-not-in-rootDir-at-the-import-location.js +++ b/testdata/baselines/reference/tsbuild/demo/in-bad-ref-branch-reports-the-error-about-files-not-in-rootDir-at-the-import-location.js @@ -400,7 +400,7 @@ Object.defineProperty(exports, "createDog", { enumerable: true, get: function () "size": 2794 } //// [/user/username/projects/demo/lib/core/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","errors":true,"root":[5],"fileNames":["lib.d.ts","../../animals/animal.ts","../../animals/dog.ts","../../animals/index.ts","../../core/utilities.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"47f086fff365b1e8b96a6df2c4313c1a-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}","signature":"1d76529d4652ddf9ebdfa65e748240fb-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}\n","impliedNodeFormat":1},{"version":"39dbb9b755eef022e56879989968e5cf-import Animal from '.';\nimport { makeRandomName } from '../core/utilities';\n\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\n\nexport function createDog(): Dog {\n return ({\n size: \"medium\",\n woof: function(this: Dog) {\n console.log(`${ this.name } says \"Woof\"!`);\n },\n name: makeRandomName()\n });\n}","signature":"4dc4bc559452869bfd0d92b5ed5d604f-import Animal from '.';\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\nexport declare function createDog(): Dog;\n","impliedNodeFormat":1},{"version":"d6a6b65b86b0330b1a1bd96b1738d5a4-import Animal from './animal';\n\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };","signature":"a3e41a5ccafc3d07a201f0603e28edcf-import Animal from './animal';\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };\n","impliedNodeFormat":1},{"version":"c71a99e072793c29cda49dd3fea04661-import * as A from '../animals'\nexport function makeRandomName() {\n return \"Bob!?! \";\n}\n\nexport function lastElementOf(arr: T[]): T | undefined {\n if (arr.length === 0) return undefined;\n return arr[arr.length - 1];\n}","signature":"096c311e7aecdb577f7b613fbf1716e5-export declare function makeRandomName(): string;\nexport declare function lastElementOf(arr: T[]): T | undefined;\n","impliedNodeFormat":1}],"fileIdsList":[[4,5],[2,3],[4]],"options":{"composite":true,"declaration":true,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","rootDir":"../../core","strict":true,"target":1},"referencedMap":[[3,1],[4,2],[5,3]],"semanticDiagnosticsPerFile":[[5,[{"pos":12,"end":13,"code":6133,"category":1,"message":"'A' is declared but its value is never read.","reportsUnnecessary":true}]]],"latestChangedDtsFile":"./utilities.d.ts"} +{"version":"FakeTSVersion","errors":true,"root":[5],"fileNames":["lib.d.ts","../../animals/animal.ts","../../animals/dog.ts","../../animals/index.ts","../../core/utilities.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"47f086fff365b1e8b96a6df2c4313c1a-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}","signature":"1d76529d4652ddf9ebdfa65e748240fb-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}\n","impliedNodeFormat":1},{"version":"39dbb9b755eef022e56879989968e5cf-import Animal from '.';\nimport { makeRandomName } from '../core/utilities';\n\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\n\nexport function createDog(): Dog {\n return ({\n size: \"medium\",\n woof: function(this: Dog) {\n console.log(`${ this.name } says \"Woof\"!`);\n },\n name: makeRandomName()\n });\n}","signature":"4dc4bc559452869bfd0d92b5ed5d604f-import Animal from '.';\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\nexport declare function createDog(): Dog;\n","impliedNodeFormat":1},{"version":"d6a6b65b86b0330b1a1bd96b1738d5a4-import Animal from './animal';\n\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };","signature":"a3e41a5ccafc3d07a201f0603e28edcf-import Animal from './animal';\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };\n","impliedNodeFormat":1},{"version":"c71a99e072793c29cda49dd3fea04661-import * as A from '../animals'\nexport function makeRandomName() {\n return \"Bob!?! \";\n}\n\nexport function lastElementOf(arr: T[]): T | undefined {\n if (arr.length === 0) return undefined;\n return arr[arr.length - 1];\n}","signature":"096c311e7aecdb577f7b613fbf1716e5-export declare function makeRandomName(): string;\nexport declare function lastElementOf(arr: T[]): T | undefined;\n","impliedNodeFormat":1}],"fileIdsList":[[4,5],[2,3],[4]],"options":{"composite":true,"declaration":true,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","rootDir":"../../core","strict":true,"target":1},"referencedMap":[[3,1],[4,2],[5,3]],"semanticDiagnosticsPerFile":[[5,[{"pos":12,"end":13,"code":6133,"category":1,"messageKey":"_0_is_declared_but_its_value_is_never_read_6133","messageArgs":["A"],"reportsUnnecessary":true}]]],"latestChangedDtsFile":"./utilities.d.ts"} //// [/user/username/projects/demo/lib/core/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -526,14 +526,17 @@ Object.defineProperty(exports, "createDog", { enumerable: true, get: function () "end": 13, "code": 6133, "category": 1, - "message": "'A' is declared but its value is never read.", + "messageKey": "_0_is_declared_but_its_value_is_never_read_6133", + "messageArgs": [ + "A" + ], "reportsUnnecessary": true } ] ] ], "latestChangedDtsFile": "./utilities.d.ts", - "size": 3302 + "size": 3328 } //// [/user/username/projects/demo/lib/core/utilities.d.ts] *new* export declare function makeRandomName(): string; diff --git a/testdata/baselines/reference/tsbuild/fileDelete/detects-deleted-file.js b/testdata/baselines/reference/tsbuild/fileDelete/detects-deleted-file.js index 2603d2cd2e..bc6d9873a6 100644 --- a/testdata/baselines/reference/tsbuild/fileDelete/detects-deleted-file.js +++ b/testdata/baselines/reference/tsbuild/fileDelete/detects-deleted-file.js @@ -325,7 +325,7 @@ Found 1 error in child/child.ts:1 //// [/home/src/workspaces/solution/child/child.js] *rewrite with same content* //// [/home/src/workspaces/solution/child/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./child.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9686fb058ae9baf28ea93ef1e3b32b74-import { child2 } from \"../child/child2\";\nexport function child() {\n child2();\n}","signature":"3a48d078ac909d932ed914f17038d634-export declare function child(): void;\n","impliedNodeFormat":1}],"options":{"composite":true},"semanticDiagnosticsPerFile":[[2,[{"pos":23,"end":40,"code":2307,"category":1,"message":"Cannot find module '../child/child2' or its corresponding type declarations."}]]],"latestChangedDtsFile":"./child.d.ts"} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./child.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9686fb058ae9baf28ea93ef1e3b32b74-import { child2 } from \"../child/child2\";\nexport function child() {\n child2();\n}","signature":"3a48d078ac909d932ed914f17038d634-export declare function child(): void;\n","impliedNodeFormat":1}],"options":{"composite":true},"semanticDiagnosticsPerFile":[[2,[{"pos":23,"end":40,"code":2307,"category":1,"messageKey":"Cannot_find_module_0_or_its_corresponding_type_declarations_2307","messageArgs":["../child/child2"]}]]],"latestChangedDtsFile":"./child.d.ts"} //// [/home/src/workspaces/solution/child/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -378,13 +378,16 @@ Found 1 error in child/child.ts:1 "end": 40, "code": 2307, "category": 1, - "message": "Cannot find module '../child/child2' or its corresponding type declarations." + "messageKey": "Cannot_find_module_0_or_its_corresponding_type_declarations_2307", + "messageArgs": [ + "../child/child2" + ] } ] ] ], "latestChangedDtsFile": "./child.d.ts", - "size": 1344 + "size": 1369 } //// [/home/src/workspaces/solution/main/tsconfig.tsbuildinfo] *mTime changed* diff --git a/testdata/baselines/reference/tsbuild/inferredTypeFromTransitiveModule/reports-errors-in-files-affected-by-change-in-signature-with-isolatedModules.js b/testdata/baselines/reference/tsbuild/inferredTypeFromTransitiveModule/reports-errors-in-files-affected-by-change-in-signature-with-isolatedModules.js index b58b23c468..efa4fc46fc 100644 --- a/testdata/baselines/reference/tsbuild/inferredTypeFromTransitiveModule/reports-errors-in-files-affected-by-change-in-signature-with-isolatedModules.js +++ b/testdata/baselines/reference/tsbuild/inferredTypeFromTransitiveModule/reports-errors-in-files-affected-by-change-in-signature-with-isolatedModules.js @@ -364,7 +364,7 @@ export declare const lazyBar: LazyAction<() => void, typeof import("./lazyIndex" //// [/home/src/workspaces/project/obj/lazyIndex.d.ts] *rewrite with same content* //// [/home/src/workspaces/project/obj/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,6]],"fileNames":["lib.d.ts","../bar.ts","../bundling.ts","../global.d.ts","../lazyIndex.ts","../index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"0bd8823a281968531aa051fd0166b47a-interface RawAction {\n (...args: any[]): Promise | void;\n}\ninterface ActionFactory {\n (target: T): T;\n}\ndeclare function foo(): ActionFactory;\nexport default foo()(function foobar(): void {\n});","signature":"6cd64ed70c0d0d178b062e1470eb929d-declare const _default: () => void;\nexport default _default;\n","impliedNodeFormat":1},{"version":"16bf1b870d8b21533eda3b1f1b87cd77-export class LazyModule {\n constructor(private importCallback: () => Promise) {}\n}\n\nexport class LazyAction<\n TAction extends (...args: any[]) => any,\n TModule\n> {\n constructor(_lazyModule: LazyModule, _getter: (module: TModule) => TAction) {\n }\n}","signature":"5e4757586f6f5d494b6763f1e808313a-export declare class LazyModule {\n private importCallback;\n constructor(importCallback: () => Promise);\n}\nexport declare class LazyAction any, TModule> {\n constructor(_lazyModule: LazyModule, _getter: (module: TModule) => TAction);\n}\n","impliedNodeFormat":1},{"version":"9c9274fd70d574f2b4b68a2891bd4c47-interface PromiseConstructor {\n new (): Promise;\n}\ndeclare var Promise: PromiseConstructor;\ninterface Promise {\n}","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"60603312318c6195044a5691dcb10507-export { default as bar } from './bar';import { default as bar } from './bar';\nbar(\"hello\");","signature":"3a848e147ba2aebbd888c3c7bbab715b-export { default as bar } from './bar';\n","impliedNodeFormat":1},{"version":"d552d2a19fa05b15aa33018233d09810-import { LazyAction, LazyModule } from './bundling';\nconst lazyModule = new LazyModule(() =>\n import('./lazyIndex')\n);\nexport const lazyBar = new LazyAction(lazyModule, m => m.bar);","signature":"58c7056d7920602a0f958afefa15677d-import { LazyAction } from './bundling';\nexport declare const lazyBar: LazyAction<() => void, typeof import(\"./lazyIndex\")>;\n","impliedNodeFormat":1}],"fileIdsList":[[3,5],[2]],"options":{"declaration":true,"outDir":"./","target":1},"referencedMap":[[6,1],[5,2]],"semanticDiagnosticsPerFile":[[5,[{"pos":83,"end":90,"code":2554,"category":1,"message":"Expected 0 arguments, but got 1."}]]]} +{"version":"FakeTSVersion","root":[[2,6]],"fileNames":["lib.d.ts","../bar.ts","../bundling.ts","../global.d.ts","../lazyIndex.ts","../index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"0bd8823a281968531aa051fd0166b47a-interface RawAction {\n (...args: any[]): Promise | void;\n}\ninterface ActionFactory {\n (target: T): T;\n}\ndeclare function foo(): ActionFactory;\nexport default foo()(function foobar(): void {\n});","signature":"6cd64ed70c0d0d178b062e1470eb929d-declare const _default: () => void;\nexport default _default;\n","impliedNodeFormat":1},{"version":"16bf1b870d8b21533eda3b1f1b87cd77-export class LazyModule {\n constructor(private importCallback: () => Promise) {}\n}\n\nexport class LazyAction<\n TAction extends (...args: any[]) => any,\n TModule\n> {\n constructor(_lazyModule: LazyModule, _getter: (module: TModule) => TAction) {\n }\n}","signature":"5e4757586f6f5d494b6763f1e808313a-export declare class LazyModule {\n private importCallback;\n constructor(importCallback: () => Promise);\n}\nexport declare class LazyAction any, TModule> {\n constructor(_lazyModule: LazyModule, _getter: (module: TModule) => TAction);\n}\n","impliedNodeFormat":1},{"version":"9c9274fd70d574f2b4b68a2891bd4c47-interface PromiseConstructor {\n new (): Promise;\n}\ndeclare var Promise: PromiseConstructor;\ninterface Promise {\n}","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"60603312318c6195044a5691dcb10507-export { default as bar } from './bar';import { default as bar } from './bar';\nbar(\"hello\");","signature":"3a848e147ba2aebbd888c3c7bbab715b-export { default as bar } from './bar';\n","impliedNodeFormat":1},{"version":"d552d2a19fa05b15aa33018233d09810-import { LazyAction, LazyModule } from './bundling';\nconst lazyModule = new LazyModule(() =>\n import('./lazyIndex')\n);\nexport const lazyBar = new LazyAction(lazyModule, m => m.bar);","signature":"58c7056d7920602a0f958afefa15677d-import { LazyAction } from './bundling';\nexport declare const lazyBar: LazyAction<() => void, typeof import(\"./lazyIndex\")>;\n","impliedNodeFormat":1}],"fileIdsList":[[3,5],[2]],"options":{"declaration":true,"outDir":"./","target":1},"referencedMap":[[6,1],[5,2]],"semanticDiagnosticsPerFile":[[5,[{"pos":83,"end":90,"code":2554,"category":1,"messageKey":"Expected_0_arguments_but_got_1_2554","messageArgs":["0","1"]}]]]} //// [/home/src/workspaces/project/obj/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -493,12 +493,16 @@ export declare const lazyBar: LazyAction<() => void, typeof import("./lazyIndex" "end": 90, "code": 2554, "category": 1, - "message": "Expected 0 arguments, but got 1." + "messageKey": "Expected_0_arguments_but_got_1_2554", + "messageArgs": [ + "0", + "1" + ] } ] ] ], - "size": 3253 + "size": 3283 } tsconfig.json:: @@ -730,7 +734,7 @@ export declare const lazyBar: LazyAction<() => void, typeof import("./lazyIndex" //// [/home/src/workspaces/project/obj/lazyIndex.d.ts] *rewrite with same content* //// [/home/src/workspaces/project/obj/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,6]],"fileNames":["lib.d.ts","../bar.ts","../bundling.ts","../global.d.ts","../lazyIndex.ts","../index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"0bd8823a281968531aa051fd0166b47a-interface RawAction {\n (...args: any[]): Promise | void;\n}\ninterface ActionFactory {\n (target: T): T;\n}\ndeclare function foo(): ActionFactory;\nexport default foo()(function foobar(): void {\n});","signature":"6cd64ed70c0d0d178b062e1470eb929d-declare const _default: () => void;\nexport default _default;\n","impliedNodeFormat":1},{"version":"16bf1b870d8b21533eda3b1f1b87cd77-export class LazyModule {\n constructor(private importCallback: () => Promise) {}\n}\n\nexport class LazyAction<\n TAction extends (...args: any[]) => any,\n TModule\n> {\n constructor(_lazyModule: LazyModule, _getter: (module: TModule) => TAction) {\n }\n}","signature":"5e4757586f6f5d494b6763f1e808313a-export declare class LazyModule {\n private importCallback;\n constructor(importCallback: () => Promise);\n}\nexport declare class LazyAction any, TModule> {\n constructor(_lazyModule: LazyModule, _getter: (module: TModule) => TAction);\n}\n","impliedNodeFormat":1},{"version":"9c9274fd70d574f2b4b68a2891bd4c47-interface PromiseConstructor {\n new (): Promise;\n}\ndeclare var Promise: PromiseConstructor;\ninterface Promise {\n}","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"60603312318c6195044a5691dcb10507-export { default as bar } from './bar';import { default as bar } from './bar';\nbar(\"hello\");","signature":"3a848e147ba2aebbd888c3c7bbab715b-export { default as bar } from './bar';\n","impliedNodeFormat":1},{"version":"d552d2a19fa05b15aa33018233d09810-import { LazyAction, LazyModule } from './bundling';\nconst lazyModule = new LazyModule(() =>\n import('./lazyIndex')\n);\nexport const lazyBar = new LazyAction(lazyModule, m => m.bar);","signature":"58c7056d7920602a0f958afefa15677d-import { LazyAction } from './bundling';\nexport declare const lazyBar: LazyAction<() => void, typeof import(\"./lazyIndex\")>;\n","impliedNodeFormat":1}],"fileIdsList":[[3,5],[2]],"options":{"declaration":true,"outDir":"./","target":1},"referencedMap":[[6,1],[5,2]],"semanticDiagnosticsPerFile":[[5,[{"pos":83,"end":90,"code":2554,"category":1,"message":"Expected 0 arguments, but got 1."}]]]} +{"version":"FakeTSVersion","root":[[2,6]],"fileNames":["lib.d.ts","../bar.ts","../bundling.ts","../global.d.ts","../lazyIndex.ts","../index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"0bd8823a281968531aa051fd0166b47a-interface RawAction {\n (...args: any[]): Promise | void;\n}\ninterface ActionFactory {\n (target: T): T;\n}\ndeclare function foo(): ActionFactory;\nexport default foo()(function foobar(): void {\n});","signature":"6cd64ed70c0d0d178b062e1470eb929d-declare const _default: () => void;\nexport default _default;\n","impliedNodeFormat":1},{"version":"16bf1b870d8b21533eda3b1f1b87cd77-export class LazyModule {\n constructor(private importCallback: () => Promise) {}\n}\n\nexport class LazyAction<\n TAction extends (...args: any[]) => any,\n TModule\n> {\n constructor(_lazyModule: LazyModule, _getter: (module: TModule) => TAction) {\n }\n}","signature":"5e4757586f6f5d494b6763f1e808313a-export declare class LazyModule {\n private importCallback;\n constructor(importCallback: () => Promise);\n}\nexport declare class LazyAction any, TModule> {\n constructor(_lazyModule: LazyModule, _getter: (module: TModule) => TAction);\n}\n","impliedNodeFormat":1},{"version":"9c9274fd70d574f2b4b68a2891bd4c47-interface PromiseConstructor {\n new (): Promise;\n}\ndeclare var Promise: PromiseConstructor;\ninterface Promise {\n}","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"60603312318c6195044a5691dcb10507-export { default as bar } from './bar';import { default as bar } from './bar';\nbar(\"hello\");","signature":"3a848e147ba2aebbd888c3c7bbab715b-export { default as bar } from './bar';\n","impliedNodeFormat":1},{"version":"d552d2a19fa05b15aa33018233d09810-import { LazyAction, LazyModule } from './bundling';\nconst lazyModule = new LazyModule(() =>\n import('./lazyIndex')\n);\nexport const lazyBar = new LazyAction(lazyModule, m => m.bar);","signature":"58c7056d7920602a0f958afefa15677d-import { LazyAction } from './bundling';\nexport declare const lazyBar: LazyAction<() => void, typeof import(\"./lazyIndex\")>;\n","impliedNodeFormat":1}],"fileIdsList":[[3,5],[2]],"options":{"declaration":true,"outDir":"./","target":1},"referencedMap":[[6,1],[5,2]],"semanticDiagnosticsPerFile":[[5,[{"pos":83,"end":90,"code":2554,"category":1,"messageKey":"Expected_0_arguments_but_got_1_2554","messageArgs":["0","1"]}]]]} //// [/home/src/workspaces/project/obj/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -859,12 +863,16 @@ export declare const lazyBar: LazyAction<() => void, typeof import("./lazyIndex" "end": 90, "code": 2554, "category": 1, - "message": "Expected 0 arguments, but got 1." + "messageKey": "Expected_0_arguments_but_got_1_2554", + "messageArgs": [ + "0", + "1" + ] } ] ] ], - "size": 3253 + "size": 3283 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/javascriptProjectEmit/loads-js-based-projects-and-emits-them-correctly.js b/testdata/baselines/reference/tsbuild/javascriptProjectEmit/loads-js-based-projects-and-emits-them-correctly.js index bbd565a6cd..8397717405 100644 --- a/testdata/baselines/reference/tsbuild/javascriptProjectEmit/loads-js-based-projects-and-emits-them-correctly.js +++ b/testdata/baselines/reference/tsbuild/javascriptProjectEmit/loads-js-based-projects-and-emits-them-correctly.js @@ -217,7 +217,7 @@ function getVar() { } //// [/home/src/workspaces/lib/sub-project-2/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../common/nominal.d.ts","../sub-project/index.d.ts","../../solution/sub-project-2/index.js"],"fileInfos":[{"version":"24b4796cd50d1a9aabad1583878c494d-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n readonly species: symbol;\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"de751e2539eb6f12413f7067ad0a0ef5-export type Nominal = T & {\n [Symbol.species]: Name;\n};\ndeclare const _default: {};\nexport = _default;\n","225285a996cc5c4120877a377890d79e-import { Nominal } from '../common/nominal';\nexport type MyNominal = Nominal;\n/**\n * @typedef {Nominal} MyNominal\n */ \n",{"version":"db2a90e082fd17d65127bda69975a727-import { MyNominal } from '../sub-project/index';\n\nconst variable = {\n key: /** @type {MyNominal} */('value'),\n};\n\n/**\n * @return {keyof typeof variable}\n */\nexport function getVar() {\n return 'key';\n}","signature":"f2cd6630b2dfa04d1fc92179f15d1647-declare const variable: {\n key: Nominal;\n};\n/**\n * @return {keyof typeof variable}\n */\nexport declare function getVar(): keyof typeof variable;\nexport {};\n","impliedNodeFormat":1}],"fileIdsList":[[2],[3]],"options":{"allowJs":true,"checkJs":true,"composite":true,"declaration":true,"outDir":"..","rootDir":"../../solution","skipLibCheck":true},"referencedMap":[[3,1],[4,2]],"semanticDiagnosticsPerFile":[[4,[{"pos":9,"end":18,"code":18042,"category":1,"message":"'MyNominal' is a type and cannot be imported in JavaScript files. Use 'import(\"../sub-project/index\").MyNominal' in a JSDoc type annotation."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../common/nominal.d.ts","../sub-project/index.d.ts","../../solution/sub-project-2/index.js"],"fileInfos":[{"version":"24b4796cd50d1a9aabad1583878c494d-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n readonly species: symbol;\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"de751e2539eb6f12413f7067ad0a0ef5-export type Nominal = T & {\n [Symbol.species]: Name;\n};\ndeclare const _default: {};\nexport = _default;\n","225285a996cc5c4120877a377890d79e-import { Nominal } from '../common/nominal';\nexport type MyNominal = Nominal;\n/**\n * @typedef {Nominal} MyNominal\n */ \n",{"version":"db2a90e082fd17d65127bda69975a727-import { MyNominal } from '../sub-project/index';\n\nconst variable = {\n key: /** @type {MyNominal} */('value'),\n};\n\n/**\n * @return {keyof typeof variable}\n */\nexport function getVar() {\n return 'key';\n}","signature":"f2cd6630b2dfa04d1fc92179f15d1647-declare const variable: {\n key: Nominal;\n};\n/**\n * @return {keyof typeof variable}\n */\nexport declare function getVar(): keyof typeof variable;\nexport {};\n","impliedNodeFormat":1}],"fileIdsList":[[2],[3]],"options":{"allowJs":true,"checkJs":true,"composite":true,"declaration":true,"outDir":"..","rootDir":"../../solution","skipLibCheck":true},"referencedMap":[[3,1],[4,2]],"semanticDiagnosticsPerFile":[[4,[{"pos":9,"end":18,"code":18042,"category":1,"messageKey":"_0_is_a_type_and_cannot_be_imported_in_JavaScript_files_Use_1_in_a_JSDoc_type_annotation_18042","messageArgs":["MyNominal","import(\"../sub-project/index\").MyNominal"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/home/src/workspaces/lib/sub-project-2/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -306,13 +306,17 @@ function getVar() { "end": 18, "code": 18042, "category": 1, - "message": "'MyNominal' is a type and cannot be imported in JavaScript files. Use 'import(\"../sub-project/index\").MyNominal' in a JSDoc type annotation." + "messageKey": "_0_is_a_type_and_cannot_be_imported_in_JavaScript_files_Use_1_in_a_JSDoc_type_annotation_18042", + "messageArgs": [ + "MyNominal", + "import(\"../sub-project/index\").MyNominal" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2322 + "size": 2350 } //// [/home/src/workspaces/lib/sub-project/index.d.ts] *new* import { Nominal } from '../common/nominal'; @@ -330,7 +334,7 @@ const nominal_1 = require("../common/nominal"); */ //// [/home/src/workspaces/lib/sub-project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[3],"fileNames":["lib.d.ts","../common/nominal.d.ts","../../solution/sub-project/index.js"],"fileInfos":[{"version":"24b4796cd50d1a9aabad1583878c494d-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n readonly species: symbol;\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"de751e2539eb6f12413f7067ad0a0ef5-export type Nominal = T & {\n [Symbol.species]: Name;\n};\ndeclare const _default: {};\nexport = _default;\n",{"version":"00b7836eaf1e026f7764b7be6efcc8f5-import { Nominal } from '../common/nominal';\n\n/**\n * @typedef {Nominal} MyNominal\n */","signature":"225285a996cc5c4120877a377890d79e-import { Nominal } from '../common/nominal';\nexport type MyNominal = Nominal;\n/**\n * @typedef {Nominal} MyNominal\n */ \n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"allowJs":true,"checkJs":true,"composite":true,"declaration":true,"outDir":"..","rootDir":"../../solution","skipLibCheck":true},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":9,"end":16,"code":2305,"category":1,"message":"Module '\"../../lib/common/nominal\"' has no exported member 'Nominal'."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[3],"fileNames":["lib.d.ts","../common/nominal.d.ts","../../solution/sub-project/index.js"],"fileInfos":[{"version":"24b4796cd50d1a9aabad1583878c494d-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n readonly species: symbol;\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"de751e2539eb6f12413f7067ad0a0ef5-export type Nominal = T & {\n [Symbol.species]: Name;\n};\ndeclare const _default: {};\nexport = _default;\n",{"version":"00b7836eaf1e026f7764b7be6efcc8f5-import { Nominal } from '../common/nominal';\n\n/**\n * @typedef {Nominal} MyNominal\n */","signature":"225285a996cc5c4120877a377890d79e-import { Nominal } from '../common/nominal';\nexport type MyNominal = Nominal;\n/**\n * @typedef {Nominal} MyNominal\n */ \n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"allowJs":true,"checkJs":true,"composite":true,"declaration":true,"outDir":"..","rootDir":"../../solution","skipLibCheck":true},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":9,"end":16,"code":2305,"category":1,"messageKey":"Module_0_has_no_exported_member_1_2305","messageArgs":["\"../../lib/common/nominal\"","Nominal"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/home/src/workspaces/lib/sub-project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -406,13 +410,17 @@ const nominal_1 = require("../common/nominal"); "end": 16, "code": 2305, "category": 1, - "message": "Module '\"../../lib/common/nominal\"' has no exported member 'Nominal'." + "messageKey": "Module_0_has_no_exported_member_1_2305", + "messageArgs": [ + "\"../../lib/common/nominal\"", + "Nominal" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 1877 + "size": 1904 } common/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noCheck/dts-errors-with-incremental.js b/testdata/baselines/reference/tsbuild/noCheck/dts-errors-with-incremental.js index 92ec8ba77d..e40d226062 100644 --- a/testdata/baselines/reference/tsbuild/noCheck/dts-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noCheck/dts-errors-with-incremental.js @@ -84,7 +84,7 @@ exports.b = void 0; exports.b = 10; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[1,2,3],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[1,2,3],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -122,11 +122,11 @@ exports.b = 10; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -159,21 +159,27 @@ exports.b = 10; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1810 + "size": 1878 } tsconfig.json:: @@ -487,7 +493,7 @@ const a = class { exports.a = a; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -525,11 +531,11 @@ exports.a = a; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -560,21 +566,27 @@ exports.a = a; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1806 + "size": 1874 } tsconfig.json:: @@ -640,7 +652,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -677,11 +689,11 @@ Found 1 error in a.ts:1 { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -709,21 +721,27 @@ Found 1 error in a.ts:1 "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1753 + "size": 1821 } tsconfig.json:: @@ -944,7 +962,7 @@ exports.c = void 0; exports.c = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1026,12 +1044,16 @@ exports.c = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: @@ -1084,7 +1106,7 @@ const a = class { exports.a = a; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1124,11 +1146,11 @@ exports.a = a; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -1168,7 +1190,11 @@ exports.a = a; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -1182,21 +1208,27 @@ exports.a = a; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 2114 + "size": 2209 } tsconfig.json:: @@ -1230,7 +1262,7 @@ exports.a = void 0; exports.a = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1314,12 +1346,16 @@ exports.a = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1611 + "size": 1638 } tsconfig.json:: @@ -1350,7 +1386,7 @@ Output:: Found 1 error in c.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1432,12 +1468,16 @@ Found 1 error in c.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noCheck/semantic-errors-with-incremental.js b/testdata/baselines/reference/tsbuild/noCheck/semantic-errors-with-incremental.js index 3b59a18d15..38b75cfd08 100644 --- a/testdata/baselines/reference/tsbuild/noCheck/semantic-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noCheck/semantic-errors-with-incremental.js @@ -504,7 +504,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"2c3aef4914dc04eedbda88b614f5cc47-export const a: number = \"hello\";","signature":"03ee330dc35a9c186b6cc67781eafb11-export declare const a: number;\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"2c3aef4914dc04eedbda88b614f5cc47-export const a: number = \"hello\";","signature":"03ee330dc35a9c186b6cc67781eafb11-export declare const a: number;\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -573,12 +573,16 @@ Found 1 error in a.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1398 + "size": 1425 } tsconfig.json:: @@ -794,7 +798,7 @@ exports.c = void 0; exports.c = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -876,12 +880,16 @@ exports.c = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: @@ -910,7 +918,7 @@ export declare const a: number; //// [/home/src/workspaces/project/a.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"2c3aef4914dc04eedbda88b614f5cc47-export const a: number = \"hello\";","signature":"03ee330dc35a9c186b6cc67781eafb11-export declare const a: number;\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"2c3aef4914dc04eedbda88b614f5cc47-export const a: number = \"hello\";","signature":"03ee330dc35a9c186b6cc67781eafb11-export declare const a: number;\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -994,12 +1002,16 @@ export declare const a: number; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1615 + "size": 1642 } tsconfig.json:: @@ -1028,7 +1040,7 @@ export declare const a = "hello"; //// [/home/src/workspaces/project/a.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1112,12 +1124,16 @@ export declare const a = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1611 + "size": 1638 } tsconfig.json:: @@ -1148,7 +1164,7 @@ Output:: Found 1 error in c.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1230,12 +1246,16 @@ Found 1 error in c.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noCheck/syntax-errors-with-incremental.js b/testdata/baselines/reference/tsbuild/noCheck/syntax-errors-with-incremental.js index de8cd5cf35..f3379da2d6 100644 --- a/testdata/baselines/reference/tsbuild/noCheck/syntax-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noCheck/syntax-errors-with-incremental.js @@ -841,7 +841,7 @@ exports.c = void 0; exports.c = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -923,12 +923,16 @@ exports.c = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: @@ -968,7 +972,7 @@ exports.a = void 0; exports.a = "hello; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","errors":true,"checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"1fca32c5d452470ed9d0aa38bbe62e60-export const a = \"hello","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","errors":true,"checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"1fca32c5d452470ed9d0aa38bbe62e60-export const a = \"hello","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1053,12 +1057,16 @@ exports.a = "hello; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1622 + "size": 1649 } tsconfig.json:: @@ -1090,7 +1098,7 @@ exports.a = void 0; exports.a = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1174,12 +1182,16 @@ exports.a = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1611 + "size": 1638 } tsconfig.json:: @@ -1210,7 +1222,7 @@ Output:: Found 1 error in c.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1292,12 +1304,16 @@ Found 1 error in c.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/changes-composite.js b/testdata/baselines/reference/tsbuild/noEmit/changes-composite.js index 5972225167..0873954d60 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/changes-composite.js +++ b/testdata/baselines/reference/tsbuild/noEmit/changes-composite.js @@ -349,7 +349,7 @@ Errors Files 1 src/indirectUse.ts:2 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;",{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"affectedFilesPendingEmit":[2,[4],3,[5]],"latestChangedDtsFile":"./src/noChangeFileWithEmitSpecificError.d.ts","emitSignatures":[[2,"8743eb01f3ddad300611aa9bbf6b6c0a-export declare class classC {\n prop: number;\n}\n"],[4,"abe7d9981d6018efb6b2b794f40a1607-export {};\n"],[5,"abe7d9981d6018efb6b2b794f40a1607-export {};\n"]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;",{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"affectedFilesPendingEmit":[2,[4],3,[5]],"latestChangedDtsFile":"./src/noChangeFileWithEmitSpecificError.d.ts","emitSignatures":[[2,"8743eb01f3ddad300611aa9bbf6b6c0a-export declare class classC {\n prop: number;\n}\n"],[4,"abe7d9981d6018efb6b2b794f40a1607-export {};\n"],[5,"abe7d9981d6018efb6b2b794f40a1607-export {};\n"]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -481,7 +481,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -489,7 +494,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -503,7 +511,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -511,7 +524,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -571,7 +587,7 @@ Errors Files ] } ], - "size": 3190 + "size": 3298 } tsconfig.json:: @@ -865,7 +881,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"latestChangedDtsFile":"./src/class.d.ts"} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"latestChangedDtsFile":"./src/class.d.ts"} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1007,7 +1023,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -1015,7 +1036,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -1029,7 +1053,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -1037,7 +1066,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -1045,7 +1077,7 @@ exports.classC = classC; ] ], "latestChangedDtsFile": "./src/class.d.ts", - "size": 3093 + "size": 3201 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/changes-incremental-declaration.js b/testdata/baselines/reference/tsbuild/noEmit/changes-incremental-declaration.js index 868e102cab..7389de4736 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/changes-incremental-declaration.js +++ b/testdata/baselines/reference/tsbuild/noEmit/changes-incremental-declaration.js @@ -348,7 +348,7 @@ Errors Files 1 src/indirectUse.ts:2 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;",{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"affectedFilesPendingEmit":[2,[4],3,[5]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;",{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"affectedFilesPendingEmit":[2,[4],3,[5]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -480,7 +480,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -488,7 +493,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -502,7 +510,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -510,7 +523,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -543,7 +559,7 @@ Errors Files ] ] ], - "size": 2906 + "size": 3014 } tsconfig.json:: @@ -843,7 +859,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/src/indirectUse.d.ts] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -985,7 +1001,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -993,7 +1014,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -1007,7 +1031,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -1015,14 +1044,17 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } ] ] ], - "size": 3053 + "size": 3161 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/changes-incremental.js b/testdata/baselines/reference/tsbuild/noEmit/changes-incremental.js index e36127a4d1..3ac81a8f94 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/changes-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmit/changes-incremental.js @@ -290,7 +290,7 @@ Errors Files 1 src/indirectUse.ts:2 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"affectedFilesPendingEmit":[2,4,3,5]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"affectedFilesPendingEmit":[2,4,3,5]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -423,7 +423,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -431,7 +436,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -445,7 +453,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -453,7 +466,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -482,7 +498,7 @@ Errors Files 5 ] ], - "size": 2807 + "size": 2915 } tsconfig.json:: @@ -753,7 +769,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -876,7 +892,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -884,7 +905,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -898,7 +922,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -906,14 +935,17 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } ] ] ], - "size": 2582 + "size": 2690 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-composite.js b/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-composite.js index 62a76b588e..43d33d4605 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-composite.js +++ b/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-composite.js @@ -542,7 +542,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"latestChangedDtsFile":"./src/class.d.ts"} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"latestChangedDtsFile":"./src/class.d.ts"} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -684,7 +684,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -692,7 +697,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -706,7 +714,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -714,7 +727,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -722,7 +738,7 @@ exports.classC = classC; ] ], "latestChangedDtsFile": "./src/class.d.ts", - "size": 3093 + "size": 3201 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental-declaration.js b/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental-declaration.js index d3688f6b7e..4f4866eadc 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental-declaration.js +++ b/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental-declaration.js @@ -518,7 +518,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/src/indirectUse.d.ts] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -660,7 +660,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -668,7 +673,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -682,7 +690,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -690,14 +703,17 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } ] ] ], - "size": 3053 + "size": 3161 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental.js b/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental.js index 66ce7033ab..c27e81298b 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental.js @@ -433,7 +433,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/src/indirectUse.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -566,7 +566,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -574,7 +579,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -588,7 +596,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -596,14 +609,17 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } ] ] ], - "size": 2770 + "size": 2878 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-incremental-as-modules.js b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-incremental-as-modules.js index 2604cb333a..2e1ada17c1 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-incremental-as-modules.js @@ -154,7 +154,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -213,14 +213,20 @@ Found 1 error in a.ts:1 "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -245,7 +251,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1368 + "size": 1420 } tsconfig.json:: @@ -278,7 +284,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,49],[3,49]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,49],[3,49]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -338,14 +344,20 @@ Found 1 error in a.ts:1 "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -370,7 +382,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1390 + "size": 1442 } tsconfig.json:: @@ -441,7 +453,7 @@ exports.b = void 0; exports.b = 10; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -478,11 +490,11 @@ exports.b = 10; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -510,21 +522,27 @@ exports.b = 10; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1753 + "size": 1821 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-incremental.js b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-incremental.js index 78b36fcdf6..e1d529603a 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-incremental.js @@ -141,7 +141,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -195,14 +195,20 @@ Found 1 error in a.ts:1 "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -219,7 +225,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1341 + "size": 1393 } tsconfig.json:: @@ -252,7 +258,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,49]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,49]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -307,14 +313,20 @@ Found 1 error in a.ts:1 "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -331,7 +343,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1363 + "size": 1415 } tsconfig.json:: @@ -389,7 +401,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -421,12 +433,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -444,21 +456,27 @@ const a = class { "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1578 + "size": 1646 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-multiple-files.js b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-multiple-files.js index dbbed51592..e053d214fc 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-multiple-files.js +++ b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-declaration-enable-changes-with-multiple-files.js @@ -209,7 +209,7 @@ Errors Files 1 d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17],[4,17],[5,17]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17],[4,17],[5,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -284,14 +284,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -305,14 +311,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -326,14 +338,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -374,7 +392,7 @@ Errors Files ] ] ], - "size": 2084 + "size": 2240 } tsconfig.json:: @@ -430,7 +448,7 @@ Errors Files 1 d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };"],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,49],[3,49],[4,49],[5,49]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };"],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,49],[3,49],[4,49],[5,49]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -506,14 +524,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -527,14 +551,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -548,14 +578,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -596,7 +632,7 @@ Errors Files ] ] ], - "size": 2106 + "size": 2262 } tsconfig.json:: @@ -722,7 +758,7 @@ const d = class { exports.d = d; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -763,11 +799,11 @@ exports.d = d; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -785,22 +821,22 @@ exports.d = d; { "fileName": "./c.ts", "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": 1 } }, { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -817,14 +853,20 @@ exports.d = d; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -838,14 +880,20 @@ exports.d = d; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -859,21 +907,27 @@ exports.d = d; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } ] ] ], - "size": 3087 + "size": 3291 } tsconfig.json:: @@ -900,7 +954,7 @@ Output:: [HH:MM:SS AM] Building project 'tsconfig.json'... //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -963,22 +1017,22 @@ Output:: { "fileName": "./c.ts", "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": 1 } }, { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -992,14 +1046,20 @@ Output:: "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -1013,14 +1073,20 @@ Output:: "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -1034,7 +1100,7 @@ Output:: 2 ] ], - "size": 2663 + "size": 2799 } tsconfig.json:: @@ -1082,7 +1148,7 @@ Errors Files 1 d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,16],[4,16],[5,16]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,16],[4,16],[5,16]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1145,22 +1211,22 @@ Errors Files { "fileName": "./c.ts", "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": 1 } }, { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -1177,14 +1243,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -1198,14 +1270,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -1246,7 +1324,7 @@ Errors Files ] ] ], - "size": 2720 + "size": 2856 } tsconfig.json:: @@ -1292,7 +1370,7 @@ Errors Files 1 d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,49],[3,48],[4,48],[5,48]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,49],[3,48],[4,48],[5,48]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1355,22 +1433,22 @@ Errors Files { "fileName": "./c.ts", "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": 1 } }, { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -1388,14 +1466,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -1409,14 +1493,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -1457,7 +1547,7 @@ Errors Files ] ] ], - "size": 2742 + "size": 2878 } tsconfig.json:: @@ -1492,7 +1582,7 @@ Output:: Found 1 error in d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"dc7165893e9c62cfeea6f0fad1d8b57c-export const c = class { public p = 10; };","signature":"17c24c6640bff8629aa96eed43575ace-export declare const c: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,49],[3,48],[4,49],[5,48]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"dc7165893e9c62cfeea6f0fad1d8b57c-export const c = class { public p = 10; };","signature":"17c24c6640bff8629aa96eed43575ace-export declare const c: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,49],[3,48],[4,49],[5,48]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1566,11 +1656,11 @@ Found 1 error in d.ts:1 { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -1588,14 +1678,20 @@ Found 1 error in d.ts:1 "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -1636,7 +1732,7 @@ Found 1 error in d.ts:1 ] ] ], - "size": 2318 + "size": 2386 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-incremental-as-modules.js b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-incremental-as-modules.js index 917f58c5d5..178551a900 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-incremental-as-modules.js @@ -36,7 +36,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -95,14 +95,20 @@ Found 1 error in a.ts:1 "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -127,7 +133,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1368 + "size": 1420 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -442,7 +448,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -479,12 +485,12 @@ Found 1 error in a.ts:1 { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -513,14 +519,20 @@ Found 1 error in a.ts:1 "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -537,7 +549,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1795 + "size": 1863 } tsconfig.json:: @@ -585,7 +597,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -622,12 +634,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -656,21 +668,27 @@ const a = class { "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1759 + "size": 1827 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-incremental.js b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-incremental.js index 660a979a45..184e945981 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-with-incremental.js @@ -34,7 +34,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -88,14 +88,20 @@ Found 1 error in a.ts:1 "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -112,7 +118,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1341 + "size": 1393 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -383,7 +389,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -415,12 +421,12 @@ Found 1 error in a.ts:1 { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -438,14 +444,20 @@ Found 1 error in a.ts:1 "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -462,7 +474,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1614 + "size": 1682 } tsconfig.json:: @@ -510,7 +522,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -542,12 +554,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -565,21 +577,27 @@ const a = class { "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1578 + "size": 1646 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js index 89554d564a..363e51a460 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js @@ -354,7 +354,7 @@ Output:: [HH:MM:SS AM] Building project 'tsconfig.json'... //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -391,12 +391,12 @@ Output:: { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -418,7 +418,7 @@ Output:: 2 ] ], - "size": 1393 + "size": 1409 } tsconfig.json:: @@ -447,7 +447,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false}} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false}} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -484,12 +484,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -504,7 +504,7 @@ const a = class { "options": { "declaration": false }, - "size": 1362 + "size": 1378 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-without-dts-enabled-with-incremental.js b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-without-dts-enabled-with-incremental.js index 4875813312..79155946d7 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/dts-errors-without-dts-enabled-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmit/dts-errors-without-dts-enabled-with-incremental.js @@ -310,7 +310,7 @@ Output:: [HH:MM:SS AM] Building project 'tsconfig.json'... //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -342,12 +342,12 @@ Output:: { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -363,7 +363,7 @@ Output:: 2 ] ], - "size": 1324 + "size": 1340 } tsconfig.json:: @@ -392,7 +392,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false}} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false}} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -424,12 +424,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -438,7 +438,7 @@ const a = class { "options": { "declaration": false }, - "size": 1293 + "size": 1309 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/semantic-errors-with-incremental-as-modules.js b/testdata/baselines/reference/tsbuild/noEmit/semantic-errors-with-incremental-as-modules.js index c23186cbd1..f9b0c57057 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/semantic-errors-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsbuild/noEmit/semantic-errors-with-incremental-as-modules.js @@ -32,7 +32,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"a49e791c9509caf97ef39f9e765d5015-export const a: number = \"hello\"","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2,3]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"a49e791c9509caf97ef39f9e765d5015-export const a: number = \"hello\"","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2,3]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -91,7 +91,11 @@ Found 1 error in a.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -108,7 +112,7 @@ Found 1 error in a.ts:1 3 ] ], - "size": 1204 + "size": 1231 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -397,7 +401,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -463,7 +467,11 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -475,7 +483,7 @@ Found 1 error in a.ts:1 2 ] ], - "size": 1327 + "size": 1354 } tsconfig.json:: @@ -510,7 +518,7 @@ Found 1 error in a.ts:1 const a = "hello"; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -576,12 +584,16 @@ const a = "hello"; "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1296 + "size": 1323 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmit/semantic-errors-with-incremental.js b/testdata/baselines/reference/tsbuild/noEmit/semantic-errors-with-incremental.js index c1fa7999c7..18c846b72b 100644 --- a/testdata/baselines/reference/tsbuild/noEmit/semantic-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmit/semantic-errors-with-incremental.js @@ -30,7 +30,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -84,7 +84,11 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -96,7 +100,7 @@ Found 1 error in a.ts:1 2 ] ], - "size": 1184 + "size": 1211 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -353,7 +357,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -408,7 +412,11 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -420,7 +428,7 @@ Found 1 error in a.ts:1 2 ] ], - "size": 1258 + "size": 1285 } tsconfig.json:: @@ -453,7 +461,7 @@ Found 1 error in a.ts:1 //// [/home/src/projects/project/a.js] *rewrite with same content* //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -508,12 +516,16 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1227 + "size": 1254 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmitOnError/dts-errors-with-declaration-with-incremental.js b/testdata/baselines/reference/tsbuild/noEmitOnError/dts-errors-with-declaration-with-incremental.js index 8cd1b339a5..7eb185e88d 100644 --- a/testdata/baselines/reference/tsbuild/noEmitOnError/dts-errors-with-declaration-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmitOnError/dts-errors-with-declaration-with-incremental.js @@ -67,7 +67,7 @@ interface Symbol { } declare const console: { log(msg: any): void; }; //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":53,"end":54,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":53,"end":54,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17],[4,17]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":53,"end":54,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":53,"end":54,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17],[4,17]]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -146,14 +146,20 @@ declare const console: { log(msg: any): void; }; "end": 54, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 53, "end": 54, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -186,7 +192,7 @@ declare const console: { log(msg: any): void; }; ] ] ], - "size": 1628 + "size": 1680 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmitOnError/semantic-errors-with-declaration-with-incremental.js b/testdata/baselines/reference/tsbuild/noEmitOnError/semantic-errors-with-declaration-with-incremental.js index d8fdb8837c..ce4e2c8bc5 100644 --- a/testdata/baselines/reference/tsbuild/noEmitOnError/semantic-errors-with-declaration-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmitOnError/semantic-errors-with-declaration-with-incremental.js @@ -63,7 +63,7 @@ interface Symbol { } declare const console: { log(msg: any): void; }; //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"affectedFilesPendingEmit":[2,3,4]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"affectedFilesPendingEmit":[2,3,4]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -142,7 +142,11 @@ declare const console: { log(msg: any): void; }; "end": 47, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] @@ -164,7 +168,7 @@ declare const console: { log(msg: any): void; }; 4 ] ], - "size": 1445 + "size": 1472 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/noEmitOnError/semantic-errors-with-incremental.js b/testdata/baselines/reference/tsbuild/noEmitOnError/semantic-errors-with-incremental.js index ffd63e121b..bb065a46c3 100644 --- a/testdata/baselines/reference/tsbuild/noEmitOnError/semantic-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuild/noEmitOnError/semantic-errors-with-incremental.js @@ -63,7 +63,7 @@ interface Symbol { } declare const console: { log(msg: any): void; }; //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":false,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"affectedFilesPendingEmit":[2,3,4]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":false,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"affectedFilesPendingEmit":[2,3,4]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -142,7 +142,11 @@ declare const console: { log(msg: any): void; }; "end": 47, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] @@ -164,7 +168,7 @@ declare const console: { log(msg: any): void; }; 4 ] ], - "size": 1446 + "size": 1473 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/sample/builds-downstream-projects-even-if-upstream-projects-have-errors.js b/testdata/baselines/reference/tsbuild/sample/builds-downstream-projects-even-if-upstream-projects-have-errors.js index 0e42fc149c..1cc04c9487 100644 --- a/testdata/baselines/reference/tsbuild/sample/builds-downstream-projects-even-if-upstream-projects-have-errors.js +++ b/testdata/baselines/reference/tsbuild/sample/builds-downstream-projects-even-if-upstream-projects-have-errors.js @@ -273,7 +273,7 @@ exports.m = mod; //// [/user/username/projects/sample1/logic/index.js.map] *new* {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAY,CAAC,0CAAsB;AACnC,2BAAkC;IAC9B,OAAO,CAAC,CAAC,OAAO,EAAE,CAAC;AAAA,CACtB;AACD,MAAY,GAAG,kDAA8B;AAChC,QAAA,CAAC,GAAG,GAAG,CAAC"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../core/anotherModule.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"fc70810d80f598d415c6f21c113a400b-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n//# sourceMappingURL=index.d.ts.map","5ef600f6f6585506cfe942fc161e76c5-export declare const World = \"hello\";\n//# sourceMappingURL=anotherModule.d.ts.map",{"version":"4da0a6ee7d4a662685afc8fe143c994d-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.muitply();\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"07587a8dc02fb971c487c21dd8f4849b-export declare function getSecondsInDay(): any;\nimport * as mod from '../core/anotherModule';\nexport declare const m: typeof mod;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":85,"end":92,"code":2339,"category":1,"message":"Property 'muitply' does not exist on type 'typeof import(\"/user/username/projects/sample1/core/index\")'."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../core/anotherModule.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"fc70810d80f598d415c6f21c113a400b-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n//# sourceMappingURL=index.d.ts.map","5ef600f6f6585506cfe942fc161e76c5-export declare const World = \"hello\";\n//# sourceMappingURL=anotherModule.d.ts.map",{"version":"4da0a6ee7d4a662685afc8fe143c994d-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.muitply();\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"07587a8dc02fb971c487c21dd8f4849b-export declare function getSecondsInDay(): any;\nimport * as mod from '../core/anotherModule';\nexport declare const m: typeof mod;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":85,"end":92,"code":2339,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_2339","messageArgs":["muitply","typeof import(\"/user/username/projects/sample1/core/index\")"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -355,13 +355,17 @@ exports.m = mod; "end": 92, "code": 2339, "category": 1, - "message": "Property 'muitply' does not exist on type 'typeof import(\"/user/username/projects/sample1/core/index\")'." + "messageKey": "Property_0_does_not_exist_on_type_1_2339", + "messageArgs": [ + "muitply", + "typeof import(\"/user/username/projects/sample1/core/index\")" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2070 + "size": 2097 } //// [/user/username/projects/sample1/tests/index.d.ts] *new* import * as mod from '../core/anotherModule'; diff --git a/testdata/baselines/reference/tsbuild/sample/reports-error-if-input-file-is-missing-with-force.js b/testdata/baselines/reference/tsbuild/sample/reports-error-if-input-file-is-missing-with-force.js index 69a3eed6d1..e706bf4b38 100644 --- a/testdata/baselines/reference/tsbuild/sample/reports-error-if-input-file-is-missing-with-force.js +++ b/testdata/baselines/reference/tsbuild/sample/reports-error-if-input-file-is-missing-with-force.js @@ -246,7 +246,7 @@ exports.m = mod; //// [/user/username/projects/sample1/logic/index.js.map] *new* {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAY,CAAC,0CAAsB;AACnC,2BAAkC;IAC9B,OAAO,CAAC,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;AAAA,CAC7B;AACD,MAAY,GAAG,kDAA8B;AAChC,QAAA,CAAC,GAAG,GAAG,CAAC"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[3],"fileNames":["lib.d.ts","../core/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n",{"version":"590556060bc156a64834010df8cda255-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"40bb9a18ac3dbfd340fea197221fa9dd-export declare function getSecondsInDay(): number;\nexport declare const m: any;\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":126,"end":149,"code":2307,"category":1,"message":"Cannot find module '../core/anotherModule' or its corresponding type declarations."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[3],"fileNames":["lib.d.ts","../core/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n",{"version":"590556060bc156a64834010df8cda255-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"40bb9a18ac3dbfd340fea197221fa9dd-export declare function getSecondsInDay(): number;\nexport declare const m: any;\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":126,"end":149,"code":2307,"category":1,"messageKey":"Cannot_find_module_0_or_its_corresponding_type_declarations_2307","messageArgs":["../core/anotherModule"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -319,13 +319,16 @@ exports.m = mod; "end": 149, "code": 2307, "category": 1, - "message": "Cannot find module '../core/anotherModule' or its corresponding type declarations." + "messageKey": "Cannot_find_module_0_or_its_corresponding_type_declarations_2307", + "messageArgs": [ + "../core/anotherModule" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 1818 + "size": 1843 } //// [/user/username/projects/sample1/tests/index.d.ts] *new* export declare const m: any; @@ -375,7 +378,7 @@ const mod = __importStar(require("../core/anotherModule")); exports.m = mod; //// [/user/username/projects/sample1/tests/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../logic/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","40bb9a18ac3dbfd340fea197221fa9dd-export declare function getSecondsInDay(): number;\nexport declare const m: any;\n",{"version":"7fa4162f733e6b9e7f7d9d9410e62f61-import * as c from '../core/index';\nimport * as logic from '../logic/index';\n\nc.leftPad(\"\", 10);\nlogic.getSecondsInDay();\n\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"ce0233db1f3aabecabdb072a4f4c8d1e-export declare const m: any;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":144,"end":167,"code":2307,"category":1,"message":"Cannot find module '../core/anotherModule' or its corresponding type declarations."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../logic/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","40bb9a18ac3dbfd340fea197221fa9dd-export declare function getSecondsInDay(): number;\nexport declare const m: any;\n",{"version":"7fa4162f733e6b9e7f7d9d9410e62f61-import * as c from '../core/index';\nimport * as logic from '../logic/index';\n\nc.leftPad(\"\", 10);\nlogic.getSecondsInDay();\n\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"ce0233db1f3aabecabdb072a4f4c8d1e-export declare const m: any;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":144,"end":167,"code":2307,"category":1,"messageKey":"Cannot_find_module_0_or_its_corresponding_type_declarations_2307","messageArgs":["../core/anotherModule"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/tests/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -456,13 +459,16 @@ exports.m = mod; "end": 167, "code": 2307, "category": 1, - "message": "Cannot find module '../core/anotherModule' or its corresponding type declarations." + "messageKey": "Cannot_find_module_0_or_its_corresponding_type_declarations_2307", + "messageArgs": [ + "../core/anotherModule" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 1913 + "size": 1938 } core/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/sample/reports-error-if-input-file-is-missing.js b/testdata/baselines/reference/tsbuild/sample/reports-error-if-input-file-is-missing.js index d546837a27..6ebfb68cc3 100644 --- a/testdata/baselines/reference/tsbuild/sample/reports-error-if-input-file-is-missing.js +++ b/testdata/baselines/reference/tsbuild/sample/reports-error-if-input-file-is-missing.js @@ -246,7 +246,7 @@ exports.m = mod; //// [/user/username/projects/sample1/logic/index.js.map] *new* {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAY,CAAC,0CAAsB;AACnC,2BAAkC;IAC9B,OAAO,CAAC,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;AAAA,CAC7B;AACD,MAAY,GAAG,kDAA8B;AAChC,QAAA,CAAC,GAAG,GAAG,CAAC"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[3],"fileNames":["lib.d.ts","../core/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n",{"version":"590556060bc156a64834010df8cda255-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"40bb9a18ac3dbfd340fea197221fa9dd-export declare function getSecondsInDay(): number;\nexport declare const m: any;\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":126,"end":149,"code":2307,"category":1,"message":"Cannot find module '../core/anotherModule' or its corresponding type declarations."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[3],"fileNames":["lib.d.ts","../core/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n",{"version":"590556060bc156a64834010df8cda255-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"40bb9a18ac3dbfd340fea197221fa9dd-export declare function getSecondsInDay(): number;\nexport declare const m: any;\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":126,"end":149,"code":2307,"category":1,"messageKey":"Cannot_find_module_0_or_its_corresponding_type_declarations_2307","messageArgs":["../core/anotherModule"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -319,13 +319,16 @@ exports.m = mod; "end": 149, "code": 2307, "category": 1, - "message": "Cannot find module '../core/anotherModule' or its corresponding type declarations." + "messageKey": "Cannot_find_module_0_or_its_corresponding_type_declarations_2307", + "messageArgs": [ + "../core/anotherModule" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 1818 + "size": 1843 } //// [/user/username/projects/sample1/tests/index.d.ts] *new* export declare const m: any; @@ -375,7 +378,7 @@ const mod = __importStar(require("../core/anotherModule")); exports.m = mod; //// [/user/username/projects/sample1/tests/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../logic/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","40bb9a18ac3dbfd340fea197221fa9dd-export declare function getSecondsInDay(): number;\nexport declare const m: any;\n",{"version":"7fa4162f733e6b9e7f7d9d9410e62f61-import * as c from '../core/index';\nimport * as logic from '../logic/index';\n\nc.leftPad(\"\", 10);\nlogic.getSecondsInDay();\n\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"ce0233db1f3aabecabdb072a4f4c8d1e-export declare const m: any;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":144,"end":167,"code":2307,"category":1,"message":"Cannot find module '../core/anotherModule' or its corresponding type declarations."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../logic/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","40bb9a18ac3dbfd340fea197221fa9dd-export declare function getSecondsInDay(): number;\nexport declare const m: any;\n",{"version":"7fa4162f733e6b9e7f7d9d9410e62f61-import * as c from '../core/index';\nimport * as logic from '../logic/index';\n\nc.leftPad(\"\", 10);\nlogic.getSecondsInDay();\n\nimport * as mod from '../core/anotherModule';\nexport const m = mod;","signature":"ce0233db1f3aabecabdb072a4f4c8d1e-export declare const m: any;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":144,"end":167,"code":2307,"category":1,"messageKey":"Cannot_find_module_0_or_its_corresponding_type_declarations_2307","messageArgs":["../core/anotherModule"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/tests/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -456,13 +459,16 @@ exports.m = mod; "end": 167, "code": 2307, "category": 1, - "message": "Cannot find module '../core/anotherModule' or its corresponding type declarations." + "messageKey": "Cannot_find_module_0_or_its_corresponding_type_declarations_2307", + "messageArgs": [ + "../core/anotherModule" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 1913 + "size": 1938 } core/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors-when-test-does-not-reference-core.js b/testdata/baselines/reference/tsbuild/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors-when-test-does-not-reference-core.js index 2a9339f273..d116b0e0b3 100644 --- a/testdata/baselines/reference/tsbuild/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors-when-test-does-not-reference-core.js +++ b/testdata/baselines/reference/tsbuild/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors-when-test-does-not-reference-core.js @@ -144,7 +144,7 @@ function multiply(a, b) { return a * b; } multiply(); //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"4bf9c557eaa1c988144310898522b7b5-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }multiply();","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":177,"end":185,"code":2554,"category":1,"message":"Expected 2 arguments, but got 0.","relatedInformation":[{"pos":138,"end":147,"code":6210,"category":3,"message":"An argument for 'a' was not provided."}]}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"4bf9c557eaa1c988144310898522b7b5-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }multiply();","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":177,"end":185,"code":2554,"category":1,"messageKey":"Expected_0_arguments_but_got_1_2554","messageArgs":["2","0"],"relatedInformation":[{"pos":138,"end":147,"code":6210,"category":3,"messageKey":"An_argument_for_0_was_not_provided_6210","messageArgs":["a"]}]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -230,14 +230,21 @@ multiply(); "end": 185, "code": 2554, "category": 1, - "message": "Expected 2 arguments, but got 0.", + "messageKey": "Expected_0_arguments_but_got_1_2554", + "messageArgs": [ + "2", + "0" + ], "relatedInformation": [ { "pos": 138, "end": 147, "code": 6210, "category": 3, - "message": "An argument for 'a' was not provided." + "messageKey": "An_argument_for_0_was_not_provided_6210", + "messageArgs": [ + "a" + ] } ] } @@ -245,7 +252,7 @@ multiply(); ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2078 + "size": 2133 } core/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors.js b/testdata/baselines/reference/tsbuild/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors.js index 065dec9b3d..017400f333 100644 --- a/testdata/baselines/reference/tsbuild/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors.js +++ b/testdata/baselines/reference/tsbuild/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors.js @@ -145,7 +145,7 @@ function multiply(a, b) { return a * b; } multiply(); //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"4bf9c557eaa1c988144310898522b7b5-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }multiply();","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":177,"end":185,"code":2554,"category":1,"message":"Expected 2 arguments, but got 0.","relatedInformation":[{"pos":138,"end":147,"code":6210,"category":3,"message":"An argument for 'a' was not provided."}]}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"4bf9c557eaa1c988144310898522b7b5-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }multiply();","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":177,"end":185,"code":2554,"category":1,"messageKey":"Expected_0_arguments_but_got_1_2554","messageArgs":["2","0"],"relatedInformation":[{"pos":138,"end":147,"code":6210,"category":3,"messageKey":"An_argument_for_0_was_not_provided_6210","messageArgs":["a"]}]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -231,14 +231,21 @@ multiply(); "end": 185, "code": 2554, "category": 1, - "message": "Expected 2 arguments, but got 0.", + "messageKey": "Expected_0_arguments_but_got_1_2554", + "messageArgs": [ + "2", + "0" + ], "relatedInformation": [ { "pos": 138, "end": 147, "code": 6210, "category": 3, - "message": "An argument for 'a' was not provided." + "messageKey": "An_argument_for_0_was_not_provided_6210", + "messageArgs": [ + "a" + ] } ] } @@ -246,7 +253,7 @@ multiply(); ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2078 + "size": 2133 } core/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuild/transitiveReferences/reports-error-about-module-not-found-with-node-resolution-with-external-module-name.js b/testdata/baselines/reference/tsbuild/transitiveReferences/reports-error-about-module-not-found-with-node-resolution-with-external-module-name.js index 7045a5c3e2..f89cd02b37 100644 --- a/testdata/baselines/reference/tsbuild/transitiveReferences/reports-error-about-module-not-found-with-node-resolution-with-external-module-name.js +++ b/testdata/baselines/reference/tsbuild/transitiveReferences/reports-error-about-module-not-found-with-node-resolution-with-external-module-name.js @@ -185,7 +185,7 @@ a_1.X; "size": 1083 } //// [/user/username/projects/transitiveReferences/tsconfig.b.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.esnext.full.d.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"d0c1e70086e2297c6733a209dc8aebd5-import {A} from 'a';\nexport const b = new A();","signature":"5c4caa93805477a2ce78ec8e61b569d7-export declare const b: any;\n","impliedNodeFormat":1}],"options":{"composite":true,"module":199},"semanticDiagnosticsPerFile":[[2,[{"pos":16,"end":19,"code":2307,"category":1,"message":"Cannot find module 'a' or its corresponding type declarations."}]]],"latestChangedDtsFile":"./b.d.ts"} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.esnext.full.d.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"d0c1e70086e2297c6733a209dc8aebd5-import {A} from 'a';\nexport const b = new A();","signature":"5c4caa93805477a2ce78ec8e61b569d7-export declare const b: any;\n","impliedNodeFormat":1}],"options":{"composite":true,"module":199},"semanticDiagnosticsPerFile":[[2,[{"pos":16,"end":19,"code":2307,"category":1,"messageKey":"Cannot_find_module_0_or_its_corresponding_type_declarations_2307","messageArgs":["a"]}]]],"latestChangedDtsFile":"./b.d.ts"} //// [/user/username/projects/transitiveReferences/tsconfig.b.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -239,13 +239,16 @@ a_1.X; "end": 19, "code": 2307, "category": 1, - "message": "Cannot find module 'a' or its corresponding type declarations." + "messageKey": "Cannot_find_module_0_or_its_corresponding_type_declarations_2307", + "messageArgs": [ + "a" + ] } ] ] ], "latestChangedDtsFile": "./b.d.ts", - "size": 1296 + "size": 1321 } //// [/user/username/projects/transitiveReferences/tsconfig.c.tsbuildinfo] *new* {"version":"FakeTSVersion","root":["./c.ts"]} diff --git a/testdata/baselines/reference/tsbuildWatch/demo/updates-with-bad-reference.js b/testdata/baselines/reference/tsbuildWatch/demo/updates-with-bad-reference.js index 3fdefa6ac5..6675258b47 100644 --- a/testdata/baselines/reference/tsbuildWatch/demo/updates-with-bad-reference.js +++ b/testdata/baselines/reference/tsbuildWatch/demo/updates-with-bad-reference.js @@ -397,7 +397,7 @@ Object.defineProperty(exports, "createDog", { enumerable: true, get: function () "size": 2794 } //// [/user/username/projects/demo/lib/core/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","errors":true,"root":[5],"fileNames":["lib.d.ts","../../animals/animal.ts","../../animals/dog.ts","../../animals/index.ts","../../core/utilities.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"47f086fff365b1e8b96a6df2c4313c1a-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}","signature":"1d76529d4652ddf9ebdfa65e748240fb-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}\n","impliedNodeFormat":1},{"version":"39dbb9b755eef022e56879989968e5cf-import Animal from '.';\nimport { makeRandomName } from '../core/utilities';\n\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\n\nexport function createDog(): Dog {\n return ({\n size: \"medium\",\n woof: function(this: Dog) {\n console.log(`${ this.name } says \"Woof\"!`);\n },\n name: makeRandomName()\n });\n}","signature":"4dc4bc559452869bfd0d92b5ed5d604f-import Animal from '.';\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\nexport declare function createDog(): Dog;\n","impliedNodeFormat":1},{"version":"d6a6b65b86b0330b1a1bd96b1738d5a4-import Animal from './animal';\n\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };","signature":"a3e41a5ccafc3d07a201f0603e28edcf-import Animal from './animal';\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };\n","impliedNodeFormat":1},{"version":"c71a99e072793c29cda49dd3fea04661-import * as A from '../animals'\nexport function makeRandomName() {\n return \"Bob!?! \";\n}\n\nexport function lastElementOf(arr: T[]): T | undefined {\n if (arr.length === 0) return undefined;\n return arr[arr.length - 1];\n}","signature":"096c311e7aecdb577f7b613fbf1716e5-export declare function makeRandomName(): string;\nexport declare function lastElementOf(arr: T[]): T | undefined;\n","impliedNodeFormat":1}],"fileIdsList":[[4,5],[2,3],[4]],"options":{"composite":true,"declaration":true,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","rootDir":"../../core","strict":true,"target":1},"referencedMap":[[3,1],[4,2],[5,3]],"semanticDiagnosticsPerFile":[[5,[{"pos":12,"end":13,"code":6133,"category":1,"message":"'A' is declared but its value is never read.","reportsUnnecessary":true}]]],"latestChangedDtsFile":"./utilities.d.ts"} +{"version":"FakeTSVersion","errors":true,"root":[5],"fileNames":["lib.d.ts","../../animals/animal.ts","../../animals/dog.ts","../../animals/index.ts","../../core/utilities.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"47f086fff365b1e8b96a6df2c4313c1a-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}","signature":"1d76529d4652ddf9ebdfa65e748240fb-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}\n","impliedNodeFormat":1},{"version":"39dbb9b755eef022e56879989968e5cf-import Animal from '.';\nimport { makeRandomName } from '../core/utilities';\n\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\n\nexport function createDog(): Dog {\n return ({\n size: \"medium\",\n woof: function(this: Dog) {\n console.log(`${ this.name } says \"Woof\"!`);\n },\n name: makeRandomName()\n });\n}","signature":"4dc4bc559452869bfd0d92b5ed5d604f-import Animal from '.';\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\nexport declare function createDog(): Dog;\n","impliedNodeFormat":1},{"version":"d6a6b65b86b0330b1a1bd96b1738d5a4-import Animal from './animal';\n\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };","signature":"a3e41a5ccafc3d07a201f0603e28edcf-import Animal from './animal';\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };\n","impliedNodeFormat":1},{"version":"c71a99e072793c29cda49dd3fea04661-import * as A from '../animals'\nexport function makeRandomName() {\n return \"Bob!?! \";\n}\n\nexport function lastElementOf(arr: T[]): T | undefined {\n if (arr.length === 0) return undefined;\n return arr[arr.length - 1];\n}","signature":"096c311e7aecdb577f7b613fbf1716e5-export declare function makeRandomName(): string;\nexport declare function lastElementOf(arr: T[]): T | undefined;\n","impliedNodeFormat":1}],"fileIdsList":[[4,5],[2,3],[4]],"options":{"composite":true,"declaration":true,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","rootDir":"../../core","strict":true,"target":1},"referencedMap":[[3,1],[4,2],[5,3]],"semanticDiagnosticsPerFile":[[5,[{"pos":12,"end":13,"code":6133,"category":1,"messageKey":"_0_is_declared_but_its_value_is_never_read_6133","messageArgs":["A"],"reportsUnnecessary":true}]]],"latestChangedDtsFile":"./utilities.d.ts"} //// [/user/username/projects/demo/lib/core/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -523,14 +523,17 @@ Object.defineProperty(exports, "createDog", { enumerable: true, get: function () "end": 13, "code": 6133, "category": 1, - "message": "'A' is declared but its value is never read.", + "messageKey": "_0_is_declared_but_its_value_is_never_read_6133", + "messageArgs": [ + "A" + ], "reportsUnnecessary": true } ] ] ], "latestChangedDtsFile": "./utilities.d.ts", - "size": 3302 + "size": 3328 } //// [/user/username/projects/demo/lib/core/utilities.d.ts] *new* export declare function makeRandomName(): string; @@ -764,7 +767,7 @@ Output:: //// [/user/username/projects/demo/lib/animals/tsconfig.tsbuildinfo] *mTime changed* //// [/user/username/projects/demo/lib/core/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","errors":true,"root":[5],"fileNames":["lib.d.ts","../../animals/animal.ts","../../animals/dog.ts","../../animals/index.ts","../../core/utilities.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"47f086fff365b1e8b96a6df2c4313c1a-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}","signature":"1d76529d4652ddf9ebdfa65e748240fb-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}\n","impliedNodeFormat":1},{"version":"39dbb9b755eef022e56879989968e5cf-import Animal from '.';\nimport { makeRandomName } from '../core/utilities';\n\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\n\nexport function createDog(): Dog {\n return ({\n size: \"medium\",\n woof: function(this: Dog) {\n console.log(`${ this.name } says \"Woof\"!`);\n },\n name: makeRandomName()\n });\n}","signature":"4dc4bc559452869bfd0d92b5ed5d604f-import Animal from '.';\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\nexport declare function createDog(): Dog;\n","impliedNodeFormat":1},{"version":"d6a6b65b86b0330b1a1bd96b1738d5a4-import Animal from './animal';\n\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };","signature":"a3e41a5ccafc3d07a201f0603e28edcf-import Animal from './animal';\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };\n","impliedNodeFormat":1},{"version":"c3e46c15bb789df9e21a5ca1964be7a1-\nimport * as A from '../animals'\nexport function makeRandomName() {\n return \"Bob!?! \";\n}\n\nexport function lastElementOf(arr: T[]): T | undefined {\n if (arr.length === 0) return undefined;\n return arr[arr.length - 1];\n}","signature":"096c311e7aecdb577f7b613fbf1716e5-export declare function makeRandomName(): string;\nexport declare function lastElementOf(arr: T[]): T | undefined;\n","impliedNodeFormat":1}],"fileIdsList":[[4,5],[2,3],[4]],"options":{"composite":true,"declaration":true,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","rootDir":"../../core","strict":true,"target":1},"referencedMap":[[3,1],[4,2],[5,3]],"semanticDiagnosticsPerFile":[[5,[{"pos":13,"end":14,"code":6133,"category":1,"message":"'A' is declared but its value is never read.","reportsUnnecessary":true}]]],"latestChangedDtsFile":"./utilities.d.ts"} +{"version":"FakeTSVersion","errors":true,"root":[5],"fileNames":["lib.d.ts","../../animals/animal.ts","../../animals/dog.ts","../../animals/index.ts","../../core/utilities.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"47f086fff365b1e8b96a6df2c4313c1a-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}","signature":"1d76529d4652ddf9ebdfa65e748240fb-export type Size = \"small\" | \"medium\" | \"large\";\nexport default interface Animal {\n size: Size;\n}\n","impliedNodeFormat":1},{"version":"39dbb9b755eef022e56879989968e5cf-import Animal from '.';\nimport { makeRandomName } from '../core/utilities';\n\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\n\nexport function createDog(): Dog {\n return ({\n size: \"medium\",\n woof: function(this: Dog) {\n console.log(`${ this.name } says \"Woof\"!`);\n },\n name: makeRandomName()\n });\n}","signature":"4dc4bc559452869bfd0d92b5ed5d604f-import Animal from '.';\nexport interface Dog extends Animal {\n woof(): void;\n name: string;\n}\nexport declare function createDog(): Dog;\n","impliedNodeFormat":1},{"version":"d6a6b65b86b0330b1a1bd96b1738d5a4-import Animal from './animal';\n\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };","signature":"a3e41a5ccafc3d07a201f0603e28edcf-import Animal from './animal';\nexport default Animal;\nimport { createDog, Dog } from './dog';\nexport { createDog, Dog };\n","impliedNodeFormat":1},{"version":"c3e46c15bb789df9e21a5ca1964be7a1-\nimport * as A from '../animals'\nexport function makeRandomName() {\n return \"Bob!?! \";\n}\n\nexport function lastElementOf(arr: T[]): T | undefined {\n if (arr.length === 0) return undefined;\n return arr[arr.length - 1];\n}","signature":"096c311e7aecdb577f7b613fbf1716e5-export declare function makeRandomName(): string;\nexport declare function lastElementOf(arr: T[]): T | undefined;\n","impliedNodeFormat":1}],"fileIdsList":[[4,5],[2,3],[4]],"options":{"composite":true,"declaration":true,"module":1,"noFallthroughCasesInSwitch":true,"noImplicitReturns":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","rootDir":"../../core","strict":true,"target":1},"referencedMap":[[3,1],[4,2],[5,3]],"semanticDiagnosticsPerFile":[[5,[{"pos":13,"end":14,"code":6133,"category":1,"messageKey":"_0_is_declared_but_its_value_is_never_read_6133","messageArgs":["A"],"reportsUnnecessary":true}]]],"latestChangedDtsFile":"./utilities.d.ts"} //// [/user/username/projects/demo/lib/core/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -890,14 +893,17 @@ Output:: "end": 14, "code": 6133, "category": 1, - "message": "'A' is declared but its value is never read.", + "messageKey": "_0_is_declared_but_its_value_is_never_read_6133", + "messageArgs": [ + "A" + ], "reportsUnnecessary": true } ] ] ], "latestChangedDtsFile": "./utilities.d.ts", - "size": 3304 + "size": 3330 } //// [/user/username/projects/demo/lib/core/utilities.js] *rewrite with same content* diff --git a/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-with-incremental-as-modules.js b/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-with-incremental-as-modules.js index 2f795e410b..6876112d8f 100644 --- a/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-with-incremental-as-modules.js @@ -37,7 +37,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -96,14 +96,20 @@ Output:: "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -128,7 +134,7 @@ Output:: ] ] ], - "size": 1368 + "size": 1420 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -431,7 +437,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -468,12 +474,12 @@ Output:: { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -502,14 +508,20 @@ Output:: "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -526,7 +538,7 @@ Output:: ] ] ], - "size": 1795 + "size": 1863 } tsconfig.json:: @@ -581,7 +593,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -618,12 +630,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -652,21 +664,27 @@ const a = class { "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1759 + "size": 1827 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-with-incremental.js b/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-with-incremental.js index 516fd9568c..a27cc11a25 100644 --- a/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-with-incremental.js @@ -35,7 +35,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -89,14 +89,20 @@ Output:: "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -113,7 +119,7 @@ Output:: ] ] ], - "size": 1341 + "size": 1393 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -372,7 +378,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -404,12 +410,12 @@ Output:: { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -427,14 +433,20 @@ Output:: "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -451,7 +463,7 @@ Output:: ] ] ], - "size": 1614 + "size": 1682 } tsconfig.json:: @@ -506,7 +518,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -538,12 +550,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -561,21 +573,27 @@ const a = class { "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1578 + "size": 1646 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js b/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js index 89195e93aa..7dba74d3b2 100644 --- a/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js @@ -366,7 +366,7 @@ Output:: [HH:MM:SS AM] Found 0 errors. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -403,12 +403,12 @@ Output:: { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -430,7 +430,7 @@ Output:: 2 ] ], - "size": 1393 + "size": 1409 } tsconfig.json:: @@ -469,7 +469,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false}} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false}} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -506,12 +506,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -526,7 +526,7 @@ const a = class { "options": { "declaration": false }, - "size": 1362 + "size": 1378 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-without-dts-enabled-with-incremental.js b/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-without-dts-enabled-with-incremental.js index 48624d3c0d..328ce0ffad 100644 --- a/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-without-dts-enabled-with-incremental.js +++ b/testdata/baselines/reference/tsbuildWatch/noEmit/dts-errors-without-dts-enabled-with-incremental.js @@ -322,7 +322,7 @@ Output:: [HH:MM:SS AM] Found 0 errors. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -354,12 +354,12 @@ Output:: { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -375,7 +375,7 @@ Output:: 2 ] ], - "size": 1324 + "size": 1340 } tsconfig.json:: @@ -414,7 +414,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false}} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false}} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -446,12 +446,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -460,7 +460,7 @@ const a = class { "options": { "declaration": false }, - "size": 1293 + "size": 1309 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/noEmit/semantic-errors-with-incremental-as-modules.js b/testdata/baselines/reference/tsbuildWatch/noEmit/semantic-errors-with-incremental-as-modules.js index 24ed893968..fd99d49c7f 100644 --- a/testdata/baselines/reference/tsbuildWatch/noEmit/semantic-errors-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsbuildWatch/noEmit/semantic-errors-with-incremental-as-modules.js @@ -33,7 +33,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"a49e791c9509caf97ef39f9e765d5015-export const a: number = \"hello\"","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2,3]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"a49e791c9509caf97ef39f9e765d5015-export const a: number = \"hello\"","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2,3]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -92,7 +92,11 @@ Output:: "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -109,7 +113,7 @@ Output:: 3 ] ], - "size": 1204 + "size": 1231 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -390,7 +394,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -456,7 +460,11 @@ Output:: "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -468,7 +476,7 @@ Output:: 2 ] ], - "size": 1327 + "size": 1354 } tsconfig.json:: @@ -510,7 +518,7 @@ Output:: const a = "hello"; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -576,12 +584,16 @@ const a = "hello"; "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1296 + "size": 1323 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/noEmit/semantic-errors-with-incremental.js b/testdata/baselines/reference/tsbuildWatch/noEmit/semantic-errors-with-incremental.js index 1fbba049e3..acbe0c4e48 100644 --- a/testdata/baselines/reference/tsbuildWatch/noEmit/semantic-errors-with-incremental.js +++ b/testdata/baselines/reference/tsbuildWatch/noEmit/semantic-errors-with-incremental.js @@ -31,7 +31,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -85,7 +85,11 @@ Output:: "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -97,7 +101,7 @@ Output:: 2 ] ], - "size": 1184 + "size": 1211 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -346,7 +350,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -401,7 +405,11 @@ Output:: "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -413,7 +421,7 @@ Output:: 2 ] ], - "size": 1258 + "size": 1285 } tsconfig.json:: @@ -453,7 +461,7 @@ Output:: //// [/home/src/projects/project/a.js] *rewrite with same content* //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -508,12 +516,16 @@ Output:: "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1227 + "size": 1254 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/noEmitOnError/noEmitOnError-with-declaration-with-incremental.js b/testdata/baselines/reference/tsbuildWatch/noEmitOnError/noEmitOnError-with-declaration-with-incremental.js index 11b28b91d7..c5281c07c8 100644 --- a/testdata/baselines/reference/tsbuildWatch/noEmitOnError/noEmitOnError-with-declaration-with-incremental.js +++ b/testdata/baselines/reference/tsbuildWatch/noEmitOnError/noEmitOnError-with-declaration-with-incremental.js @@ -395,7 +395,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","signature":"54943827690173f946e7a76cd9b9eb27-export interface A {\n name: string;\n}\n","impliedNodeFormat":1},{"version":"21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"affectedFilesPendingEmit":[3]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","signature":"54943827690173f946e7a76cd9b9eb27-export interface A {\n name: string;\n}\n","impliedNodeFormat":1},{"version":"21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"affectedFilesPendingEmit":[3]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -489,7 +489,11 @@ Output:: "end": 47, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] @@ -501,7 +505,7 @@ Output:: 3 ] ], - "size": 1755 + "size": 1782 } tsconfig.json:: @@ -706,7 +710,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","signature":"54943827690173f946e7a76cd9b9eb27-export interface A {\n name: string;\n}\n","impliedNodeFormat":1},{"version":"6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };","signature":"86ced526ce468674cf13e9bae78ff450-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(53,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":53,"end":54,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":53,"end":54,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[3,17]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","signature":"54943827690173f946e7a76cd9b9eb27-export interface A {\n name: string;\n}\n","impliedNodeFormat":1},{"version":"6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };","signature":"562dfe29cab6c7ded7ded341fc9c8131-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(53,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":53,"end":54,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":53,"end":54,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[3,17]]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -756,11 +760,11 @@ Output:: { "fileName": "../src/main.ts", "version": "6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };", - "signature": "86ced526ce468674cf13e9bae78ff450-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(53,1): error9027: Add a type annotation to the variable a.", + "signature": "562dfe29cab6c7ded7ded341fc9c8131-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(53,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };", - "signature": "86ced526ce468674cf13e9bae78ff450-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(53,1): error9027: Add a type annotation to the variable a.", + "signature": "562dfe29cab6c7ded7ded341fc9c8131-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(53,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -800,14 +804,20 @@ Output:: "end": 54, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 53, "end": 54, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -824,7 +834,7 @@ Output:: ] ] ], - "size": 2150 + "size": 2218 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/noEmitOnError/noEmitOnError-with-incremental.js b/testdata/baselines/reference/tsbuildWatch/noEmitOnError/noEmitOnError-with-incremental.js index 2e165e22e4..a038e5310d 100644 --- a/testdata/baselines/reference/tsbuildWatch/noEmitOnError/noEmitOnError-with-incremental.js +++ b/testdata/baselines/reference/tsbuildWatch/noEmitOnError/noEmitOnError-with-incremental.js @@ -372,7 +372,7 @@ Output:: [HH:MM:SS AM] Found 1 error. Watching for file changes. //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}",{"version":"21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":false,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"affectedFilesPendingEmit":[3]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}",{"version":"21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":false,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"affectedFilesPendingEmit":[3]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -456,7 +456,11 @@ Output:: "end": 47, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] @@ -468,7 +472,7 @@ Output:: 3 ] ], - "size": 1536 + "size": 1563 } tsconfig.json:: @@ -662,7 +666,7 @@ const a = class { exports.a = a; //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}",{"version":"6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };","signature":"86ced526ce468674cf13e9bae78ff450-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(53,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},"ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":false,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}",{"version":"6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };","signature":"562dfe29cab6c7ded7ded341fc9c8131-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(53,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},"ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":false,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -707,11 +711,11 @@ exports.a = a; { "fileName": "../src/main.ts", "version": "6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };", - "signature": "86ced526ce468674cf13e9bae78ff450-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(53,1): error9027: Add a type annotation to the variable a.", + "signature": "562dfe29cab6c7ded7ded341fc9c8131-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(53,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };", - "signature": "86ced526ce468674cf13e9bae78ff450-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(53,1): error9027: Add a type annotation to the variable a.", + "signature": "562dfe29cab6c7ded7ded341fc9c8131-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(53,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(53,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -737,7 +741,7 @@ exports.a = a; "../shared/types/db.ts" ] }, - "size": 1605 + "size": 1621 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-introduceError-when-file-with-no-error-changes.js b/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-introduceError-when-file-with-no-error-changes.js index b4ce0716d8..66b738a197 100644 --- a/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-introduceError-when-file-with-no-error-changes.js +++ b/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-introduceError-when-file-with-no-error-changes.js @@ -189,7 +189,7 @@ var myClassWithError = class { exports.myClassWithError = myClassWithError; //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.","impliedNodeFormat":1},{"version":"181818468a51a2348d25d30b10b6b1bb-export class myClass { }","signature":"00d3ac9a4cccbf94649ca3c19d44376a-export declare class myClass {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"message":"Add a type annotation to the variable myClassWithError."}]}]]],"latestChangedDtsFile":"./fileWithError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n","impliedNodeFormat":1},{"version":"181818468a51a2348d25d30b10b6b1bb-export class myClass { }","signature":"00d3ac9a4cccbf94649ca3c19d44376a-export declare class myClass {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["myClassWithError"]}]}]]],"latestChangedDtsFile":"./fileWithError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -226,11 +226,11 @@ exports.myClassWithError = myClassWithError; { "fileName": "./fileWithError.ts", "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": "CommonJS", "original": { "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": 1 } }, @@ -258,14 +258,20 @@ exports.myClassWithError = myClassWithError; "end": 27, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 11, "end": 27, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable myClassWithError." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "myClassWithError" + ] } ] } @@ -283,7 +289,7 @@ exports.myClassWithError = myClassWithError; ] } ], - "size": 2104 + "size": 2172 } app/tsconfig.json:: @@ -325,7 +331,7 @@ class myClass2 { exports.myClass2 = myClass2; //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.","impliedNodeFormat":1},{"version":"4494620e0f3a6379be16c2477b86b919-export class myClass2 { }","signature":"cdd06be46566b8da2e1a2b5b161ff551-export declare class myClass2 {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"message":"Add a type annotation to the variable myClassWithError."}]}]]],"latestChangedDtsFile":"./fileWithoutError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n","impliedNodeFormat":1},{"version":"4494620e0f3a6379be16c2477b86b919-export class myClass2 { }","signature":"cdd06be46566b8da2e1a2b5b161ff551-export declare class myClass2 {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["myClassWithError"]}]}]]],"latestChangedDtsFile":"./fileWithoutError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -362,11 +368,11 @@ exports.myClass2 = myClass2; { "fileName": "./fileWithError.ts", "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": "CommonJS", "original": { "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": 1 } }, @@ -394,14 +400,20 @@ exports.myClass2 = myClass2; "end": 27, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 11, "end": 27, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable myClassWithError." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "myClassWithError" + ] } ] } @@ -419,7 +431,7 @@ exports.myClass2 = myClass2; ] } ], - "size": 2109 + "size": 2177 } app/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-introduceError-when-fixing-errors-only-changed-file-is-emitted.js b/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-introduceError-when-fixing-errors-only-changed-file-is-emitted.js index d9ec913ddc..2225d72b3c 100644 --- a/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-introduceError-when-fixing-errors-only-changed-file-is-emitted.js +++ b/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-introduceError-when-fixing-errors-only-changed-file-is-emitted.js @@ -189,7 +189,7 @@ var myClassWithError = class { exports.myClassWithError = myClassWithError; //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.","impliedNodeFormat":1},{"version":"181818468a51a2348d25d30b10b6b1bb-export class myClass { }","signature":"00d3ac9a4cccbf94649ca3c19d44376a-export declare class myClass {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"message":"Add a type annotation to the variable myClassWithError."}]}]]],"latestChangedDtsFile":"./fileWithError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n","impliedNodeFormat":1},{"version":"181818468a51a2348d25d30b10b6b1bb-export class myClass { }","signature":"00d3ac9a4cccbf94649ca3c19d44376a-export declare class myClass {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["myClassWithError"]}]}]]],"latestChangedDtsFile":"./fileWithError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -226,11 +226,11 @@ exports.myClassWithError = myClassWithError; { "fileName": "./fileWithError.ts", "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": "CommonJS", "original": { "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": 1 } }, @@ -258,14 +258,20 @@ exports.myClassWithError = myClassWithError; "end": 27, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 11, "end": 27, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable myClassWithError." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "myClassWithError" + ] } ] } @@ -283,7 +289,7 @@ exports.myClassWithError = myClassWithError; ] } ], - "size": 2104 + "size": 2172 } app/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-when-file-with-no-error-changes.js b/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-when-file-with-no-error-changes.js index 238dfdebf7..6b2d679cf0 100644 --- a/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-when-file-with-no-error-changes.js +++ b/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-when-file-with-no-error-changes.js @@ -85,7 +85,7 @@ class myClass { exports.myClass = myClass; //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.","impliedNodeFormat":1},{"version":"181818468a51a2348d25d30b10b6b1bb-export class myClass { }","signature":"00d3ac9a4cccbf94649ca3c19d44376a-export declare class myClass {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"message":"Add a type annotation to the variable myClassWithError."}]}]]],"latestChangedDtsFile":"./fileWithoutError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n","impliedNodeFormat":1},{"version":"181818468a51a2348d25d30b10b6b1bb-export class myClass { }","signature":"00d3ac9a4cccbf94649ca3c19d44376a-export declare class myClass {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["myClassWithError"]}]}]]],"latestChangedDtsFile":"./fileWithoutError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -122,11 +122,11 @@ exports.myClass = myClass; { "fileName": "./fileWithError.ts", "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": "CommonJS", "original": { "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": 1 } }, @@ -154,14 +154,20 @@ exports.myClass = myClass; "end": 27, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 11, "end": 27, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable myClassWithError." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "myClassWithError" + ] } ] } @@ -179,7 +185,7 @@ exports.myClass = myClass; ] } ], - "size": 2107 + "size": 2175 } app/tsconfig.json:: @@ -224,7 +230,7 @@ class myClass2 { exports.myClass2 = myClass2; //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.","impliedNodeFormat":1},{"version":"4494620e0f3a6379be16c2477b86b919-export class myClass2 { }","signature":"cdd06be46566b8da2e1a2b5b161ff551-export declare class myClass2 {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"message":"Add a type annotation to the variable myClassWithError."}]}]]],"latestChangedDtsFile":"./fileWithoutError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n","impliedNodeFormat":1},{"version":"4494620e0f3a6379be16c2477b86b919-export class myClass2 { }","signature":"cdd06be46566b8da2e1a2b5b161ff551-export declare class myClass2 {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["myClassWithError"]}]}]]],"latestChangedDtsFile":"./fileWithoutError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -261,11 +267,11 @@ exports.myClass2 = myClass2; { "fileName": "./fileWithError.ts", "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": "CommonJS", "original": { "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": 1 } }, @@ -293,14 +299,20 @@ exports.myClass2 = myClass2; "end": 27, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 11, "end": 27, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable myClassWithError." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "myClassWithError" + ] } ] } @@ -318,7 +330,7 @@ exports.myClass2 = myClass2; ] } ], - "size": 2109 + "size": 2177 } app/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-when-fixing-error-files-all-files-are-emitted.js b/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-when-fixing-error-files-all-files-are-emitted.js index 14e00b8d9a..c62dcd47a1 100644 --- a/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-when-fixing-error-files-all-files-are-emitted.js +++ b/testdata/baselines/reference/tsbuildWatch/programUpdates/declarationEmitErrors-when-fixing-error-files-all-files-are-emitted.js @@ -85,7 +85,7 @@ class myClass { exports.myClass = myClass; //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.","impliedNodeFormat":1},{"version":"181818468a51a2348d25d30b10b6b1bb-export class myClass { }","signature":"00d3ac9a4cccbf94649ca3c19d44376a-export declare class myClass {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"message":"Add a type annotation to the variable myClassWithError."}]}]]],"latestChangedDtsFile":"./fileWithoutError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./fileWithError.ts","./fileWithoutError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};","signature":"0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n","impliedNodeFormat":1},{"version":"181818468a51a2348d25d30b10b6b1bb-export class myClass { }","signature":"00d3ac9a4cccbf94649ca3c19d44376a-export declare class myClass {\n}\n","impliedNodeFormat":1}],"options":{"composite":true},"emitDiagnosticsPerFile":[[2,[{"pos":11,"end":27,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":11,"end":27,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["myClassWithError"]}]}]]],"latestChangedDtsFile":"./fileWithoutError.d.ts","emitSignatures":[[2,"b73b369b8f252d3d9d6dcbf326b8e0e8-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n"]]} //// [/user/username/projects/solution/app/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -122,11 +122,11 @@ exports.myClass = myClass; { "fileName": "./fileWithError.ts", "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": "CommonJS", "original": { "version": "02dc54a766c51fbc368b69a386e90b57-export var myClassWithError = class {\n tags() { }\n private p = 12\n};", - "signature": "4763ea6446bf27424942ef44caadabed-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(11,16): error9027: Add a type annotation to the variable myClassWithError.", + "signature": "0db97697d9203901ca9117430d4f5be9-export declare var myClassWithError: {\n new (): {\n tags(): void;\n p: number;\n };\n};\n\n(11,16): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(11,16): error9027: Add_a_type_annotation_to_the_variable_0_9027\nmyClassWithError\n", "impliedNodeFormat": 1 } }, @@ -154,14 +154,20 @@ exports.myClass = myClass; "end": 27, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 11, "end": 27, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable myClassWithError." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "myClassWithError" + ] } ] } @@ -179,7 +185,7 @@ exports.myClass = myClass; ] } ], - "size": 2107 + "size": 2175 } app/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-preserveWatchOutput-is-not-used.js b/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-preserveWatchOutput-is-not-used.js index 52aaf107d3..fe4f5e884f 100644 --- a/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-preserveWatchOutput-is-not-used.js +++ b/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-preserveWatchOutput-is-not-used.js @@ -568,7 +568,7 @@ let y = 10; //// [/user/username/projects/sample1/logic/index.js.map] *modified* {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAY,CAAC,0CAAsB;AACnC,2BAAkC;IAC9B,OAAO,CAAC,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;AAAA,CAC7B;AACD,MAAY,GAAG,kDAA8B;AAChC,QAAA,CAAC,GAAG,GAAG,CAAC;AACrB,IAAI,CAAC,GAAW,EAAE,CAAC"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../core/anotherModule.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"fc70810d80f598d415c6f21c113a400b-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n//# sourceMappingURL=index.d.ts.map","5ef600f6f6585506cfe942fc161e76c5-export declare const World = \"hello\";\n//# sourceMappingURL=anotherModule.d.ts.map",{"version":"3abed61bf6897ffa70a069303f7ee37f-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;\nlet y: string = 10;","signature":"487f7216384ec40e22ff7dc40c01be4b-export declare function getSecondsInDay(): number;\nimport * as mod from '../core/anotherModule';\nexport declare const m: typeof mod;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":177,"end":178,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../core/anotherModule.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"fc70810d80f598d415c6f21c113a400b-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n//# sourceMappingURL=index.d.ts.map","5ef600f6f6585506cfe942fc161e76c5-export declare const World = \"hello\";\n//# sourceMappingURL=anotherModule.d.ts.map",{"version":"3abed61bf6897ffa70a069303f7ee37f-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;\nlet y: string = 10;","signature":"487f7216384ec40e22ff7dc40c01be4b-export declare function getSecondsInDay(): number;\nimport * as mod from '../core/anotherModule';\nexport declare const m: typeof mod;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":177,"end":178,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -650,13 +650,17 @@ let y = 10; "end": 178, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2046 + "size": 2073 } //// [/user/username/projects/sample1/tests/tsconfig.tsbuildinfo] *mTime changed* @@ -703,7 +707,7 @@ function multiply(a, b) { return a * b; } let x = 10; //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"bd46ecaf1bd821bbf62f3d94c22c2a57-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }\nlet x: string = 10;","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":182,"end":183,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"bd46ecaf1bd821bbf62f3d94c22c2a57-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }\nlet x: string = 10;","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":182,"end":183,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -789,13 +793,17 @@ let x = 10; "end": 183, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 1985 + "size": 2012 } //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo] *mTime changed* //// [/user/username/projects/sample1/tests/tsconfig.tsbuildinfo] *mTime changed* diff --git a/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-preserveWatchOutput-is-passed-on-command-line.js b/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-preserveWatchOutput-is-passed-on-command-line.js index 34661be266..17d1ed8ab1 100644 --- a/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-preserveWatchOutput-is-passed-on-command-line.js +++ b/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-preserveWatchOutput-is-passed-on-command-line.js @@ -568,7 +568,7 @@ let y = 10; //// [/user/username/projects/sample1/logic/index.js.map] *modified* {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAY,CAAC,0CAAsB;AACnC,2BAAkC;IAC9B,OAAO,CAAC,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;AAAA,CAC7B;AACD,MAAY,GAAG,kDAA8B;AAChC,QAAA,CAAC,GAAG,GAAG,CAAC;AACrB,IAAI,CAAC,GAAW,EAAE,CAAC"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../core/anotherModule.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"fc70810d80f598d415c6f21c113a400b-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n//# sourceMappingURL=index.d.ts.map","5ef600f6f6585506cfe942fc161e76c5-export declare const World = \"hello\";\n//# sourceMappingURL=anotherModule.d.ts.map",{"version":"3abed61bf6897ffa70a069303f7ee37f-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;\nlet y: string = 10;","signature":"487f7216384ec40e22ff7dc40c01be4b-export declare function getSecondsInDay(): number;\nimport * as mod from '../core/anotherModule';\nexport declare const m: typeof mod;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":177,"end":178,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../core/anotherModule.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"fc70810d80f598d415c6f21c113a400b-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n//# sourceMappingURL=index.d.ts.map","5ef600f6f6585506cfe942fc161e76c5-export declare const World = \"hello\";\n//# sourceMappingURL=anotherModule.d.ts.map",{"version":"3abed61bf6897ffa70a069303f7ee37f-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;\nlet y: string = 10;","signature":"487f7216384ec40e22ff7dc40c01be4b-export declare function getSecondsInDay(): number;\nimport * as mod from '../core/anotherModule';\nexport declare const m: typeof mod;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":177,"end":178,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -650,13 +650,17 @@ let y = 10; "end": 178, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2046 + "size": 2073 } //// [/user/username/projects/sample1/tests/tsconfig.tsbuildinfo] *mTime changed* @@ -703,7 +707,7 @@ function multiply(a, b) { return a * b; } let x = 10; //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"bd46ecaf1bd821bbf62f3d94c22c2a57-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }\nlet x: string = 10;","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":182,"end":183,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"bd46ecaf1bd821bbf62f3d94c22c2a57-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }\nlet x: string = 10;","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":182,"end":183,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -789,13 +793,17 @@ let x = 10; "end": 183, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 1985 + "size": 2012 } //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo] *mTime changed* //// [/user/username/projects/sample1/tests/tsconfig.tsbuildinfo] *mTime changed* diff --git a/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-stopBuildOnErrors-is-passed-on-command-line.js b/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-stopBuildOnErrors-is-passed-on-command-line.js index f39b616388..620473bcdf 100644 --- a/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-stopBuildOnErrors-is-passed-on-command-line.js +++ b/testdata/baselines/reference/tsbuildWatch/sample/reportErrors-when-stopBuildOnErrors-is-passed-on-command-line.js @@ -568,7 +568,7 @@ let y = 10; //// [/user/username/projects/sample1/logic/index.js.map] *modified* {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAY,CAAC,0CAAsB;AACnC,2BAAkC;IAC9B,OAAO,CAAC,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;AAAA,CAC7B;AACD,MAAY,GAAG,kDAA8B;AAChC,QAAA,CAAC,GAAG,GAAG,CAAC;AACrB,IAAI,CAAC,GAAW,EAAE,CAAC"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../core/anotherModule.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"fc70810d80f598d415c6f21c113a400b-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n//# sourceMappingURL=index.d.ts.map","5ef600f6f6585506cfe942fc161e76c5-export declare const World = \"hello\";\n//# sourceMappingURL=anotherModule.d.ts.map",{"version":"3abed61bf6897ffa70a069303f7ee37f-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;\nlet y: string = 10;","signature":"487f7216384ec40e22ff7dc40c01be4b-export declare function getSecondsInDay(): number;\nimport * as mod from '../core/anotherModule';\nexport declare const m: typeof mod;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":177,"end":178,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.d.ts","../core/index.d.ts","../core/anotherModule.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"fc70810d80f598d415c6f21c113a400b-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n//# sourceMappingURL=index.d.ts.map","5ef600f6f6585506cfe942fc161e76c5-export declare const World = \"hello\";\n//# sourceMappingURL=anotherModule.d.ts.map",{"version":"3abed61bf6897ffa70a069303f7ee37f-import * as c from '../core/index';\nexport function getSecondsInDay() {\n return c.multiply(10, 15);\n}\nimport * as mod from '../core/anotherModule';\nexport const m = mod;\nlet y: string = 10;","signature":"487f7216384ec40e22ff7dc40c01be4b-export declare function getSecondsInDay(): number;\nimport * as mod from '../core/anotherModule';\nexport declare const m: typeof mod;\n","impliedNodeFormat":1}],"fileIdsList":[[2,3]],"options":{"composite":true,"declaration":true,"skipDefaultLibCheck":true,"sourceMap":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":177,"end":178,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/logic/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -650,13 +650,17 @@ let y = 10; "end": 178, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2046 + "size": 2073 } logic/tsconfig.json:: @@ -702,7 +706,7 @@ function multiply(a, b) { return a * b; } let x = 10; //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"bd46ecaf1bd821bbf62f3d94c22c2a57-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }\nlet x: string = 10;","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":182,"end":183,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"bd46ecaf1bd821bbf62f3d94c22c2a57-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }\nlet x: string = 10;","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":182,"end":183,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -788,13 +792,17 @@ let x = 10; "end": 183, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 1985 + "size": 2012 } core/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors-when-test-does-not-reference-core.js b/testdata/baselines/reference/tsbuildWatch/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors-when-test-does-not-reference-core.js index 30362fa24d..6c188b0ec8 100644 --- a/testdata/baselines/reference/tsbuildWatch/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors-when-test-does-not-reference-core.js +++ b/testdata/baselines/reference/tsbuildWatch/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors-when-test-does-not-reference-core.js @@ -145,7 +145,7 @@ function multiply(a, b) { return a * b; } multiply(); //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"4bf9c557eaa1c988144310898522b7b5-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }multiply();","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":177,"end":185,"code":2554,"category":1,"message":"Expected 2 arguments, but got 0.","relatedInformation":[{"pos":138,"end":147,"code":6210,"category":3,"message":"An argument for 'a' was not provided."}]}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"4bf9c557eaa1c988144310898522b7b5-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }multiply();","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":177,"end":185,"code":2554,"category":1,"messageKey":"Expected_0_arguments_but_got_1_2554","messageArgs":["2","0"],"relatedInformation":[{"pos":138,"end":147,"code":6210,"category":3,"messageKey":"An_argument_for_0_was_not_provided_6210","messageArgs":["a"]}]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -231,14 +231,21 @@ multiply(); "end": 185, "code": 2554, "category": 1, - "message": "Expected 2 arguments, but got 0.", + "messageKey": "Expected_0_arguments_but_got_1_2554", + "messageArgs": [ + "2", + "0" + ], "relatedInformation": [ { "pos": 138, "end": 147, "code": 6210, "category": 3, - "message": "An argument for 'a' was not provided." + "messageKey": "An_argument_for_0_was_not_provided_6210", + "messageArgs": [ + "a" + ] } ] } @@ -246,7 +253,7 @@ multiply(); ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2078 + "size": 2133 } core/tsconfig.json:: diff --git a/testdata/baselines/reference/tsbuildWatch/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors.js b/testdata/baselines/reference/tsbuildWatch/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors.js index 508c861c24..0440b34495 100644 --- a/testdata/baselines/reference/tsbuildWatch/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors.js +++ b/testdata/baselines/reference/tsbuildWatch/sample/skips-builds-downstream-projects-if-upstream-projects-have-errors-with-stopBuildOnErrors.js @@ -146,7 +146,7 @@ function multiply(a, b) { return a * b; } multiply(); //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"4bf9c557eaa1c988144310898522b7b5-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }multiply();","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":177,"end":185,"code":2554,"category":1,"message":"Expected 2 arguments, but got 0.","relatedInformation":[{"pos":138,"end":147,"code":6210,"category":3,"message":"An argument for 'a' was not provided."}]}]]],"latestChangedDtsFile":"./index.d.ts"} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./anotherModule.ts","./index.ts","./some_decl.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"19cd44ed7278957051fca663f821c916-export const World = \"hello\";","signature":"5aad0de3e7b08bb6e110c7b97361b89e-export declare const World = \"hello\";\n","impliedNodeFormat":1},{"version":"4bf9c557eaa1c988144310898522b7b5-export const someString: string = \"HELLO WORLD\";\nexport function leftPad(s: string, n: number) { return s + n; }\nexport function multiply(a: number, b: number) { return a * b; }multiply();","signature":"da642d80443e7ccd327091080a82a43c-export declare const someString: string;\nexport declare function leftPad(s: string, n: number): string;\nexport declare function multiply(a: number, b: number): number;\n","impliedNodeFormat":1},{"version":"6ceab83400a6167be2fb5feab881ded0-declare const dts: any;","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"skipDefaultLibCheck":true},"semanticDiagnosticsPerFile":[[3,[{"pos":177,"end":185,"code":2554,"category":1,"messageKey":"Expected_0_arguments_but_got_1_2554","messageArgs":["2","0"],"relatedInformation":[{"pos":138,"end":147,"code":6210,"category":3,"messageKey":"An_argument_for_0_was_not_provided_6210","messageArgs":["a"]}]}]]],"latestChangedDtsFile":"./index.d.ts"} //// [/user/username/projects/sample1/core/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -232,14 +232,21 @@ multiply(); "end": 185, "code": 2554, "category": 1, - "message": "Expected 2 arguments, but got 0.", + "messageKey": "Expected_0_arguments_but_got_1_2554", + "messageArgs": [ + "2", + "0" + ], "relatedInformation": [ { "pos": 138, "end": 147, "code": 6210, "category": 3, - "message": "An argument for 'a' was not provided." + "messageKey": "An_argument_for_0_was_not_provided_6210", + "messageArgs": [ + "a" + ] } ] } @@ -247,7 +254,7 @@ multiply(); ] ], "latestChangedDtsFile": "./index.d.ts", - "size": 2078 + "size": 2133 } core/tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/commandLine/bad-locale.js b/testdata/baselines/reference/tsc/commandLine/bad-locale.js new file mode 100644 index 0000000000..5d1ad434cd --- /dev/null +++ b/testdata/baselines/reference/tsc/commandLine/bad-locale.js @@ -0,0 +1,9 @@ +currentDirectory::/home/src/workspaces/project +useCaseSensitiveFileNames::true +Input:: + +tsgo --locale whoops --version +ExitStatus:: DiagnosticsPresent_OutputsSkipped +Output:: +error TS6048: Locale must be an IETF BCP 47 language tag. Examples: 'en', 'ja-jp'. + diff --git a/testdata/baselines/reference/tsc/commandLine/locale.js b/testdata/baselines/reference/tsc/commandLine/locale.js new file mode 100644 index 0000000000..e8e5716a8a --- /dev/null +++ b/testdata/baselines/reference/tsc/commandLine/locale.js @@ -0,0 +1,9 @@ +currentDirectory::/home/src/workspaces/project +useCaseSensitiveFileNames::true +Input:: + +tsgo --locale cs --version +ExitStatus:: Success +Output:: +Verze FakeTSVersion + diff --git a/testdata/baselines/reference/tsc/composite/synthetic-jsx-import-of-ESM-module-from-CJS-module-error-on-jsx-element.js b/testdata/baselines/reference/tsc/composite/synthetic-jsx-import-of-ESM-module-from-CJS-module-error-on-jsx-element.js index 3dfafa66b8..f248cf28e4 100644 --- a/testdata/baselines/reference/tsc/composite/synthetic-jsx-import-of-ESM-module-from-CJS-module-error-on-jsx-element.js +++ b/testdata/baselines/reference/tsc/composite/synthetic-jsx-import-of-ESM-module-from-CJS-module-error-on-jsx-element.js @@ -45,7 +45,7 @@ const jsx_runtime_1 = require("solid-js/jsx-runtime"); exports.default = jsx_runtime_1.jsx("div", {}); //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[3],"fileNames":["lib.es2022.full.d.ts","./node_modules/solid-js/jsx-runtime.d.ts","./src/main.tsx"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"00e459cbb1596f8c4bdf988b0589433f-export namespace JSX {\n type IntrinsicElements = { div: {}; };\n}","impliedNodeFormat":99},{"version":"5af15af7f9b4d97300f8dcfb2bf5b7c4-export default
;","signature":"ca37c00363f904fe93e299b145186400-declare const _default: any;\nexport default _default;\n","impliedNodeFormat":1}],"options":{"composite":true,"jsx":4,"jsxImportSource":"solid-js","module":100},"semanticDiagnosticsPerFile":[[3,[{"pos":15,"end":21,"code":1479,"category":1,"message":"The current file is a CommonJS module whose imports will produce 'require' calls; however, the referenced file is an ECMAScript module and cannot be imported with 'require'. Consider writing a dynamic 'import(\"solid-js/jsx-runtime\")' call instead.","messageChain":[{"pos":15,"end":21,"code":1483,"category":3,"message":"To convert this file to an ECMAScript module, create a local package.json file with `{ \"type\": \"module\" }`."}]}]]],"latestChangedDtsFile":"./src/main.d.ts"} +{"version":"FakeTSVersion","root":[3],"fileNames":["lib.es2022.full.d.ts","./node_modules/solid-js/jsx-runtime.d.ts","./src/main.tsx"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"00e459cbb1596f8c4bdf988b0589433f-export namespace JSX {\n type IntrinsicElements = { div: {}; };\n}","impliedNodeFormat":99},{"version":"5af15af7f9b4d97300f8dcfb2bf5b7c4-export default
;","signature":"ca37c00363f904fe93e299b145186400-declare const _default: any;\nexport default _default;\n","impliedNodeFormat":1}],"options":{"composite":true,"jsx":4,"jsxImportSource":"solid-js","module":100},"semanticDiagnosticsPerFile":[[3,[{"pos":15,"end":21,"code":1479,"category":1,"messageKey":"The_current_file_is_a_CommonJS_module_whose_imports_will_produce_require_calls_however_the_reference_1479","messageArgs":["solid-js/jsx-runtime"],"messageChain":[{"pos":15,"end":21,"code":1483,"category":3,"messageKey":"To_convert_this_file_to_an_ECMAScript_module_create_a_local_package_json_file_with_type_Colon_module_1483"}]}]]],"latestChangedDtsFile":"./src/main.d.ts"} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -112,14 +112,17 @@ exports.default = jsx_runtime_1.jsx("div", {}); "end": 21, "code": 1479, "category": 1, - "message": "The current file is a CommonJS module whose imports will produce 'require' calls; however, the referenced file is an ECMAScript module and cannot be imported with 'require'. Consider writing a dynamic 'import(\"solid-js/jsx-runtime\")' call instead.", + "messageKey": "The_current_file_is_a_CommonJS_module_whose_imports_will_produce_require_calls_however_the_reference_1479", + "messageArgs": [ + "solid-js/jsx-runtime" + ], "messageChain": [ { "pos": 15, "end": 21, "code": 1483, "category": 3, - "message": "To convert this file to an ECMAScript module, create a local package.json file with `{ \"type\": \"module\" }`." + "messageKey": "To_convert_this_file_to_an_ECMAScript_module_create_a_local_package_json_file_with_type_Colon_module_1483" } ] } @@ -127,7 +130,7 @@ exports.default = jsx_runtime_1.jsx("div", {}); ] ], "latestChangedDtsFile": "./src/main.d.ts", - "size": 1905 + "size": 1800 } //// [/home/src/tslibs/TS/Lib/lib.es2022.full.d.ts] *Lib* /// diff --git a/testdata/baselines/reference/tsc/declarationEmit/reports-dts-generation-errors-with-incremental.js b/testdata/baselines/reference/tsc/declarationEmit/reports-dts-generation-errors-with-incremental.js index 4cd9f7b922..3f898c49e8 100644 --- a/testdata/baselines/reference/tsc/declarationEmit/reports-dts-generation-errors-with-incremental.js +++ b/testdata/baselines/reference/tsc/declarationEmit/reports-dts-generation-errors-with-incremental.js @@ -88,7 +88,7 @@ import ky from 'ky'; export const api = ky.extend({}); //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[3],"fileNames":["lib.esnext.full.d.ts","./node_modules/ky/distribution/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"b9b50c37c18e43d94b0dd4fb43967f10-type KyInstance = {\n extend(options: Record): KyInstance;\n}\ndeclare const ky: KyInstance;\nexport default ky;","impliedNodeFormat":99},{"version":"0f5091e963c17913313e4969c59e6eb4-import ky from 'ky';\nexport const api = ky.extend({});","signature":"5816fe34b5cf354b0d0d19bc77874616-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named.","impliedNodeFormat":99}],"fileIdsList":[[2]],"options":{"composite":true,"declaration":true,"module":199,"skipLibCheck":true,"skipDefaultLibCheck":true},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":34,"end":37,"code":4023,"category":1,"message":"Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named."}]]],"latestChangedDtsFile":"./index.d.ts","emitSignatures":[[3,"5229c9e2248679a39697053812e5f6bb-export declare const api: {\n extend(options: Record): KyInstance;\n};\n"]]} +{"version":"FakeTSVersion","root":[3],"fileNames":["lib.esnext.full.d.ts","./node_modules/ky/distribution/index.d.ts","./index.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"b9b50c37c18e43d94b0dd4fb43967f10-type KyInstance = {\n extend(options: Record): KyInstance;\n}\ndeclare const ky: KyInstance;\nexport default ky;","impliedNodeFormat":99},{"version":"0f5091e963c17913313e4969c59e6eb4-import ky from 'ky';\nexport const api = ky.extend({});","signature":"80d0207a54fef9a805b5e009ed639094-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023\napi\nKyInstance\n\"/home/src/workspaces/project/node_modules/ky/distribution/index\"\n","impliedNodeFormat":99}],"fileIdsList":[[2]],"options":{"composite":true,"declaration":true,"module":199,"skipLibCheck":true,"skipDefaultLibCheck":true},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":34,"end":37,"code":4023,"category":1,"messageKey":"Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023","messageArgs":["api","KyInstance","\"/home/src/workspaces/project/node_modules/ky/distribution/index\""]}]]],"latestChangedDtsFile":"./index.d.ts","emitSignatures":[[3,"5229c9e2248679a39697053812e5f6bb-export declare const api: {\n extend(options: Record): KyInstance;\n};\n"]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -131,11 +131,11 @@ export const api = ky.extend({}); { "fileName": "./index.ts", "version": "0f5091e963c17913313e4969c59e6eb4-import ky from 'ky';\nexport const api = ky.extend({});", - "signature": "5816fe34b5cf354b0d0d19bc77874616-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named.", + "signature": "80d0207a54fef9a805b5e009ed639094-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023\napi\nKyInstance\n\"/home/src/workspaces/project/node_modules/ky/distribution/index\"\n", "impliedNodeFormat": "ESNext", "original": { "version": "0f5091e963c17913313e4969c59e6eb4-import ky from 'ky';\nexport const api = ky.extend({});", - "signature": "5816fe34b5cf354b0d0d19bc77874616-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named.", + "signature": "80d0207a54fef9a805b5e009ed639094-export declare const api: {\n extend(options: Record): KyInstance;\n};\n\n(34,3): error4023: Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023\napi\nKyInstance\n\"/home/src/workspaces/project/node_modules/ky/distribution/index\"\n", "impliedNodeFormat": 99 } } @@ -166,7 +166,12 @@ export const api = ky.extend({}); "end": 37, "code": 4023, "category": 1, - "message": "Exported variable 'api' has or is using name 'KyInstance' from external module \"/home/src/workspaces/project/node_modules/ky/distribution/index\" but cannot be named." + "messageKey": "Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named_4023", + "messageArgs": [ + "api", + "KyInstance", + "\"/home/src/workspaces/project/node_modules/ky/distribution/index\"" + ] } ] ] @@ -182,7 +187,7 @@ export const api = ky.extend({}); ] } ], - "size": 2171 + "size": 2213 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field-with-declaration-emit-enabled.js b/testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field-with-declaration-emit-enabled.js index 6733ef2ba7..9d04eb07a6 100644 --- a/testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field-with-declaration-emit-enabled.js +++ b/testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field-with-declaration-emit-enabled.js @@ -214,7 +214,7 @@ Errors Files //// [/home/src/workspaces/project/main.d.ts] *rewrite with same content* //// [/home/src/workspaces/project/main.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./MessageablePerson.ts","./main.ts"],"fileInfos":[{"version":"778b786cd1eca831889c50ded7c79c1d-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };\ntype ReturnType any> = T extends (...args: any) => infer R ? R : any;\ntype InstanceType any> = T extends abstract new (...args: any) => infer R ? R : any;","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"fc3bcee26e986c769691717bfbe49525-const Messageable = () => {\n return class MessageableClass {\n protected message = 'hello';\n }\n};\nconst wrapper = () => Messageable();\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;","signature":"eb669b96f45855935c22925689eec67c-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property 'message' of exported anonymous class type may not be private or protected.\n(116,7): error9027: Add a type annotation to the variable wrapper.","impliedNodeFormat":1},{"version":"f1d6119c9df9ff1b48604c0e5c5f624f-import MessageablePerson from './MessageablePerson.js';\nfunction logMessage( person: MessageablePerson ) {\n console.log( person.message );\n}","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"declaration":true,"module":99},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":131,"end":138,"code":2445,"category":1,"message":"Property 'message' is protected and only accessible within class 'MessageableClass' and its subclasses."}]]],"emitDiagnosticsPerFile":[[2,[{"pos":116,"end":123,"code":4094,"category":1,"message":"Property 'message' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":116,"end":123,"code":9027,"category":1,"message":"Add a type annotation to the variable wrapper."}]}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./MessageablePerson.ts","./main.ts"],"fileInfos":[{"version":"778b786cd1eca831889c50ded7c79c1d-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };\ntype ReturnType any> = T extends (...args: any) => infer R ? R : any;\ntype InstanceType any> = T extends abstract new (...args: any) => infer R ? R : any;","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"fc3bcee26e986c769691717bfbe49525-const Messageable = () => {\n return class MessageableClass {\n protected message = 'hello';\n }\n};\nconst wrapper = () => Messageable();\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;","signature":"9bca542f83dba4822510bd12bc5e9db9-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\nmessage\n\n(116,7): error9027: Add_a_type_annotation_to_the_variable_0_9027\nwrapper\n","impliedNodeFormat":1},{"version":"f1d6119c9df9ff1b48604c0e5c5f624f-import MessageablePerson from './MessageablePerson.js';\nfunction logMessage( person: MessageablePerson ) {\n console.log( person.message );\n}","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"declaration":true,"module":99},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":131,"end":138,"code":2445,"category":1,"messageKey":"Property_0_is_protected_and_only_accessible_within_class_1_and_its_subclasses_2445","messageArgs":["message","MessageableClass"]}]]],"emitDiagnosticsPerFile":[[2,[{"pos":116,"end":123,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["message"],"relatedInformation":[{"pos":116,"end":123,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["wrapper"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -251,11 +251,11 @@ Errors Files { "fileName": "./MessageablePerson.ts", "version": "fc3bcee26e986c769691717bfbe49525-const Messageable = () => {\n return class MessageableClass {\n protected message = 'hello';\n }\n};\nconst wrapper = () => Messageable();\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;", - "signature": "eb669b96f45855935c22925689eec67c-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property 'message' of exported anonymous class type may not be private or protected.\n(116,7): error9027: Add a type annotation to the variable wrapper.", + "signature": "9bca542f83dba4822510bd12bc5e9db9-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\nmessage\n\n(116,7): error9027: Add_a_type_annotation_to_the_variable_0_9027\nwrapper\n", "impliedNodeFormat": "CommonJS", "original": { "version": "fc3bcee26e986c769691717bfbe49525-const Messageable = () => {\n return class MessageableClass {\n protected message = 'hello';\n }\n};\nconst wrapper = () => Messageable();\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;", - "signature": "eb669b96f45855935c22925689eec67c-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property 'message' of exported anonymous class type may not be private or protected.\n(116,7): error9027: Add a type annotation to the variable wrapper.", + "signature": "9bca542f83dba4822510bd12bc5e9db9-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\nmessage\n\n(116,7): error9027: Add_a_type_annotation_to_the_variable_0_9027\nwrapper\n", "impliedNodeFormat": 1 } }, @@ -294,7 +294,11 @@ Errors Files "end": 138, "code": 2445, "category": 1, - "message": "Property 'message' is protected and only accessible within class 'MessageableClass' and its subclasses." + "messageKey": "Property_0_is_protected_and_only_accessible_within_class_1_and_its_subclasses_2445", + "messageArgs": [ + "message", + "MessageableClass" + ] } ] ] @@ -308,21 +312,27 @@ Errors Files "end": 123, "code": 4094, "category": 1, - "message": "Property 'message' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "message" + ], "relatedInformation": [ { "pos": 116, "end": 123, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable wrapper." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "wrapper" + ] } ] } ] ] ], - "size": 2717 + "size": 2812 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field.js b/testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field.js index 5fb23344b4..e87dc97ab3 100644 --- a/testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field.js +++ b/testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field.js @@ -173,7 +173,7 @@ Found 1 error in main.ts:3 //// [/home/src/workspaces/project/MessageablePerson.js] *rewrite with same content* //// [/home/src/workspaces/project/main.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./MessageablePerson.ts","./main.ts"],"fileInfos":[{"version":"778b786cd1eca831889c50ded7c79c1d-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };\ntype ReturnType any> = T extends (...args: any) => infer R ? R : any;\ntype InstanceType any> = T extends abstract new (...args: any) => infer R ? R : any;","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"fc3bcee26e986c769691717bfbe49525-const Messageable = () => {\n return class MessageableClass {\n protected message = 'hello';\n }\n};\nconst wrapper = () => Messageable();\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;","signature":"eb669b96f45855935c22925689eec67c-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property 'message' of exported anonymous class type may not be private or protected.\n(116,7): error9027: Add a type annotation to the variable wrapper.","impliedNodeFormat":1},{"version":"f1d6119c9df9ff1b48604c0e5c5f624f-import MessageablePerson from './MessageablePerson.js';\nfunction logMessage( person: MessageablePerson ) {\n console.log( person.message );\n}","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"module":99},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":131,"end":138,"code":2445,"category":1,"message":"Property 'message' is protected and only accessible within class 'MessageableClass' and its subclasses."}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./MessageablePerson.ts","./main.ts"],"fileInfos":[{"version":"778b786cd1eca831889c50ded7c79c1d-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };\ntype ReturnType any> = T extends (...args: any) => infer R ? R : any;\ntype InstanceType any> = T extends abstract new (...args: any) => infer R ? R : any;","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"fc3bcee26e986c769691717bfbe49525-const Messageable = () => {\n return class MessageableClass {\n protected message = 'hello';\n }\n};\nconst wrapper = () => Messageable();\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;","signature":"9bca542f83dba4822510bd12bc5e9db9-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\nmessage\n\n(116,7): error9027: Add_a_type_annotation_to_the_variable_0_9027\nwrapper\n","impliedNodeFormat":1},{"version":"f1d6119c9df9ff1b48604c0e5c5f624f-import MessageablePerson from './MessageablePerson.js';\nfunction logMessage( person: MessageablePerson ) {\n console.log( person.message );\n}","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"module":99},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":131,"end":138,"code":2445,"category":1,"messageKey":"Property_0_is_protected_and_only_accessible_within_class_1_and_its_subclasses_2445","messageArgs":["message","MessageableClass"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -210,11 +210,11 @@ Found 1 error in main.ts:3 { "fileName": "./MessageablePerson.ts", "version": "fc3bcee26e986c769691717bfbe49525-const Messageable = () => {\n return class MessageableClass {\n protected message = 'hello';\n }\n};\nconst wrapper = () => Messageable();\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;", - "signature": "eb669b96f45855935c22925689eec67c-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property 'message' of exported anonymous class type may not be private or protected.\n(116,7): error9027: Add a type annotation to the variable wrapper.", + "signature": "9bca542f83dba4822510bd12bc5e9db9-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\nmessage\n\n(116,7): error9027: Add_a_type_annotation_to_the_variable_0_9027\nwrapper\n", "impliedNodeFormat": "CommonJS", "original": { "version": "fc3bcee26e986c769691717bfbe49525-const Messageable = () => {\n return class MessageableClass {\n protected message = 'hello';\n }\n};\nconst wrapper = () => Messageable();\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;", - "signature": "eb669b96f45855935c22925689eec67c-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property 'message' of exported anonymous class type may not be private or protected.\n(116,7): error9027: Add a type annotation to the variable wrapper.", + "signature": "9bca542f83dba4822510bd12bc5e9db9-declare const wrapper: () => {\n new (): {\n message: string;\n };\n};\ntype MessageablePerson = InstanceType>;\nexport default MessageablePerson;\n\n(116,7): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\nmessage\n\n(116,7): error9027: Add_a_type_annotation_to_the_variable_0_9027\nwrapper\n", "impliedNodeFormat": 1 } }, @@ -252,12 +252,16 @@ Found 1 error in main.ts:3 "end": 138, "code": 2445, "category": 1, - "message": "Property 'message' is protected and only accessible within class 'MessageableClass' and its subclasses." + "messageKey": "Property_0_is_protected_and_only_accessible_within_class_1_and_its_subclasses_2445", + "messageArgs": [ + "message", + "MessageableClass" + ] } ] ] ], - "size": 2392 + "size": 2435 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/incremental/react-jsx-emit-mode-with-no-backing-types-found-doesnt-crash-under---strict.js b/testdata/baselines/reference/tsc/incremental/react-jsx-emit-mode-with-no-backing-types-found-doesnt-crash-under---strict.js index ee5f85490e..2935b804de 100644 --- a/testdata/baselines/reference/tsc/incremental/react-jsx-emit-mode-with-no-backing-types-found-doesnt-crash-under---strict.js +++ b/testdata/baselines/reference/tsc/incremental/react-jsx-emit-mode-with-no-backing-types-found-doesnt-crash-under---strict.js @@ -70,7 +70,7 @@ const App = () => jsx_runtime_1.jsx("div", { propA: true }); exports.App = App; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./src/index.tsx","./node_modules/@types/react/index.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"0c3575e38f9aabc971cea9c73a211979-export const App = () =>
;",{"version":"a6afc3c631ce6ad7bc83db84287b52ea-export {};\ndeclare global {\n namespace JSX {\n interface Element {}\n interface IntrinsicElements {\n div: {\n propA?: boolean;\n };\n }\n }\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"jsx":4,"jsxImportSource":"react","module":1,"strict":true},"semanticDiagnosticsPerFile":[[2,[{"pos":25,"end":49,"code":7016,"category":1,"message":"Could not find a declaration file for module 'react/jsx-runtime'. '/home/src/workspaces/project/node_modules/react/jsx-runtime.js' implicitly has an 'any' type."}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./src/index.tsx","./node_modules/@types/react/index.d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"0c3575e38f9aabc971cea9c73a211979-export const App = () =>
;",{"version":"a6afc3c631ce6ad7bc83db84287b52ea-export {};\ndeclare global {\n namespace JSX {\n interface Element {}\n interface IntrinsicElements {\n div: {\n propA?: boolean;\n };\n }\n }\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"jsx":4,"jsxImportSource":"react","module":1,"strict":true},"semanticDiagnosticsPerFile":[[2,[{"pos":25,"end":49,"code":7016,"category":1,"messageKey":"Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016","messageArgs":["react/jsx-runtime","/home/src/workspaces/project/node_modules/react/jsx-runtime.js"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -134,12 +134,16 @@ exports.App = App; "end": 49, "code": 7016, "category": 1, - "message": "Could not find a declaration file for module 'react/jsx-runtime'. '/home/src/workspaces/project/node_modules/react/jsx-runtime.js' implicitly has an 'any' type." + "messageKey": "Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016", + "messageArgs": [ + "react/jsx-runtime", + "/home/src/workspaces/project/node_modules/react/jsx-runtime.js" + ] } ] ] ], - "size": 1623 + "size": 1647 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/incremental/serializing-error-chain.js b/testdata/baselines/reference/tsc/incremental/serializing-error-chain.js index 78c6bf193a..775a84f614 100644 --- a/testdata/baselines/reference/tsc/incremental/serializing-error-chain.js +++ b/testdata/baselines/reference/tsc/incremental/serializing-error-chain.js @@ -74,7 +74,7 @@ declare const console: { log(msg: any): void; }; React.createElement("div", null))); //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./index.tsx"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"8ca521424834f2ae3377cc3ccc9dd3ef-declare namespace JSX {\n interface ElementChildrenAttribute { children: {}; }\n interface IntrinsicElements { div: {} }\n}\n\ndeclare var React: any;\n\ndeclare function Component(props: never): any;\ndeclare function Component(props: { children?: number }): any;\n(\n
\n
\n)","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"jsx":3,"module":99,"strict":true},"semanticDiagnosticsPerFile":[[2,[{"pos":265,"end":274,"code":2769,"category":1,"message":"No overload matches this call.","messageChain":[{"pos":265,"end":274,"code":2770,"category":1,"message":"The last overload gave the following error.","messageChain":[{"pos":265,"end":274,"code":2322,"category":1,"message":"Type '{ children: any[]; }' is not assignable to type '{ children?: number | undefined; }'.","messageChain":[{"pos":265,"end":274,"code":2326,"category":1,"message":"Types of property 'children' are incompatible.","messageChain":[{"pos":265,"end":274,"code":2322,"category":1,"message":"Type 'any[]' is not assignable to type 'number'."}]}]}]}],"relatedInformation":[{"pos":217,"end":226,"code":2771,"category":1,"message":"The last overload is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./index.tsx"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"8ca521424834f2ae3377cc3ccc9dd3ef-declare namespace JSX {\n interface ElementChildrenAttribute { children: {}; }\n interface IntrinsicElements { div: {} }\n}\n\ndeclare var React: any;\n\ndeclare function Component(props: never): any;\ndeclare function Component(props: { children?: number }): any;\n(\n
\n
\n)","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"jsx":3,"module":99,"strict":true},"semanticDiagnosticsPerFile":[[2,[{"pos":265,"end":274,"code":2769,"category":1,"messageKey":"No_overload_matches_this_call_2769","messageChain":[{"pos":265,"end":274,"code":2770,"category":1,"messageKey":"The_last_overload_gave_the_following_error_2770","messageChain":[{"pos":265,"end":274,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["{ children: any[]; }","{ children?: number | undefined; }"],"messageChain":[{"pos":265,"end":274,"code":2326,"category":1,"messageKey":"Types_of_property_0_are_incompatible_2326","messageArgs":["children"],"messageChain":[{"pos":265,"end":274,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["any[]","number"]}]}]}]}],"relatedInformation":[{"pos":217,"end":226,"code":2771,"category":1,"messageKey":"The_last_overload_is_declared_here_2771"}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -130,35 +130,46 @@ declare const console: { log(msg: any): void; }; "end": 274, "code": 2769, "category": 1, - "message": "No overload matches this call.", + "messageKey": "No_overload_matches_this_call_2769", "messageChain": [ { "pos": 265, "end": 274, "code": 2770, "category": 1, - "message": "The last overload gave the following error.", + "messageKey": "The_last_overload_gave_the_following_error_2770", "messageChain": [ { "pos": 265, "end": 274, "code": 2322, "category": 1, - "message": "Type '{ children: any[]; }' is not assignable to type '{ children?: number | undefined; }'.", + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "{ children: any[]; }", + "{ children?: number | undefined; }" + ], "messageChain": [ { "pos": 265, "end": 274, "code": 2326, "category": 1, - "message": "Types of property 'children' are incompatible.", + "messageKey": "Types_of_property_0_are_incompatible_2326", + "messageArgs": [ + "children" + ], "messageChain": [ { "pos": 265, "end": 274, "code": 2322, "category": 1, - "message": "Type 'any[]' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "any[]", + "number" + ] } ] } @@ -173,14 +184,14 @@ declare const console: { log(msg: any): void; }; "end": 226, "code": 2771, "category": 1, - "message": "The last overload is declared here." + "messageKey": "The_last_overload_is_declared_here_2771" } ] } ] ] ], - "size": 2109 + "size": 2209 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/moduleResolution/alternateResult.js b/testdata/baselines/reference/tsc/moduleResolution/alternateResult.js index ef07854e61..035e5f1d66 100644 --- a/testdata/baselines/reference/tsc/moduleResolution/alternateResult.js +++ b/testdata/baselines/reference/tsc/moduleResolution/alternateResult.js @@ -327,7 +327,7 @@ Found 2 errors in the same file, starting at: index.mts:1 export {}; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.es2022.full.d.ts","./node_modules/foo2/index.d.ts","./node_modules/@types/bar2/index.d.ts","./index.mts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"165b91a7791663df5931f0b63ebf9ce2-export declare const foo2: number;","da9728b78f5d24b38c00844e001b4953-export declare const bar2: number;",{"version":"eee0814e4a127747fb836acc50eaeb5a-import { foo } from \"foo\";\nimport { bar } from \"bar\";\nimport { foo2 } from \"foo2\";\nimport { bar2 } from \"bar2\";","impliedNodeFormat":99}],"fileIdsList":[[2,3]],"options":{"module":100,"strict":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":20,"end":25,"code":7016,"category":1,"message":"Could not find a declaration file for module 'foo'. '/home/src/projects/project/node_modules/foo/index.mjs' implicitly has an 'any' type.","messageChain":[{"pos":20,"end":25,"code":6278,"category":3,"message":"There are types at '/home/src/projects/project/node_modules/foo/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The 'foo' library may need to update its package.json or typings."}]},{"pos":47,"end":52,"code":7016,"category":1,"message":"Could not find a declaration file for module 'bar'. '/home/src/projects/project/node_modules/bar/index.mjs' implicitly has an 'any' type.","messageChain":[{"pos":47,"end":52,"code":6278,"category":3,"message":"There are types at '/home/src/projects/project/node_modules/@types/bar/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The '@types/bar' library may need to update its package.json or typings."}]}]]]} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.es2022.full.d.ts","./node_modules/foo2/index.d.ts","./node_modules/@types/bar2/index.d.ts","./index.mts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"165b91a7791663df5931f0b63ebf9ce2-export declare const foo2: number;","da9728b78f5d24b38c00844e001b4953-export declare const bar2: number;",{"version":"eee0814e4a127747fb836acc50eaeb5a-import { foo } from \"foo\";\nimport { bar } from \"bar\";\nimport { foo2 } from \"foo2\";\nimport { bar2 } from \"bar2\";","impliedNodeFormat":99}],"fileIdsList":[[2,3]],"options":{"module":100,"strict":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":20,"end":25,"code":7016,"category":1,"messageKey":"Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016","messageArgs":["foo","/home/src/projects/project/node_modules/foo/index.mjs"],"messageChain":[{"pos":20,"end":25,"code":6278,"category":3,"messageKey":"There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278","messageArgs":["/home/src/projects/project/node_modules/foo/index.d.ts","foo"]}]},{"pos":47,"end":52,"code":7016,"category":1,"messageKey":"Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016","messageArgs":["bar","/home/src/projects/project/node_modules/bar/index.mjs"],"messageChain":[{"pos":47,"end":52,"code":6278,"category":3,"messageKey":"There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278","messageArgs":["/home/src/projects/project/node_modules/@types/bar/index.d.ts","@types/bar"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -406,14 +406,22 @@ export {}; "end": 25, "code": 7016, "category": 1, - "message": "Could not find a declaration file for module 'foo'. '/home/src/projects/project/node_modules/foo/index.mjs' implicitly has an 'any' type.", + "messageKey": "Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016", + "messageArgs": [ + "foo", + "/home/src/projects/project/node_modules/foo/index.mjs" + ], "messageChain": [ { "pos": 20, "end": 25, "code": 6278, "category": 3, - "message": "There are types at '/home/src/projects/project/node_modules/foo/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The 'foo' library may need to update its package.json or typings." + "messageKey": "There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278", + "messageArgs": [ + "/home/src/projects/project/node_modules/foo/index.d.ts", + "foo" + ] } ] }, @@ -422,21 +430,29 @@ export {}; "end": 52, "code": 7016, "category": 1, - "message": "Could not find a declaration file for module 'bar'. '/home/src/projects/project/node_modules/bar/index.mjs' implicitly has an 'any' type.", + "messageKey": "Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016", + "messageArgs": [ + "bar", + "/home/src/projects/project/node_modules/bar/index.mjs" + ], "messageChain": [ { "pos": 47, "end": 52, "code": 6278, "category": 3, - "message": "There are types at '/home/src/projects/project/node_modules/@types/bar/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The '@types/bar' library may need to update its package.json or typings." + "messageKey": "There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278", + "messageArgs": [ + "/home/src/projects/project/node_modules/@types/bar/index.d.ts", + "@types/bar" + ] } ] } ] ] ], - "size": 2399 + "size": 2377 } //// [/home/src/tslibs/TS/Lib/lib.es2022.full.d.ts] *Lib* /// @@ -1574,7 +1590,7 @@ Found 1 error in index.mts:1 //// [/home/src/projects/project/index.mjs] *rewrite with same content* //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[5],"fileNames":["lib.es2022.full.d.ts","./node_modules/@types/bar/index.d.ts","./node_modules/foo2/index.d.ts","./node_modules/@types/bar2/index.d.ts","./index.mts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"78bc7ca8c840e090086811119f6d6ba9-export declare const bar: number;","165b91a7791663df5931f0b63ebf9ce2-export declare const foo2: number;","da9728b78f5d24b38c00844e001b4953-export declare const bar2: number;",{"version":"eee0814e4a127747fb836acc50eaeb5a-import { foo } from \"foo\";\nimport { bar } from \"bar\";\nimport { foo2 } from \"foo2\";\nimport { bar2 } from \"bar2\";","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":99}],"fileIdsList":[[2,3,4]],"options":{"module":100,"strict":true},"referencedMap":[[5,1]],"semanticDiagnosticsPerFile":[[5,[{"pos":20,"end":25,"code":7016,"category":1,"message":"Could not find a declaration file for module 'foo'. '/home/src/projects/project/node_modules/foo/index.mjs' implicitly has an 'any' type.","messageChain":[{"pos":20,"end":25,"code":6278,"category":3,"message":"There are types at '/home/src/projects/project/node_modules/foo/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The 'foo' library may need to update its package.json or typings."}]}]]]} +{"version":"FakeTSVersion","root":[5],"fileNames":["lib.es2022.full.d.ts","./node_modules/@types/bar/index.d.ts","./node_modules/foo2/index.d.ts","./node_modules/@types/bar2/index.d.ts","./index.mts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"78bc7ca8c840e090086811119f6d6ba9-export declare const bar: number;","165b91a7791663df5931f0b63ebf9ce2-export declare const foo2: number;","da9728b78f5d24b38c00844e001b4953-export declare const bar2: number;",{"version":"eee0814e4a127747fb836acc50eaeb5a-import { foo } from \"foo\";\nimport { bar } from \"bar\";\nimport { foo2 } from \"foo2\";\nimport { bar2 } from \"bar2\";","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":99}],"fileIdsList":[[2,3,4]],"options":{"module":100,"strict":true},"referencedMap":[[5,1]],"semanticDiagnosticsPerFile":[[5,[{"pos":20,"end":25,"code":7016,"category":1,"messageKey":"Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016","messageArgs":["foo","/home/src/projects/project/node_modules/foo/index.mjs"],"messageChain":[{"pos":20,"end":25,"code":6278,"category":3,"messageKey":"There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278","messageArgs":["/home/src/projects/project/node_modules/foo/index.d.ts","foo"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1663,21 +1679,29 @@ Found 1 error in index.mts:1 "end": 25, "code": 7016, "category": 1, - "message": "Could not find a declaration file for module 'foo'. '/home/src/projects/project/node_modules/foo/index.mjs' implicitly has an 'any' type.", + "messageKey": "Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016", + "messageArgs": [ + "foo", + "/home/src/projects/project/node_modules/foo/index.mjs" + ], "messageChain": [ { "pos": 20, "end": 25, "code": 6278, "category": 3, - "message": "There are types at '/home/src/projects/project/node_modules/foo/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The 'foo' library may need to update its package.json or typings." + "messageKey": "There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278", + "messageArgs": [ + "/home/src/projects/project/node_modules/foo/index.d.ts", + "foo" + ] } ] } ] ] ], - "size": 2063 + "size": 2052 } tsconfig.json:: @@ -2086,7 +2110,7 @@ Found 1 error in index.mts:4 //// [/home/src/projects/project/index.mjs] *rewrite with same content* //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[5],"fileNames":["lib.es2022.full.d.ts","./node_modules/foo/index.d.ts","./node_modules/@types/bar/index.d.ts","./node_modules/foo2/index.d.ts","./index.mts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"2a914bfad3bba77712486af8a4cdc415-export declare const foo: number;","78bc7ca8c840e090086811119f6d6ba9-export declare const bar: number;","165b91a7791663df5931f0b63ebf9ce2-export declare const foo2: number;",{"version":"eee0814e4a127747fb836acc50eaeb5a-import { foo } from \"foo\";\nimport { bar } from \"bar\";\nimport { foo2 } from \"foo2\";\nimport { bar2 } from \"bar2\";","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":99}],"fileIdsList":[[2,3,4]],"options":{"module":100,"strict":true},"referencedMap":[[5,1]],"semanticDiagnosticsPerFile":[[5,[{"pos":104,"end":110,"code":7016,"category":1,"message":"Could not find a declaration file for module 'bar2'. '/home/src/projects/project/node_modules/bar2/index.mjs' implicitly has an 'any' type.","messageChain":[{"pos":104,"end":110,"code":6278,"category":3,"message":"There are types at '/home/src/projects/project/node_modules/@types/bar2/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The '@types/bar2' library may need to update its package.json or typings."}]}]]]} +{"version":"FakeTSVersion","root":[5],"fileNames":["lib.es2022.full.d.ts","./node_modules/foo/index.d.ts","./node_modules/@types/bar/index.d.ts","./node_modules/foo2/index.d.ts","./index.mts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"2a914bfad3bba77712486af8a4cdc415-export declare const foo: number;","78bc7ca8c840e090086811119f6d6ba9-export declare const bar: number;","165b91a7791663df5931f0b63ebf9ce2-export declare const foo2: number;",{"version":"eee0814e4a127747fb836acc50eaeb5a-import { foo } from \"foo\";\nimport { bar } from \"bar\";\nimport { foo2 } from \"foo2\";\nimport { bar2 } from \"bar2\";","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":99}],"fileIdsList":[[2,3,4]],"options":{"module":100,"strict":true},"referencedMap":[[5,1]],"semanticDiagnosticsPerFile":[[5,[{"pos":104,"end":110,"code":7016,"category":1,"messageKey":"Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016","messageArgs":["bar2","/home/src/projects/project/node_modules/bar2/index.mjs"],"messageChain":[{"pos":104,"end":110,"code":6278,"category":3,"messageKey":"There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278","messageArgs":["/home/src/projects/project/node_modules/@types/bar2/index.d.ts","@types/bar2"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -2175,21 +2199,29 @@ Found 1 error in index.mts:4 "end": 110, "code": 7016, "category": 1, - "message": "Could not find a declaration file for module 'bar2'. '/home/src/projects/project/node_modules/bar2/index.mjs' implicitly has an 'any' type.", + "messageKey": "Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016", + "messageArgs": [ + "bar2", + "/home/src/projects/project/node_modules/bar2/index.mjs" + ], "messageChain": [ { "pos": 104, "end": 110, "code": 6278, "category": 3, - "message": "There are types at '/home/src/projects/project/node_modules/@types/bar2/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The '@types/bar2' library may need to update its package.json or typings." + "messageKey": "There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278", + "messageArgs": [ + "/home/src/projects/project/node_modules/@types/bar2/index.d.ts", + "@types/bar2" + ] } ] } ] ] ], - "size": 2076 + "size": 2065 } tsconfig.json:: @@ -2417,7 +2449,7 @@ Found 2 errors in the same file, starting at: index.mts:3 //// [/home/src/projects/project/index.mjs] *rewrite with same content* //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[4],"fileNames":["lib.es2022.full.d.ts","./node_modules/foo/index.d.ts","./node_modules/@types/bar/index.d.ts","./index.mts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"2a914bfad3bba77712486af8a4cdc415-export declare const foo: number;","78bc7ca8c840e090086811119f6d6ba9-export declare const bar: number;",{"version":"eee0814e4a127747fb836acc50eaeb5a-import { foo } from \"foo\";\nimport { bar } from \"bar\";\nimport { foo2 } from \"foo2\";\nimport { bar2 } from \"bar2\";","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":99}],"fileIdsList":[[2,3]],"options":{"module":100,"strict":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":75,"end":81,"code":7016,"category":1,"message":"Could not find a declaration file for module 'foo2'. '/home/src/projects/project/node_modules/foo2/index.mjs' implicitly has an 'any' type.","messageChain":[{"pos":75,"end":81,"code":6278,"category":3,"message":"There are types at '/home/src/projects/project/node_modules/foo2/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The 'foo2' library may need to update its package.json or typings."}]},{"pos":104,"end":110,"code":7016,"category":1,"message":"Could not find a declaration file for module 'bar2'. '/home/src/projects/project/node_modules/bar2/index.mjs' implicitly has an 'any' type.","messageChain":[{"pos":104,"end":110,"code":6278,"category":3,"message":"There are types at '/home/src/projects/project/node_modules/@types/bar2/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The '@types/bar2' library may need to update its package.json or typings."}]}]]]} +{"version":"FakeTSVersion","root":[4],"fileNames":["lib.es2022.full.d.ts","./node_modules/foo/index.d.ts","./node_modules/@types/bar/index.d.ts","./index.mts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"2a914bfad3bba77712486af8a4cdc415-export declare const foo: number;","78bc7ca8c840e090086811119f6d6ba9-export declare const bar: number;",{"version":"eee0814e4a127747fb836acc50eaeb5a-import { foo } from \"foo\";\nimport { bar } from \"bar\";\nimport { foo2 } from \"foo2\";\nimport { bar2 } from \"bar2\";","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":99}],"fileIdsList":[[2,3]],"options":{"module":100,"strict":true},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":75,"end":81,"code":7016,"category":1,"messageKey":"Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016","messageArgs":["foo2","/home/src/projects/project/node_modules/foo2/index.mjs"],"messageChain":[{"pos":75,"end":81,"code":6278,"category":3,"messageKey":"There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278","messageArgs":["/home/src/projects/project/node_modules/foo2/index.d.ts","foo2"]}]},{"pos":104,"end":110,"code":7016,"category":1,"messageKey":"Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016","messageArgs":["bar2","/home/src/projects/project/node_modules/bar2/index.mjs"],"messageChain":[{"pos":104,"end":110,"code":6278,"category":3,"messageKey":"There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278","messageArgs":["/home/src/projects/project/node_modules/@types/bar2/index.d.ts","@types/bar2"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -2497,14 +2529,22 @@ Found 2 errors in the same file, starting at: index.mts:3 "end": 81, "code": 7016, "category": 1, - "message": "Could not find a declaration file for module 'foo2'. '/home/src/projects/project/node_modules/foo2/index.mjs' implicitly has an 'any' type.", + "messageKey": "Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016", + "messageArgs": [ + "foo2", + "/home/src/projects/project/node_modules/foo2/index.mjs" + ], "messageChain": [ { "pos": 75, "end": 81, "code": 6278, "category": 3, - "message": "There are types at '/home/src/projects/project/node_modules/foo2/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The 'foo2' library may need to update its package.json or typings." + "messageKey": "There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278", + "messageArgs": [ + "/home/src/projects/project/node_modules/foo2/index.d.ts", + "foo2" + ] } ] }, @@ -2513,21 +2553,29 @@ Found 2 errors in the same file, starting at: index.mts:3 "end": 110, "code": 7016, "category": 1, - "message": "Could not find a declaration file for module 'bar2'. '/home/src/projects/project/node_modules/bar2/index.mjs' implicitly has an 'any' type.", + "messageKey": "Could_not_find_a_declaration_file_for_module_0_1_implicitly_has_an_any_type_7016", + "messageArgs": [ + "bar2", + "/home/src/projects/project/node_modules/bar2/index.mjs" + ], "messageChain": [ { "pos": 104, "end": 110, "code": 6278, "category": 3, - "message": "There are types at '/home/src/projects/project/node_modules/@types/bar2/index.d.ts', but this result could not be resolved when respecting package.json \"exports\". The '@types/bar2' library may need to update its package.json or typings." + "messageKey": "There_are_types_at_0_but_this_result_could_not_be_resolved_when_respecting_package_json_exports_The__6278", + "messageArgs": [ + "/home/src/projects/project/node_modules/@types/bar2/index.d.ts", + "@types/bar2" + ] } ] } ] ] ], - "size": 2467 + "size": 2445 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/moduleResolution/package-json-scope.js b/testdata/baselines/reference/tsc/moduleResolution/package-json-scope.js index d50d7c12a5..cd3c79443e 100644 --- a/testdata/baselines/reference/tsc/moduleResolution/package-json-scope.js +++ b/testdata/baselines/reference/tsc/moduleResolution/package-json-scope.js @@ -106,7 +106,7 @@ exports.x = void 0; exports.x = 10; //// [/home/src/workspaces/project/src/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.es2016.full.d.ts","./main.ts","./fileB.mts","./fileA.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"28e8748a7acd58f4f59388926e914f86-export const x = 10;","signature":"f9b4154a9a5944099ecf197d4519d083-export declare const x = 10;\n","impliedNodeFormat":1},{"version":"d03690d860e74c03bcacf63f0dd68b93-export function foo() {}","signature":"7ffb4ea6089b1a385965a214ba412941-export declare function foo(): void;\n","impliedNodeFormat":99},{"version":"cc520ca096f0b81d18073ba8a9776fe3-import { foo } from \"./fileB.mjs\";\nfoo();","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[3]],"options":{"composite":true,"module":100,"target":3},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":20,"end":33,"code":1479,"category":1,"message":"The current file is a CommonJS module whose imports will produce 'require' calls; however, the referenced file is an ECMAScript module and cannot be imported with 'require'. Consider writing a dynamic 'import(\"./fileB.mjs\")' call instead.","messageChain":[{"pos":20,"end":33,"code":1481,"category":3,"message":"To convert this file to an ECMAScript module, change its file extension to '.mts', or add the field `\"type\": \"module\"` to '/home/src/workspaces/project/package.json'."}]}]]],"latestChangedDtsFile":"./fileA.d.ts"} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.es2016.full.d.ts","./main.ts","./fileB.mts","./fileA.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"28e8748a7acd58f4f59388926e914f86-export const x = 10;","signature":"f9b4154a9a5944099ecf197d4519d083-export declare const x = 10;\n","impliedNodeFormat":1},{"version":"d03690d860e74c03bcacf63f0dd68b93-export function foo() {}","signature":"7ffb4ea6089b1a385965a214ba412941-export declare function foo(): void;\n","impliedNodeFormat":99},{"version":"cc520ca096f0b81d18073ba8a9776fe3-import { foo } from \"./fileB.mjs\";\nfoo();","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[3]],"options":{"composite":true,"module":100,"target":3},"referencedMap":[[4,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":20,"end":33,"code":1479,"category":1,"messageKey":"The_current_file_is_a_CommonJS_module_whose_imports_will_produce_require_calls_however_the_reference_1479","messageArgs":["./fileB.mjs"],"messageChain":[{"pos":20,"end":33,"code":1481,"category":3,"messageKey":"To_convert_this_file_to_an_ECMAScript_module_change_its_file_extension_to_0_or_add_the_field_type_Co_1481","messageArgs":[".mts","/home/src/workspaces/project/package.json"]}]}]]],"latestChangedDtsFile":"./fileA.d.ts"} //// [/home/src/workspaces/project/src/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -200,14 +200,21 @@ exports.x = 10; "end": 33, "code": 1479, "category": 1, - "message": "The current file is a CommonJS module whose imports will produce 'require' calls; however, the referenced file is an ECMAScript module and cannot be imported with 'require'. Consider writing a dynamic 'import(\"./fileB.mjs\")' call instead.", + "messageKey": "The_current_file_is_a_CommonJS_module_whose_imports_will_produce_require_calls_however_the_reference_1479", + "messageArgs": [ + "./fileB.mjs" + ], "messageChain": [ { "pos": 20, "end": 33, "code": 1481, "category": 3, - "message": "To convert this file to an ECMAScript module, change its file extension to '.mts', or add the field `\"type\": \"module\"` to '/home/src/workspaces/project/package.json'." + "messageKey": "To_convert_this_file_to_an_ECMAScript_module_change_its_file_extension_to_0_or_add_the_field_type_Co_1481", + "messageArgs": [ + ".mts", + "/home/src/workspaces/project/package.json" + ] } ] } @@ -215,7 +222,7 @@ exports.x = 10; ] ], "latestChangedDtsFile": "./fileA.d.ts", - "size": 2140 + "size": 2043 } src/tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noCheck/dts-errors-with-incremental.js b/testdata/baselines/reference/tsc/noCheck/dts-errors-with-incremental.js index 31b85a5cb9..7efb7cb505 100644 --- a/testdata/baselines/reference/tsc/noCheck/dts-errors-with-incremental.js +++ b/testdata/baselines/reference/tsc/noCheck/dts-errors-with-incremental.js @@ -77,7 +77,7 @@ exports.b = void 0; exports.b = 10; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[1,2,3],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[1,2,3],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -115,11 +115,11 @@ exports.b = 10; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -152,21 +152,27 @@ exports.b = 10; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1810 + "size": 1878 } tsconfig.json:: @@ -449,7 +455,7 @@ const a = class { exports.a = a; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -487,11 +493,11 @@ exports.a = a; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -522,21 +528,27 @@ exports.a = a; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1806 + "size": 1874 } tsconfig.json:: @@ -588,7 +600,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -625,11 +637,11 @@ Found 1 error in a.ts:1 { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -657,21 +669,27 @@ Found 1 error in a.ts:1 "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1753 + "size": 1821 } tsconfig.json:: @@ -871,7 +889,7 @@ exports.c = void 0; exports.c = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -953,12 +971,16 @@ exports.c = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: @@ -1004,7 +1026,7 @@ const a = class { exports.a = a; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1044,11 +1066,11 @@ exports.a = a; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -1088,7 +1110,11 @@ exports.a = a; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -1102,21 +1128,27 @@ exports.a = a; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 2114 + "size": 2209 } tsconfig.json:: @@ -1143,7 +1175,7 @@ exports.a = void 0; exports.a = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1227,12 +1259,16 @@ exports.a = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1611 + "size": 1638 } tsconfig.json:: @@ -1256,7 +1292,7 @@ Output:: Found 1 error in c.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1338,12 +1374,16 @@ Found 1 error in c.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noCheck/semantic-errors-with-incremental.js b/testdata/baselines/reference/tsc/noCheck/semantic-errors-with-incremental.js index 79f7062075..9f42a3e028 100644 --- a/testdata/baselines/reference/tsc/noCheck/semantic-errors-with-incremental.js +++ b/testdata/baselines/reference/tsc/noCheck/semantic-errors-with-incremental.js @@ -466,7 +466,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"2c3aef4914dc04eedbda88b614f5cc47-export const a: number = \"hello\";","signature":"03ee330dc35a9c186b6cc67781eafb11-export declare const a: number;\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"2c3aef4914dc04eedbda88b614f5cc47-export const a: number = \"hello\";","signature":"03ee330dc35a9c186b6cc67781eafb11-export declare const a: number;\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -535,12 +535,16 @@ Found 1 error in a.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1398 + "size": 1425 } tsconfig.json:: @@ -735,7 +739,7 @@ exports.c = void 0; exports.c = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -817,12 +821,16 @@ exports.c = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: @@ -844,7 +852,7 @@ export declare const a: number; //// [/home/src/workspaces/project/a.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"2c3aef4914dc04eedbda88b614f5cc47-export const a: number = \"hello\";","signature":"03ee330dc35a9c186b6cc67781eafb11-export declare const a: number;\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"2c3aef4914dc04eedbda88b614f5cc47-export const a: number = \"hello\";","signature":"03ee330dc35a9c186b6cc67781eafb11-export declare const a: number;\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -928,12 +936,16 @@ export declare const a: number; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1615 + "size": 1642 } tsconfig.json:: @@ -955,7 +967,7 @@ export declare const a = "hello"; //// [/home/src/workspaces/project/a.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1039,12 +1051,16 @@ export declare const a = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1611 + "size": 1638 } tsconfig.json:: @@ -1068,7 +1084,7 @@ Output:: Found 1 error in c.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1150,12 +1166,16 @@ Found 1 error in c.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noCheck/syntax-errors-with-incremental.js b/testdata/baselines/reference/tsc/noCheck/syntax-errors-with-incremental.js index 3dea3854e6..402fd4c269 100644 --- a/testdata/baselines/reference/tsc/noCheck/syntax-errors-with-incremental.js +++ b/testdata/baselines/reference/tsc/noCheck/syntax-errors-with-incremental.js @@ -768,7 +768,7 @@ exports.c = void 0; exports.c = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -850,12 +850,16 @@ exports.c = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: @@ -888,7 +892,7 @@ exports.a = void 0; exports.a = "hello; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","errors":true,"checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"1fca32c5d452470ed9d0aa38bbe62e60-export const a = \"hello","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","errors":true,"checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"1fca32c5d452470ed9d0aa38bbe62e60-export const a = \"hello","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -973,12 +977,16 @@ exports.a = "hello; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1622 + "size": 1649 } tsconfig.json:: @@ -1003,7 +1011,7 @@ exports.a = void 0; exports.a = "hello"; //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","checkPending":true,"root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[2,[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1087,12 +1095,16 @@ exports.a = "hello"; "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1611 + "size": 1638 } tsconfig.json:: @@ -1116,7 +1128,7 @@ Output:: Found 1 error in c.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"270675b5bc3d695752ac89c2c3af7b2e-export const a = \"hello\";","signature":"8db48ef76072c70d24f212a9f210f622-export declare const a = \"hello\";\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"32c618963fbf4ae5f1475f9be91d77bb-export const c: number = \"hello\";","signature":"330cf13f2bbf810d913e97d0cc189ea6-export declare const c: number;\n","impliedNodeFormat":1}],"options":{"declaration":true},"semanticDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1198,12 +1210,16 @@ Found 1 error in c.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1589 + "size": 1616 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/changes-composite.js b/testdata/baselines/reference/tsc/noEmit/changes-composite.js index 684ab7b066..37ee82042d 100644 --- a/testdata/baselines/reference/tsc/noEmit/changes-composite.js +++ b/testdata/baselines/reference/tsc/noEmit/changes-composite.js @@ -331,7 +331,7 @@ Errors Files 1 src/indirectUse.ts:2 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;",{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"affectedFilesPendingEmit":[2,[4],3,[5]],"latestChangedDtsFile":"./src/noChangeFileWithEmitSpecificError.d.ts","emitSignatures":[[2,"8743eb01f3ddad300611aa9bbf6b6c0a-export declare class classC {\n prop: number;\n}\n"],[4,"abe7d9981d6018efb6b2b794f40a1607-export {};\n"],[5,"abe7d9981d6018efb6b2b794f40a1607-export {};\n"]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;",{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"affectedFilesPendingEmit":[2,[4],3,[5]],"latestChangedDtsFile":"./src/noChangeFileWithEmitSpecificError.d.ts","emitSignatures":[[2,"8743eb01f3ddad300611aa9bbf6b6c0a-export declare class classC {\n prop: number;\n}\n"],[4,"abe7d9981d6018efb6b2b794f40a1607-export {};\n"],[5,"abe7d9981d6018efb6b2b794f40a1607-export {};\n"]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -463,7 +463,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -471,7 +476,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -485,7 +493,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -493,7 +506,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -553,7 +569,7 @@ Errors Files ] } ], - "size": 3190 + "size": 3298 } tsconfig.json:: @@ -825,7 +841,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"latestChangedDtsFile":"./src/class.d.ts"} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"latestChangedDtsFile":"./src/class.d.ts"} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -967,7 +983,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -975,7 +996,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -989,7 +1013,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -997,7 +1026,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -1005,7 +1037,7 @@ exports.classC = classC; ] ], "latestChangedDtsFile": "./src/class.d.ts", - "size": 3093 + "size": 3201 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/changes-incremental-declaration.js b/testdata/baselines/reference/tsc/noEmit/changes-incremental-declaration.js index 5b783b64e3..095b898f9c 100644 --- a/testdata/baselines/reference/tsc/noEmit/changes-incremental-declaration.js +++ b/testdata/baselines/reference/tsc/noEmit/changes-incremental-declaration.js @@ -330,7 +330,7 @@ Errors Files 1 src/indirectUse.ts:2 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;",{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"affectedFilesPendingEmit":[2,[4],3,[5]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;",{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"affectedFilesPendingEmit":[2,[4],3,[5]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -462,7 +462,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -470,7 +475,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -484,7 +492,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -492,7 +505,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -525,7 +541,7 @@ Errors Files ] ] ], - "size": 2906 + "size": 3014 } tsconfig.json:: @@ -803,7 +819,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/src/indirectUse.d.ts] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -945,7 +961,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -953,7 +974,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -967,7 +991,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -975,14 +1004,17 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } ] ] ], - "size": 3053 + "size": 3161 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/changes-incremental.js b/testdata/baselines/reference/tsc/noEmit/changes-incremental.js index e7d2f13ae7..169d7db32b 100644 --- a/testdata/baselines/reference/tsc/noEmit/changes-incremental.js +++ b/testdata/baselines/reference/tsc/noEmit/changes-incremental.js @@ -272,7 +272,7 @@ Errors Files 1 src/indirectUse.ts:2 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"affectedFilesPendingEmit":[2,4,3,5]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"affectedFilesPendingEmit":[2,4,3,5]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -405,7 +405,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -413,7 +418,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -427,7 +435,12 @@ Errors Files "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -435,7 +448,10 @@ Errors Files "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -464,7 +480,7 @@ Errors Files 5 ] ], - "size": 2807 + "size": 2915 } tsconfig.json:: @@ -713,7 +729,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -836,7 +852,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -844,7 +865,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -858,7 +882,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -866,14 +895,17 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } ] ] ], - "size": 2582 + "size": 2690 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-composite.js b/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-composite.js index 36c0d08c5f..446644d524 100644 --- a/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-composite.js +++ b/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-composite.js @@ -521,7 +521,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]],"latestChangedDtsFile":"./src/class.d.ts"} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"composite":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]],"latestChangedDtsFile":"./src/class.d.ts"} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -663,7 +663,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -671,7 +676,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -685,7 +693,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -693,7 +706,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -701,7 +717,7 @@ exports.classC = classC; ] ], "latestChangedDtsFile": "./src/class.d.ts", - "size": 3093 + "size": 3201 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental-declaration.js b/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental-declaration.js index 06cf8ee6c6..ee6f0436f8 100644 --- a/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental-declaration.js +++ b/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental-declaration.js @@ -497,7 +497,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/src/indirectUse.d.ts] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}","signature":"b46de008dd76697ce12a1dca20c0bf9e-export declare function writeLog(s: string): void;\n","impliedNodeFormat":1},{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","signature":"86b693f65e0d5bed7e4ac554c2edb8ba-declare function someFunc(arguments: boolean, ...rest: any[]): void;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"options":{"declaration":true},"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -639,7 +639,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -647,7 +652,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -661,7 +669,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -669,14 +682,17 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } ] ] ], - "size": 3053 + "size": 3161 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental.js b/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental.js index 30ecfe7660..671a78cf8f 100644 --- a/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental.js +++ b/testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental.js @@ -412,7 +412,7 @@ exports.classC = classC; //// [/home/src/workspaces/project/src/indirectClass.js] *rewrite with same content* //// [/home/src/workspaces/project/src/indirectUse.js] *rewrite with same content* //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"message":"Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?","relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"message":"'prop1' is declared here."}]}]]]} +{"version":"FakeTSVersion","root":[[2,7]],"fileNames":["lib.d.ts","./src/class.ts","./src/indirectClass.ts","./src/directUse.ts","./src/indirectUse.ts","./src/noChangeFile.ts","./src/noChangeFileWithEmitSpecificError.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"f5da9f4ab128bbaf87adf83ca7ae8e2d-export class classC {\n prop1 = 1;\n}","signature":"e36cbd492db9c71062d723d518b6277f-export declare class classC {\n prop1: number;\n}\n","impliedNodeFormat":1},{"version":"2d32895543847620d7c9848ddd3a7306-import { classC } from './class';\nexport class indirectClass {\n classC = new classC();\n}","signature":"4c7e50f9604f4038b2f1bafae04987bb-import { classC } from './class';\nexport declare class indirectClass {\n classC: classC;\n}\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},{"version":"1e7a664a983b65ba5fbd926c9dad4a26-import { indirectClass } from './indirectClass';\nnew indirectClass().classC.prop;","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1},"12f2d04905c254bde932222194cd2d1b-export function writeLog(s: string) {\n}",{"version":"f54e687ca7ac9fc3c2161967d09e9950-function someFunc(arguments: boolean, ...rest: any[]) {\n}","affectsGlobalScope":true,"impliedNodeFormat":1}],"fileIdsList":[[3],[2]],"referencedMap":[[4,1],[3,2],[5,1]],"semanticDiagnosticsPerFile":[[4,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]],[5,[{"pos":76,"end":80,"code":2551,"category":1,"messageKey":"Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551","messageArgs":["prop","classC","prop1"],"relatedInformation":[{"file":2,"pos":26,"end":31,"code":2728,"category":3,"messageKey":"_0_is_declared_here_2728","messageArgs":["prop1"]}]}]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -545,7 +545,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -553,7 +558,10 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } @@ -567,7 +575,12 @@ exports.classC = classC; "end": 80, "code": 2551, "category": 1, - "message": "Property 'prop' does not exist on type 'classC'. Did you mean 'prop1'?", + "messageKey": "Property_0_does_not_exist_on_type_1_Did_you_mean_2_2551", + "messageArgs": [ + "prop", + "classC", + "prop1" + ], "relatedInformation": [ { "file": "./src/class.ts", @@ -575,14 +588,17 @@ exports.classC = classC; "end": 31, "code": 2728, "category": 3, - "message": "'prop1' is declared here." + "messageKey": "_0_is_declared_here_2728", + "messageArgs": [ + "prop1" + ] } ] } ] ] ], - "size": 2770 + "size": 2878 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/dts-errors-with-declaration-enable-changes-with-multiple-files.js b/testdata/baselines/reference/tsc/noEmit/dts-errors-with-declaration-enable-changes-with-multiple-files.js index fbd4468cd3..cb01d23441 100644 --- a/testdata/baselines/reference/tsc/noEmit/dts-errors-with-declaration-enable-changes-with-multiple-files.js +++ b/testdata/baselines/reference/tsc/noEmit/dts-errors-with-declaration-enable-changes-with-multiple-files.js @@ -193,7 +193,7 @@ Errors Files 1 d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17],[4,17],[5,17]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17],[4,17],[5,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -268,14 +268,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -289,14 +295,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -310,14 +322,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -358,7 +376,7 @@ Errors Files ] ] ], - "size": 2084 + "size": 2240 } tsconfig.json:: @@ -407,7 +425,7 @@ Errors Files 1 d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };"],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,49],[3,49],[4,49],[5,49]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };"],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,49],[3,49],[4,49],[5,49]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -483,14 +501,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -504,14 +528,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -525,14 +555,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -573,7 +609,7 @@ Errors Files ] ] ], - "size": 2106 + "size": 2262 } tsconfig.json:: @@ -690,7 +726,7 @@ const d = class { exports.d = d; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","signature":"797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]],[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -731,11 +767,11 @@ exports.d = d; { "fileName": "./a.ts", "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": "CommonJS", "original": { "version": "9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };", - "signature": "ee8f9d3f76983159b6f8f0407d3b0dff-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable a.", + "signature": "797d7267ef7f35dc3f989be23b6d4fe3-export declare const a: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "impliedNodeFormat": 1 } }, @@ -753,22 +789,22 @@ exports.d = d; { "fileName": "./c.ts", "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": 1 } }, { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -785,14 +821,20 @@ exports.d = d; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -806,14 +848,20 @@ exports.d = d; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -827,21 +875,27 @@ exports.d = d; "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } ] ] ], - "size": 3087 + "size": 3291 } tsconfig.json:: @@ -861,7 +915,7 @@ tsgo --noEmit ExitStatus:: Success Output:: //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -924,22 +978,22 @@ Output:: { "fileName": "./c.ts", "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": 1 } }, { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -953,14 +1007,20 @@ Output:: "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -974,14 +1034,20 @@ Output:: "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -995,7 +1061,7 @@ Output:: 2 ] ], - "size": 2663 + "size": 2799 } tsconfig.json:: @@ -1036,7 +1102,7 @@ Errors Files 1 d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,16],[4,16],[5,16]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,16],[4,16],[5,16]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1099,22 +1165,22 @@ Errors Files { "fileName": "./c.ts", "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": 1 } }, { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -1131,14 +1197,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -1152,14 +1224,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -1200,7 +1278,7 @@ Errors Files ] ] ], - "size": 2720 + "size": 2856 } tsconfig.json:: @@ -1239,7 +1317,7 @@ Errors Files 1 d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable c."}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,49],[3,48],[4,48],[5,48]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };","signature":"e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[4,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["c"]}]}]],[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,49],[3,48],[4,48],[5,48]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1302,22 +1380,22 @@ Errors Files { "fileName": "./c.ts", "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": "CommonJS", "original": { "version": "6f729672e1964d12037938bd07604115-export const c = class { private p = 10; };", - "signature": "e2ca0ad93099a06094277675c8c60e6f-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable c.", + "signature": "e1e85d69ff8bbf5440c12f8f1badf3e4-export declare const c: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nc\n", "impliedNodeFormat": 1 } }, { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -1335,14 +1413,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable c." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "c" + ] } ] } @@ -1356,14 +1440,20 @@ Errors Files "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -1404,7 +1494,7 @@ Errors Files ] ] ], - "size": 2742 + "size": 2878 } tsconfig.json:: @@ -1432,7 +1522,7 @@ Output:: Found 1 error in d.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"dc7165893e9c62cfeea6f0fad1d8b57c-export const c = class { public p = 10; };","signature":"17c24c6640bff8629aa96eed43575ace-export declare const c: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.","impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[5,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable d."}]}]]],"affectedFilesPendingEmit":[[2,49],[3,48],[4,49],[5,48]]} +{"version":"FakeTSVersion","root":[[2,5]],"fileNames":["lib.d.ts","./a.ts","./b.ts","./c.ts","./d.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"257f0ffae056266a216e22aca9e25055-export const a = class { public p = 10; };","signature":"1aa32af20adf1f5d970642bd31541eeb-export declare const a: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1},{"version":"dc7165893e9c62cfeea6f0fad1d8b57c-export const c = class { public p = 10; };","signature":"17c24c6640bff8629aa96eed43575ace-export declare const c: {\n new (): {\n p: number;\n };\n};\n","impliedNodeFormat":1},{"version":"eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };","signature":"9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n","impliedNodeFormat":1}],"options":{"declaration":true,"declarationMap":true},"emitDiagnosticsPerFile":[[5,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["d"]}]}]]],"affectedFilesPendingEmit":[[2,49],[3,48],[4,49],[5,48]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -1506,11 +1596,11 @@ Found 1 error in d.ts:1 { "fileName": "./d.ts", "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": "CommonJS", "original": { "version": "eee493071f513e65e5368e45a4d35584-export const d = class { private p = 10; };", - "signature": "da46c64a7214d458d5aad6924e4d69d3-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(13,1): error9027: Add a type annotation to the variable d.", + "signature": "9bb613afbef9c5e40a1cbd833df92c7f-export declare const d: {\n new (): {\n p: number;\n };\n};\n\n(13,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(13,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\nd\n", "impliedNodeFormat": 1 } } @@ -1528,14 +1618,20 @@ Found 1 error in d.ts:1 "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable d." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "d" + ] } ] } @@ -1576,7 +1672,7 @@ Found 1 error in d.ts:1 ] ] ], - "size": 2318 + "size": 2386 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/dts-errors-with-incremental-as-modules.js b/testdata/baselines/reference/tsc/noEmit/dts-errors-with-incremental-as-modules.js index 0813159493..eac12bb8a9 100644 --- a/testdata/baselines/reference/tsc/noEmit/dts-errors-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsc/noEmit/dts-errors-with-incremental-as-modules.js @@ -29,7 +29,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"9c1fc7106f3a21aadb5219db8b3209bc-export const a = class { private p = 10; };","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":13,"end":14,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -88,14 +88,20 @@ Found 1 error in a.ts:1 "end": 14, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 13, "end": 14, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -120,7 +126,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1368 + "size": 1420 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -403,7 +409,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -440,12 +446,12 @@ Found 1 error in a.ts:1 { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -474,14 +480,20 @@ Found 1 error in a.ts:1 "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -498,7 +510,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1795 + "size": 1863 } tsconfig.json:: @@ -539,7 +551,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;","signature":"eaed5dafb4668e1b7c86b65b584b776a-export declare const b = 10;\n","impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -576,12 +588,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -610,21 +622,27 @@ const a = class { "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1759 + "size": 1827 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/dts-errors-with-incremental.js b/testdata/baselines/reference/tsc/noEmit/dts-errors-with-incremental.js index 21f7e2d3af..26f97a2be5 100644 --- a/testdata/baselines/reference/tsc/noEmit/dts-errors-with-incremental.js +++ b/testdata/baselines/reference/tsc/noEmit/dts-errors-with-incremental.js @@ -27,7 +27,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -81,14 +81,20 @@ Found 1 error in a.ts:1 "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -105,7 +111,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1341 + "size": 1393 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -344,7 +350,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -376,12 +382,12 @@ Found 1 error in a.ts:1 { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -399,14 +405,20 @@ Found 1 error in a.ts:1 "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -423,7 +435,7 @@ Found 1 error in a.ts:1 ] ] ], - "size": 1614 + "size": 1682 } tsconfig.json:: @@ -464,7 +476,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":true},"emitDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":6,"end":7,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -496,12 +508,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -519,21 +531,27 @@ const a = class { "end": 7, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 6, "end": 7, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } ] ] ], - "size": 1578 + "size": 1646 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js b/testdata/baselines/reference/tsc/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js index ad330475c2..57fd7cf970 100644 --- a/testdata/baselines/reference/tsc/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsc/noEmit/dts-errors-without-dts-enabled-with-incremental-as-modules.js @@ -320,7 +320,7 @@ tsgo --noEmit ExitStatus:: Success Output:: //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -357,12 +357,12 @@ Output:: { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -384,7 +384,7 @@ Output:: 2 ] ], - "size": 1393 + "size": 1409 } tsconfig.json:: @@ -406,7 +406,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false}} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false}} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -443,12 +443,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -463,7 +463,7 @@ const a = class { "options": { "declaration": false }, - "size": 1362 + "size": 1378 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/dts-errors-without-dts-enabled-with-incremental.js b/testdata/baselines/reference/tsc/noEmit/dts-errors-without-dts-enabled-with-incremental.js index e75cb2871d..253723134b 100644 --- a/testdata/baselines/reference/tsc/noEmit/dts-errors-without-dts-enabled-with-incremental.js +++ b/testdata/baselines/reference/tsc/noEmit/dts-errors-without-dts-enabled-with-incremental.js @@ -276,7 +276,7 @@ tsgo --noEmit ExitStatus:: Success Output:: //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -308,12 +308,12 @@ Output:: { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -329,7 +329,7 @@ Output:: 2 ] ], - "size": 1324 + "size": 1340 } tsconfig.json:: @@ -351,7 +351,7 @@ const a = class { }; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false}} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };","signature":"e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false}} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -383,12 +383,12 @@ const a = class { { "fileName": "./a.ts", "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": "CommonJS", "original": { "version": "54435c7adb578d59d7e39dd2f567250e-const a = class { private p = 10; };", - "signature": "26341e8dc85f0d296deed3b6fe76a0dd-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property 'p' of exported anonymous class type may not be private or protected.\n(6,1): error9027: Add a type annotation to the variable a.", + "signature": "e4289913a1e3c6021f5a6745f65d4044-declare const a: {\n new (): {\n p: number;\n };\n};\n\n(6,1): error4094: Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094\np\n\n(6,1): error9027: Add_a_type_annotation_to_the_variable_0_9027\na\n", "affectsGlobalScope": true, "impliedNodeFormat": 1 } @@ -397,7 +397,7 @@ const a = class { "options": { "declaration": false }, - "size": 1293 + "size": 1309 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/semantic-errors-with-incremental-as-modules.js b/testdata/baselines/reference/tsc/noEmit/semantic-errors-with-incremental-as-modules.js index 549ea01b34..8a0748882c 100644 --- a/testdata/baselines/reference/tsc/noEmit/semantic-errors-with-incremental-as-modules.js +++ b/testdata/baselines/reference/tsc/noEmit/semantic-errors-with-incremental-as-modules.js @@ -25,7 +25,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"a49e791c9509caf97ef39f9e765d5015-export const a: number = \"hello\"","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2,3]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"a49e791c9509caf97ef39f9e765d5015-export const a: number = \"hello\"","907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2,3]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -84,7 +84,11 @@ Found 1 error in a.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -101,7 +105,7 @@ Found 1 error in a.ts:1 3 ] ], - "size": 1204 + "size": 1231 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -358,7 +362,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -424,7 +428,11 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -436,7 +444,7 @@ Found 1 error in a.ts:1 2 ] ], - "size": 1327 + "size": 1354 } tsconfig.json:: @@ -464,7 +472,7 @@ Found 1 error in a.ts:1 const a = "hello"; //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1},"907abc8137ceb88f0ddd6eccfa92d573-export const b = 10;"],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -530,12 +538,16 @@ const a = "hello"; "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1296 + "size": 1323 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmit/semantic-errors-with-incremental.js b/testdata/baselines/reference/tsc/noEmit/semantic-errors-with-incremental.js index d8d37eb0bb..2ef820b080 100644 --- a/testdata/baselines/reference/tsc/noEmit/semantic-errors-with-incremental.js +++ b/testdata/baselines/reference/tsc/noEmit/semantic-errors-with-incremental.js @@ -23,7 +23,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -77,7 +77,11 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -89,7 +93,7 @@ Found 1 error in a.ts:1 2 ] ], - "size": 1184 + "size": 1211 } //// [/home/src/tslibs/TS/Lib/lib.d.ts] *Lib* /// @@ -314,7 +318,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -369,7 +373,11 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] @@ -381,7 +389,7 @@ Found 1 error in a.ts:1 2 ] ], - "size": 1258 + "size": 1285 } tsconfig.json:: @@ -407,7 +415,7 @@ Found 1 error in a.ts:1 //// [/home/src/projects/project/a.js] *rewrite with same content* //// [/home/src/projects/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type 'string' is not assignable to type 'number'."}]]]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","./a.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"903d9216256112700b1325b61dcb7717-const a: number = \"hello\"","signature":"a87bf21f13058d40be607df702228523-declare const a: number;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"declaration":false},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["string","number"]}]]]} //// [/home/src/projects/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -462,12 +470,16 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type 'string' is not assignable to type 'number'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "string", + "number" + ] } ] ] ], - "size": 1227 + "size": 1254 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmitOnError/dts-errors-with-declaration-with-incremental.js b/testdata/baselines/reference/tsc/noEmitOnError/dts-errors-with-declaration-with-incremental.js index 9ad5ae42c0..60737ba2d2 100644 --- a/testdata/baselines/reference/tsc/noEmitOnError/dts-errors-with-declaration-with-incremental.js +++ b/testdata/baselines/reference/tsc/noEmitOnError/dts-errors-with-declaration-with-incremental.js @@ -60,7 +60,7 @@ interface Symbol { } declare const console: { log(msg: any): void; }; //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":53,"end":54,"code":4094,"category":1,"message":"Property 'p' of exported anonymous class type may not be private or protected.","relatedInformation":[{"pos":53,"end":54,"code":9027,"category":1,"message":"Add a type annotation to the variable a."}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17],[4,17]]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","6cc24027429965f7fa7493c1b9efd532-import { A } from \"../shared/types/db\";\nexport const a = class { private p = 10; };","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"emitDiagnosticsPerFile":[[3,[{"pos":53,"end":54,"code":4094,"category":1,"messageKey":"Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094","messageArgs":["p"],"relatedInformation":[{"pos":53,"end":54,"code":9027,"category":1,"messageKey":"Add_a_type_annotation_to_the_variable_0_9027","messageArgs":["a"]}]}]]],"affectedFilesPendingEmit":[[2,17],[3,17],[4,17]]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -139,14 +139,20 @@ declare const console: { log(msg: any): void; }; "end": 54, "code": 4094, "category": 1, - "message": "Property 'p' of exported anonymous class type may not be private or protected.", + "messageKey": "Property_0_of_exported_anonymous_class_type_may_not_be_private_or_protected_4094", + "messageArgs": [ + "p" + ], "relatedInformation": [ { "pos": 53, "end": 54, "code": 9027, "category": 1, - "message": "Add a type annotation to the variable a." + "messageKey": "Add_a_type_annotation_to_the_variable_0_9027", + "messageArgs": [ + "a" + ] } ] } @@ -179,7 +185,7 @@ declare const console: { log(msg: any): void; }; ] ] ], - "size": 1628 + "size": 1680 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmitOnError/file-deleted-before-fixing-error-with-noEmitOnError.js b/testdata/baselines/reference/tsc/noEmitOnError/file-deleted-before-fixing-error-with-noEmitOnError.js index 68b5044997..4cf35eb31a 100644 --- a/testdata/baselines/reference/tsc/noEmitOnError/file-deleted-before-fixing-error-with-noEmitOnError.js +++ b/testdata/baselines/reference/tsc/noEmitOnError/file-deleted-before-fixing-error-with-noEmitOnError.js @@ -48,7 +48,7 @@ interface Symbol { } declare const console: { log(msg: any): void; }; //// [/home/src/workspaces/project/outDir/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","../file1.ts","../file2.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"15ec141484c003c242081ba307fd0794-export const x: 30 = \"hello\";","f7d221ab360f516a6280e3b725f4cd31-export class D { }"],"options":{"noEmitOnError":true,"outDir":"./"},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type '\"hello\"' is not assignable to type '30'."}]]],"affectedFilesPendingEmit":[2,3]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","../file1.ts","../file2.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"15ec141484c003c242081ba307fd0794-export const x: 30 = \"hello\";","f7d221ab360f516a6280e3b725f4cd31-export class D { }"],"options":{"noEmitOnError":true,"outDir":"./"},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["\"hello\"","30"]}]]],"affectedFilesPendingEmit":[2,3]} //// [/home/src/workspaces/project/outDir/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -108,7 +108,11 @@ declare const console: { log(msg: any): void; }; "end": 14, "code": 2322, "category": 1, - "message": "Type '\"hello\"' is not assignable to type '30'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "\"hello\"", + "30" + ] } ] ] @@ -125,7 +129,7 @@ declare const console: { log(msg: any): void; }; 3 ] ], - "size": 1223 + "size": 1250 } tsconfig.json:: @@ -151,7 +155,7 @@ Output:: Found 1 error in file1.ts:1 //// [/home/src/workspaces/project/outDir/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","../file1.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"15ec141484c003c242081ba307fd0794-export const x: 30 = \"hello\";"],"options":{"noEmitOnError":true,"outDir":"./"},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"message":"Type '\"hello\"' is not assignable to type '30'."}]]],"affectedFilesPendingEmit":[2]} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","../file1.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"15ec141484c003c242081ba307fd0794-export const x: 30 = \"hello\";"],"options":{"noEmitOnError":true,"outDir":"./"},"semanticDiagnosticsPerFile":[[2,[{"pos":13,"end":14,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["\"hello\"","30"]}]]],"affectedFilesPendingEmit":[2]} //// [/home/src/workspaces/project/outDir/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -200,7 +204,11 @@ Found 1 error in file1.ts:1 "end": 14, "code": 2322, "category": 1, - "message": "Type '\"hello\"' is not assignable to type '30'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "\"hello\"", + "30" + ] } ] ] @@ -212,7 +220,7 @@ Found 1 error in file1.ts:1 2 ] ], - "size": 1149 + "size": 1176 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmitOnError/semantic-errors-with-declaration-with-incremental.js b/testdata/baselines/reference/tsc/noEmitOnError/semantic-errors-with-declaration-with-incremental.js index 19e0e565e2..ffc2b7b649 100644 --- a/testdata/baselines/reference/tsc/noEmitOnError/semantic-errors-with-declaration-with-incremental.js +++ b/testdata/baselines/reference/tsc/noEmitOnError/semantic-errors-with-declaration-with-incremental.js @@ -56,7 +56,7 @@ interface Symbol { } declare const console: { log(msg: any): void; }; //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"affectedFilesPendingEmit":[2,3,4]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":true,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"affectedFilesPendingEmit":[2,3,4]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -135,7 +135,11 @@ declare const console: { log(msg: any): void; }; "end": 47, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] @@ -157,7 +161,7 @@ declare const console: { log(msg: any): void; }; 4 ] ], - "size": 1445 + "size": 1472 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmitOnError/semantic-errors-with-incremental.js b/testdata/baselines/reference/tsc/noEmitOnError/semantic-errors-with-incremental.js index 6720293a58..c826738520 100644 --- a/testdata/baselines/reference/tsc/noEmitOnError/semantic-errors-with-incremental.js +++ b/testdata/baselines/reference/tsc/noEmitOnError/semantic-errors-with-incremental.js @@ -56,7 +56,7 @@ interface Symbol { } declare const console: { log(msg: any): void; }; //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":false,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"message":"Type 'number' is not assignable to type 'string'."}]]],"affectedFilesPendingEmit":[2,3,4]} +{"version":"FakeTSVersion","root":[[2,4]],"fileNames":["lib.d.ts","../shared/types/db.ts","../src/main.ts","../src/other.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"4dba75627964632af83642176cf4b611-export interface A {\n name: string;\n}","21728e732a07c83043db4a93ca54350c-import { A } from \"../shared/types/db\";\nconst a: string = 10;","ac4084c9455da7165ada8cb39f592843-console.log(\"hi\");\nexport { }"],"fileIdsList":[[2]],"options":{"declaration":false,"noEmitOnError":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":46,"end":47,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["number","string"]}]]],"affectedFilesPendingEmit":[2,3,4]} //// [/user/username/projects/noEmitOnError/dev-build/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -135,7 +135,11 @@ declare const console: { log(msg: any): void; }; "end": 47, "code": 2322, "category": 1, - "message": "Type 'number' is not assignable to type 'string'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "number", + "string" + ] } ] ] @@ -157,7 +161,7 @@ declare const console: { log(msg: any): void; }; 4 ] ], - "size": 1446 + "size": 1473 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/noEmitOnError/when-declarationMap-changes.js b/testdata/baselines/reference/tsc/noEmitOnError/when-declarationMap-changes.js index 28ab717dad..47ae7bdf2b 100644 --- a/testdata/baselines/reference/tsc/noEmitOnError/when-declarationMap-changes.js +++ b/testdata/baselines/reference/tsc/noEmitOnError/when-declarationMap-changes.js @@ -149,7 +149,7 @@ Output:: Found 1 error in a.ts:1 //// [/home/src/workspaces/project/tsconfig.tsbuildinfo] *modified* -{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"6792320cbdee0286d2b3e83ff1d9fcc1-const x: 20 = 10;","signature":"c4dd771ef0ee0838482d28bc7dea6269-declare const x: 20;\n","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"4448aee3ffd6eaf52054c6f2413c128a-const y = 10;","signature":"b0061f8cf6b7f4ef02673fae62fc90dd-declare const y = 10;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"noEmitOnError":true},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"message":"Type '10' is not assignable to type '20'."}]]],"affectedFilesPendingEmit":[2,[3,48]],"latestChangedDtsFile":"./b.d.ts","emitSignatures":[[2,["4be7af7f970696121f4f582a5d074177-declare const x = 10;\n"]],[3,[]]]} +{"version":"FakeTSVersion","root":[[2,3]],"fileNames":["lib.d.ts","./a.ts","./b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"6792320cbdee0286d2b3e83ff1d9fcc1-const x: 20 = 10;","signature":"c4dd771ef0ee0838482d28bc7dea6269-declare const x: 20;\n","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"4448aee3ffd6eaf52054c6f2413c128a-const y = 10;","signature":"b0061f8cf6b7f4ef02673fae62fc90dd-declare const y = 10;\n","affectsGlobalScope":true,"impliedNodeFormat":1}],"options":{"composite":true,"declaration":true,"declarationMap":true,"noEmitOnError":true},"semanticDiagnosticsPerFile":[[2,[{"pos":6,"end":7,"code":2322,"category":1,"messageKey":"Type_0_is_not_assignable_to_type_1_2322","messageArgs":["10","20"]}]]],"affectedFilesPendingEmit":[2,[3,48]],"latestChangedDtsFile":"./b.d.ts","emitSignatures":[[2,["4be7af7f970696121f4f582a5d074177-declare const x = 10;\n"]],[3,[]]]} //// [/home/src/workspaces/project/tsconfig.tsbuildinfo.readable.baseline.txt] *modified* { "version": "FakeTSVersion", @@ -225,7 +225,11 @@ Found 1 error in a.ts:1 "end": 7, "code": 2322, "category": 1, - "message": "Type '10' is not assignable to type '20'." + "messageKey": "Type_0_is_not_assignable_to_type_1_2322", + "messageArgs": [ + "10", + "20" + ] } ] ] @@ -267,7 +271,7 @@ Found 1 error in a.ts:1 ] } ], - "size": 1620 + "size": 1647 } tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/projectReferences/issues-a-nice-error-when-the-input-file-is-missing-when-module-reference-is-not-relative.js b/testdata/baselines/reference/tsc/projectReferences/issues-a-nice-error-when-the-input-file-is-missing-when-module-reference-is-not-relative.js index 8175413de0..70775185da 100644 --- a/testdata/baselines/reference/tsc/projectReferences/issues-a-nice-error-when-the-input-file-is-missing-when-module-reference-is-not-relative.js +++ b/testdata/baselines/reference/tsc/projectReferences/issues-a-nice-error-when-the-input-file-is-missing-when-module-reference-is-not-relative.js @@ -66,7 +66,7 @@ export {}; Object.defineProperty(exports, "__esModule", { value: true }); //// [/home/src/workspaces/project/beta/bin/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","../b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"311c3bac923f08ac35ab2246c3464fb7-import { m } from '@alpha/a'","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"options":{"composite":true,"outDir":"./"},"semanticDiagnosticsPerFile":[[2,[{"pos":18,"end":28,"code":6305,"category":1,"message":"Output file '/home/src/workspaces/project/alpha/bin/a.d.ts' has not been built from source file '/home/src/workspaces/project/alpha/a.ts'."}]]],"latestChangedDtsFile":"./b.d.ts"} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","../b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"311c3bac923f08ac35ab2246c3464fb7-import { m } from '@alpha/a'","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"options":{"composite":true,"outDir":"./"},"semanticDiagnosticsPerFile":[[2,[{"pos":18,"end":28,"code":6305,"category":1,"messageKey":"Output_file_0_has_not_been_built_from_source_file_1_6305","messageArgs":["/home/src/workspaces/project/alpha/bin/a.d.ts","/home/src/workspaces/project/alpha/a.ts"]}]]],"latestChangedDtsFile":"./b.d.ts"} //// [/home/src/workspaces/project/beta/bin/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -120,13 +120,17 @@ Object.defineProperty(exports, "__esModule", { value: true }); "end": 28, "code": 6305, "category": 1, - "message": "Output file '/home/src/workspaces/project/alpha/bin/a.d.ts' has not been built from source file '/home/src/workspaces/project/alpha/a.ts'." + "messageKey": "Output_file_0_has_not_been_built_from_source_file_1_6305", + "messageArgs": [ + "/home/src/workspaces/project/alpha/bin/a.d.ts", + "/home/src/workspaces/project/alpha/a.ts" + ] } ] ] ], "latestChangedDtsFile": "./b.d.ts", - "size": 1325 + "size": 1352 } beta/tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/projectReferences/issues-a-nice-error-when-the-input-file-is-missing.js b/testdata/baselines/reference/tsc/projectReferences/issues-a-nice-error-when-the-input-file-is-missing.js index be88f86fa1..913e9640bd 100644 --- a/testdata/baselines/reference/tsc/projectReferences/issues-a-nice-error-when-the-input-file-is-missing.js +++ b/testdata/baselines/reference/tsc/projectReferences/issues-a-nice-error-when-the-input-file-is-missing.js @@ -64,7 +64,7 @@ export {}; Object.defineProperty(exports, "__esModule", { value: true }); //// [/home/src/workspaces/project/beta/bin/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","../b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"fcbf49879e154aae077c688a18cd60c0-import { m } from '../alpha/a'","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"options":{"composite":true,"outDir":"./"},"semanticDiagnosticsPerFile":[[2,[{"pos":18,"end":30,"code":6305,"category":1,"message":"Output file '/home/src/workspaces/project/alpha/bin/a.d.ts' has not been built from source file '/home/src/workspaces/project/alpha/a.ts'."}]]],"latestChangedDtsFile":"./b.d.ts"} +{"version":"FakeTSVersion","root":[2],"fileNames":["lib.d.ts","../b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},{"version":"fcbf49879e154aae077c688a18cd60c0-import { m } from '../alpha/a'","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"options":{"composite":true,"outDir":"./"},"semanticDiagnosticsPerFile":[[2,[{"pos":18,"end":30,"code":6305,"category":1,"messageKey":"Output_file_0_has_not_been_built_from_source_file_1_6305","messageArgs":["/home/src/workspaces/project/alpha/bin/a.d.ts","/home/src/workspaces/project/alpha/a.ts"]}]]],"latestChangedDtsFile":"./b.d.ts"} //// [/home/src/workspaces/project/beta/bin/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -118,13 +118,17 @@ Object.defineProperty(exports, "__esModule", { value: true }); "end": 30, "code": 6305, "category": 1, - "message": "Output file '/home/src/workspaces/project/alpha/bin/a.d.ts' has not been built from source file '/home/src/workspaces/project/alpha/a.ts'." + "messageKey": "Output_file_0_has_not_been_built_from_source_file_1_6305", + "messageArgs": [ + "/home/src/workspaces/project/alpha/bin/a.d.ts", + "/home/src/workspaces/project/alpha/a.ts" + ] } ] ] ], "latestChangedDtsFile": "./b.d.ts", - "size": 1327 + "size": 1354 } beta/tsconfig.json:: diff --git a/testdata/baselines/reference/tsc/projectReferences/redirects-to-the-output-dts-file.js b/testdata/baselines/reference/tsc/projectReferences/redirects-to-the-output-dts-file.js index fad1de3193..af46244a79 100644 --- a/testdata/baselines/reference/tsc/projectReferences/redirects-to-the-output-dts-file.js +++ b/testdata/baselines/reference/tsc/projectReferences/redirects-to-the-output-dts-file.js @@ -72,7 +72,7 @@ export {}; Object.defineProperty(exports, "__esModule", { value: true }); //// [/home/src/workspaces/project/beta/bin/tsconfig.tsbuildinfo] *new* -{"version":"FakeTSVersion","root":[3],"fileNames":["lib.d.ts","../../alpha/bin/a.d.ts","../b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"3145b36c4687eb0550eabb198d0c0d22-export { };",{"version":"fcbf49879e154aae077c688a18cd60c0-import { m } from '../alpha/a'","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"composite":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":9,"end":10,"code":2305,"category":1,"message":"Module '\"../alpha/bin/a\"' has no exported member 'm'."}]]],"latestChangedDtsFile":"./b.d.ts"} +{"version":"FakeTSVersion","root":[3],"fileNames":["lib.d.ts","../../alpha/bin/a.d.ts","../b.ts"],"fileInfos":[{"version":"8859c12c614ce56ba9a18e58384a198f-/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ninterface SymbolConstructor {\n (desc?: string | number): symbol;\n for(name: string): symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true,"impliedNodeFormat":1},"3145b36c4687eb0550eabb198d0c0d22-export { };",{"version":"fcbf49879e154aae077c688a18cd60c0-import { m } from '../alpha/a'","signature":"abe7d9981d6018efb6b2b794f40a1607-export {};\n","impliedNodeFormat":1}],"fileIdsList":[[2]],"options":{"composite":true,"outDir":"./"},"referencedMap":[[3,1]],"semanticDiagnosticsPerFile":[[3,[{"pos":9,"end":10,"code":2305,"category":1,"messageKey":"Module_0_has_no_exported_member_1_2305","messageArgs":["\"../alpha/bin/a\"","m"]}]]],"latestChangedDtsFile":"./b.d.ts"} //// [/home/src/workspaces/project/beta/bin/tsconfig.tsbuildinfo.readable.baseline.txt] *new* { "version": "FakeTSVersion", @@ -143,13 +143,17 @@ Object.defineProperty(exports, "__esModule", { value: true }); "end": 10, "code": 2305, "category": 1, - "message": "Module '\"../alpha/bin/a\"' has no exported member 'm'." + "messageKey": "Module_0_has_no_exported_member_1_2305", + "messageArgs": [ + "\"../alpha/bin/a\"", + "m" + ] } ] ] ], "latestChangedDtsFile": "./b.d.ts", - "size": 1359 + "size": 1386 } beta/tsconfig.json::