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

Make --derive more flexible #237

Merged
merged 21 commits into from
May 1, 2024
Merged

Make --derive more flexible #237

merged 21 commits into from
May 1, 2024

Commits on Apr 29, 2024

  1. Always generate PartialEq, Eq, PartialOrd & Ord for enums

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 29, 2024
    Configuration menu
    Copy the full SHA
    b0fa42f View commit details
    Browse the repository at this point in the history
  2. Constraint automatic enum PartialEq, Eq, PartialOrd & Ord derives to …

    …enums with only simple members.
    
    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 29, 2024
    Configuration menu
    Copy the full SHA
    4c7c200 View commit details
    Browse the repository at this point in the history

Commits on Apr 30, 2024

  1. Implement --derive flag as discussed in #231

    Fixes #231
    
    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    a0c0733 View commit details
    Browse the repository at this point in the history
  2. Include link to Rust enumeration reference for information on unit-on…

    …ly enums
    
    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    b36c66f View commit details
    Browse the repository at this point in the history
  3. Maintain ordering of conditionals

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    2732c4a View commit details
    Browse the repository at this point in the history
  4. several -> three

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    d23b130 View commit details
    Browse the repository at this point in the history
  5. One example is plenty

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    42152f3 View commit details
    Browse the repository at this point in the history
  6. Merge updated main

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    66aae3c View commit details
    Browse the repository at this point in the history
  7. No need to construct a vec just to re-construct another

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    bfeaac1 View commit details
    Browse the repository at this point in the history
  8. Simplify trait target translation

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    bbaf1f9 View commit details
    Browse the repository at this point in the history
  9. Update src/main.rs

    Co-authored-by: Eirik A <sszynrae@gmail.com>
    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius and clux committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    89cef67 View commit details
    Browse the repository at this point in the history
  10. Implement parse_derive in terms of FromStr

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    1d03d22 View commit details
    Browse the repository at this point in the history
  11. Refactor derive into its own module

    Fix trait derivation for structs (proving the need for tests)
    
    Re-add @clux's vec/clone refactor to reduce allocation
    
    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    24185c0 View commit details
    Browse the repository at this point in the history
  12. Sort out the logic around applicability and apply tests

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    d8c7580 View commit details
    Browse the repository at this point in the history
  13. Throw in a named enum just for completeness sake

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    53b476c View commit details
    Browse the repository at this point in the history
  14. Test Derive construction

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    6e30580 View commit details
    Browse the repository at this point in the history
  15. Hide test befind cfg(test)

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    ca3051c View commit details
    Browse the repository at this point in the history
  16. Rename DeriveTarget to Target and make private

    Co-authored-by: Eirik A <sszynrae@gmail.com>
    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius and clux committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    625b5d3 View commit details
    Browse the repository at this point in the history
  17. Complete renaming of DeriveTarget to Target

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed Apr 30, 2024
    Configuration menu
    Copy the full SHA
    7198c82 View commit details
    Browse the repository at this point in the history

Commits on May 1, 2024

  1. Fix table alignment after rename of DeriveTarget -> Target

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed May 1, 2024
    Configuration menu
    Copy the full SHA
    e9dcc43 View commit details
    Browse the repository at this point in the history
  2. Fix table layouting when viewed in docs

    Signed-off-by: Mathias Pius <contact@pius.io>
    MathiasPius committed May 1, 2024
    Configuration menu
    Copy the full SHA
    52e4d19 View commit details
    Browse the repository at this point in the history