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

cxx-qt-gen: change rust_mut to be safe and remove field generation #585

Merged
merged 5 commits into from
Jun 21, 2023

Conversation

ahayzen-kdab
Copy link
Collaborator

Related to #559

Related to #583

As we move qproperty to an attribute we need to disable generating
helpers for fields as we won't be able to find them when the struct
is outside the bridge.

There are three options going forwards
- let the developer create their own getters/setters (this commit)
- add a #[field(T, NAME)] as an attribute to the qobject later
- remove the (un)safe for qproperty with notify so that rust_mut is safe

Related to KDAB#559
@ahayzen-kdab ahayzen-kdab force-pushed the 559-allow-field-access-safely branch from d018985 to 10c80e1 Compare June 13, 2023 13:50
As rust_mut is now safe.

Related to KDAB#559
@ahayzen-kdab ahayzen-kdab added the 🥳🎉 1.0 This issue is part of stabilization for 1.0 release label Jun 13, 2023
@ahayzen-kdab ahayzen-kdab marked this pull request as ready for review June 21, 2023 12:32
Copy link
Collaborator

@LeonMatthesKDAB LeonMatthesKDAB left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@ahayzen-kdab ahayzen-kdab merged commit 386a7aa into KDAB:main Jun 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🥳🎉 1.0 This issue is part of stabilization for 1.0 release
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants