Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Type width in error messages#1099

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Draft
bjatkin wants to merge3 commits intomicrosoft:main
base:main
Choose a base branch
Loading
frombjatkin:typeWidthInErrorMessages

Conversation

bjatkin
Copy link

@bjatkinbjatkin commentedJun 8, 2025
edited
Loading

Fixesmicrosoft/TypeScript#45896

Currently the complier will print "... is not assignable..." errors on a single line

prettyFormatLongTypes.ts: - error TS2882: Type '{ b: { c: { e: { f: string; }; }; }; }' is not assignable to type '{ b: { c: { e: { f: number; }; }; }; }' The types of 'b.c.e.f' are incompatible between these types.    Type 'string' is not assignable to type 'number'.

This PR puts types onto their own lines when they are >30 characters in length

prettyFormatLongTypes.ts: - error TS2882: Type:  { b: { c: { e: { f: string; }; }; }; }is not assignable to type:  { b: { c: { e: { f: number; }; }; }; }  The types of 'b.c.e.f' are incompatible between these types.    Type 'string' is not assignable to type 'number'.

This PR is the typescrpt-go version of this PRmicrosoft/TypeScript#61829

@jakebailey
Copy link
Member

I'm going to mark this as a draft. I don't think we've accepted this feature, and the direction of new features like this needs to be from the TypeScript repo into this one.

@jakebaileyjakebailey marked this pull request as draftJune 26, 2025 17:58
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

Use the width of a type to add newlines in type assignment error messages
2 participants
@bjatkin@jakebailey

[8]ページ先頭

©2009-2025 Movatter.jp