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

Derive FloatUlps #9

Closed
3 of 4 tasks
jtempest opened this issue Jun 7, 2020 · 1 comment
Closed
3 of 4 tasks

Derive FloatUlps #9

jtempest opened this issue Jun 7, 2020 · 1 comment

Comments

@jtempest
Copy link
Owner

jtempest commented Jun 7, 2020

Part one of deriving traits:

#[derive(FloatUlps)]
struct Foo {
    a: f32,
    b: [f64; 2],
}

Should expand to:

struct __FloatUlps_Foo {
    a: Ulps<f32>,
    b: Ulps<[f64; 2]>,
}

impl float_eq::FloatUlps for Foo {
    type Ulps = __FloatUlps_Foo;
}

Check that this works for:

  • Empty tuple struct
  • Tuple struct
  • Named field struct
  • Struct with generic fields
@jtempest jtempest added enhancement New feature or request and removed enhancement New feature or request labels Jun 12, 2020
@jtempest
Copy link
Owner Author

Implemented for all but generic structs in 4cfdcad

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

No branches or pull requests

1 participant