Skip to content

Conversation

@guylamar2006
Copy link
Contributor

If the type of is_press changes in the future, the as cast may not handle the conversion safely and could introduce silent bugs.

i32::from: Using i32::from ensures that the conversion is handled safely and explicitly, making it more robust against future changes.

If the type of is_press changes in the future, the as cast may not handle the conversion safely and could introduce silent bugs.

i32::from: Using i32::from ensures that the conversion is handled safely and explicitly, making it more robust against future changes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant