diff --git a/50538.d.ts b/50538.d.ts new file mode 100644 index 0000000..bdf2683 --- /dev/null +++ b/50538.d.ts @@ -0,0 +1,13 @@ +// https://github.com/microsoft/TypeScript/pull/50538 + +declare module "main" { + export const main: ({ conflict }: { + conflict: number; + }, { conflict }: { + conflict: number; + }, { dupe, dupe }: { + dupe: number; + }, { function: e }: { + function: number; + }) => number; +} diff --git a/README.md b/README.md index 885078c..3be33ff 100644 --- a/README.md +++ b/README.md @@ -6,24 +6,12 @@ npm install ```shell npm run build - -# > build -# > npm run --quiet build --workspaces -# -# -# > build -# > tsc --declaration --emitDeclarationOnly --outfile ../4.7.4.d.ts ../main.ts -# -# > build -# > tsc --declaration --emitDeclarationOnly --outfile ../4.8.3.d.ts ../main.ts ``` ```shell -npm run lint +npm run --silent lint 4.7.4.d.ts -# > lint -# > tsc --noEmit *.d.ts -# +npm run --silent lint 4.8.3.d.ts # 4.8.3.d.ts:8:19 - error TS1005: ':' expected. # # 8 }, { function }: { @@ -31,4 +19,28 @@ npm run lint # # # Found 1 error in 4.8.3.d.ts:8 + +npm run --silent lint 50538.d.ts +# 50538.d.ts:4:27 - error TS2300: Duplicate identifier 'conflict'. +# +# 4 export const main: ({ conflict }: { +# ~~~~~~~~ +# +# 50538.d.ts:6:10 - error TS2300: Duplicate identifier 'conflict'. +# +# 6 }, { conflict }: { +# ~~~~~~~~ +# +# 50538.d.ts:8:10 - error TS2300: Duplicate identifier 'dupe'. +# +# 8 }, { dupe, dupe }: { +# ~~~~ +# +# 50538.d.ts:8:16 - error TS2300: Duplicate identifier 'dupe'. +# +# 8 }, { dupe, dupe }: { +# ~~~~ +# +# +# Found 4 errors in the same file, starting at: 50538.d.ts:4 ``` diff --git a/package.json b/package.json index dafe660..cf8de50 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "scripts": { "build": "npm run build --workspaces", - "lint": "tsc --noEmit *.d.ts" + "lint": "tsc --noEmit" }, "workspaces": [ "4.7.4",