Proc macro to derive ApproxEq? #21

Open
opened 2019-11-21 04:21:15 +13:00 by swiftcoder · 1 comment
swiftcoder commented 2019-11-21 04:21:15 +13:00 (Migrated from github.com)

It would be very convenient to be able to #[derive(ApproxEq)] on structs (much like one does with PartialEq). Would you see that a proc-macro crate for that fitting within the scope of float-cmp itself?

It would be very convenient to be able to `#[derive(ApproxEq)]` on structs (much like one does with PartialEq). Would you see that a proc-macro crate for that fitting within the scope of float-cmp itself?
mikedilger commented 2019-11-21 09:54:25 +13:00 (Migrated from github.com)

That sounds like a great idea. I've never written a proc-macro so it's completely unknown territory for me, and I wouldn't be able to get to it right away, but I think yes it should be done.

That sounds like a great idea. I've never written a proc-macro so it's completely unknown territory for me, and I wouldn't be able to get to it right away, but I think yes it should be done.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
mikedilger/float-cmp#21
No description provided.