Skip to content

Simplify windows::core type traits#2343

Merged
kennykerr merged 5 commits intomasterfrom
type2
Feb 22, 2023
Merged

Simplify windows::core type traits#2343
kennykerr merged 5 commits intomasterfrom
type2

Conversation

@kennykerr
Copy link
Copy Markdown
Collaborator

The type traits used internally by the windows crate for modeling various abstractions and reasoning about how certain types behave have long been somewhat cumbersome due to the inability to express mutually exclusive type traits in Rust. Well, I stumbled upon an approach that can do just that. We can now distinguish between reference and value types, and other potential categories, and provide unique behavior and associated types in a single place. This will take a few iterations to polish, but this is a good start and simplifies a lot of that plumbing considerably.

This work was motivated by my desire to work on #91 but that requires reasoning more clearly about types and so you will also see some much-needed improvements to the way the implement macro generated generic constraints.

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