-
Notifications
You must be signed in to change notification settings - Fork 20
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
Improve RXingResultPoint usage #13
Conversation
Previously, the struct was passed around everywhere as a reference. It only holds two floats, so there's no real need for indirection. Now it's being passed as a value.
Build fails because the OneDReader proc macro expects that a RXingResultPoint type exists.
Currently it's not possible to rename RXingResultPoint to Point cleanly, since the external OneDReader proc macro makes use of them. For the time being, simple aliases are introduced to get the code to compile, but the plan is to remove them at a later point.
Shorter than writing `Point::new`
Point already has `x` and `y` properties, so accessing them with `getX()` and `getY()` is needlessly verbose. These calls have been removed, though the trait impl is still presen for the time being, since the OneDReader proc macro requires it.
@hschimke I think this might be a good point for a review and maybe a merge if everything looks good. There's still more that can be worked on, but I feel like there's enough improvement here that it's worth merging it and adding more with another PR. Here's what this PR includes:
|
I'll review this evening. For reference: it's just now morning for me. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed the code and everything looks good. CI passed.
This looks great, I passed review, I will merge in the morning. Thanks for your hard work! |
Closes #12