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

Implicit conversion - buitins #2

Open
cnewman opened this issue Jul 15, 2017 · 0 comments
Open

Implicit conversion - buitins #2

cnewman opened this issue Jul 15, 2017 · 0 comments
Assignees

Comments

@cnewman
Copy link
Member

cnewman commented Jul 15, 2017

Currently, srcType can handle some implicit conversions between built-in types and between string literals and string.

However, it could be better at it. Right now, it won't resolve strictly. Example:

Foo(int, double)
Foo(double, double)

are both candidates for a call matching: Foo(1, 2.0) even though the first call is clearly the more appropriate. Need to enable strict matching by scanning the literal beforehand and guessing if it is an int or double or float or long, etc.

Problem is going to be handling things that aren't easy to do heuristically. I.e., an int literal can be converted to a long but still look like an int.

@cnewman cnewman self-assigned this Jul 15, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant