Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BigInt constructor should not accept any type #38980

Open
LongTengDao opened this issue Jun 8, 2020 · 4 comments · May be fixed by #40877
Open

BigInt constructor should not accept any type #38980

LongTengDao opened this issue Jun 8, 2020 · 4 comments · May be fixed by #40877

Comments

@LongTengDao
Copy link
Contributor

@LongTengDao LongTengDao commented Jun 8, 2020

TypeScript Version: 3.9.3

Search Terms:

Code

Expected behavior:

interface BigIntConstructor {
    (value: string | number | bigint | boolean | object): bigint;
}

Actual behavior:

interface BigIntConstructor {
    (value?: any): bigint;
}

Playground Link:

Related Issues:

@DanielRosenwasser
Copy link
Member

@DanielRosenwasser DanielRosenwasser commented Jun 8, 2020

I think a PR would be a good start to a discussion. We could then run it on a few code suites and see what breaks.

@DanielRosenwasser DanielRosenwasser added this to the Backlog milestone Jun 8, 2020
@idankash
Copy link

@idankash idankash commented Jun 9, 2020

Hey,
I'd love to open a PR and work on it if it's ok. :)

@dy-fi
Copy link

@dy-fi dy-fi commented Jul 14, 2020

I will submit a PR on this if it's still open

@LongTengDao
Copy link
Contributor Author

@LongTengDao LongTengDao commented Jul 15, 2020

I will submit a PR on this if it's still open

@dy-fi There is already #38995. Don't know why it's still not merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants