Skip to content

Function overloaded with different string literals causes duplicate function #174

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

Closed
epabst opened this issue Nov 8, 2018 · 0 comments
Closed
Labels
ir-target causes problems with IR compilation ts2kt questions migrated from ts2kt unusable-code kotlin code is generated, can be compiled but actually is unusable
Milestone

Comments

@epabst
Copy link

epabst commented Nov 8, 2018

Example:

declare function foo(s: "number"): number;
declare function foo(s: "string"): string;

results in:

external fun foo(s: String /* "number" */): Number = definedExternally
external fun foo(s: String /* "string" */): String = definedExternally

but it should be:

external fun foo(s: String /* "number" | "string" */): dynamic = definedExternally
@Schahen Schahen transferred this issue from Kotlin/ts2kt Nov 5, 2019
@Schahen Schahen added the ts2kt questions migrated from ts2kt label Nov 5, 2019
@Schahen Schahen added the unusable-code kotlin code is generated, can be compiled but actually is unusable label May 29, 2020
@Schahen Schahen added this to the 0.5.1 milestone May 29, 2020
@Schahen Schahen added the ir-target causes problems with IR compilation label Jun 3, 2020
@Schahen Schahen closed this as completed Jun 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ir-target causes problems with IR compilation ts2kt questions migrated from ts2kt unusable-code kotlin code is generated, can be compiled but actually is unusable
Projects
None yet
Development

No branches or pull requests

2 participants