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

Add a check for using casts for Float -> Int conversion #88

Open
Gama11 opened this issue Mar 1, 2016 · 0 comments
Open

Add a check for using casts for Float -> Int conversion #88

Gama11 opened this issue Mar 1, 2016 · 0 comments

Comments

@Gama11
Copy link
Member

Gama11 commented Mar 1, 2016

For the sake of type safety, it's best practice to use Std.int() to convert Float to Int. It would be nice if a check could detect cases where this is done with cast (both the safe and the unsafe variant) - from my experience this is a common beginner mistake.

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