Skip to content

--noUnusedParameters does not work good enough #9860

@KnisterPeter

Description

@KnisterPeter

TypeScript Version: 2.0.0

Code

function fn(p1: any, p2: any): void {
  return p2;
}

Expected behavior:
This should compile even with --noUnusedParameters

Actual behavior:
Fails when p1 is unused.

Since this is method signature and callside may not be possible to fix this, the compiler should only flag unused from the end.

Metadata

Metadata

Assignees

No one assigned

    Labels

    DuplicateAn existing issue was already created

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions