-
Notifications
You must be signed in to change notification settings - Fork 13k
Closed
Labels
Working as IntendedThe behavior described is the intended behavior; this is not a bugThe behavior described is the intended behavior; this is not a bug
Description
Bug Report
π Search Terms
TS5055
π Version & Regression Information
- This is a crash
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about TS5055
- I reproduced this using TypeScript 4.4 and TypeScript 5.
β― Playground Link
N/A
π» Code
// index.js
// Modifying anything, for example editing this comment, will cause the issue.
π Actual behavior
Run the following
$ # Run thow however many times you like
$ tsc --build
$ tsc --build
$ tsc --build
$ tsc --build
$ tsc --build
$ tsc --build
$ tsc --build
$ tsc --build
$ # Can also be reproduced by adding this to tsconfig.json instead.
$ echo '//comment' >> index.js
$ tsc --build
error TS5055: Cannot write file '/home/remco/Downloads/asd/index.d.ts' because it would overwrite input file.
Found 1 error.
Without the --build
flag this happens regardless of any previous modifications.
To recover, run:
tsc --build --clean
π Expected behavior
Consistency. Itβs currently not clear if one is supposed to exclude *.d.ts
or not.
Metadata
Metadata
Assignees
Labels
Working as IntendedThe behavior described is the intended behavior; this is not a bugThe behavior described is the intended behavior; this is not a bug