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-lib: Add support for QUuid #1149

Merged
merged 19 commits into from
Jan 14, 2025
Merged

cxx-qt-lib: Add support for QUuid #1149

merged 19 commits into from
Jan 14, 2025

Conversation

jnbooth
Copy link
Contributor

@jnbooth jnbooth commented Dec 25, 2024

Adds a shared type for QUuid, which can optionally be converted to and from the type provided by the uuid crate. Since it's expensive to convert between Strings and QStrings, QUuids provide a convenient no-allocation alternative for identifiers.

@redstrate
Copy link
Contributor

This looks pretty in-depth, thanks! I think this is definitely worthy of a mention in CHANGELOG.md, you should add it there in this PR.

I also started up the CI workflow, so we can see if that succeeds.

crates/cxx-qt-lib/src/core/quuid.rs Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.rs Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.cpp Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/qset/qset_quuid.rs Show resolved Hide resolved
crates/cxx-qt-lib/include/core/quuid.h Outdated Show resolved Hide resolved
Copy link

codecov bot commented Jan 10, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (1f72cdd) to head (ec120fe).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #1149   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           71        71           
  Lines        11967     11967           
=========================================
  Hits         11967     11967           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

crates/cxx-qt-lib/src/core/quuid.rs Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.cpp Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.cpp Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.rs Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.rs Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.rs Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.rs Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.rs Outdated Show resolved Hide resolved
crates/cxx-qt-lib/src/core/quuid.rs Outdated Show resolved Hide resolved
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.

Hi @jnbooth ,
thank you for taking the time to work on this.
UUIDs are an important topic and having QUuid in cxx-qt-lib would be great!

I have left some minor nitpicks, but the most important problem is going to be Qt5 support, as QAnyStringView isn't supported on Qt5.
For now I'm okay to only support QString so we can merge this PR earlier.

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.

Thank you for the contribution @jnbooth 🎉

@LeonMatthesKDAB LeonMatthesKDAB merged commit e84662a into KDAB:main Jan 14, 2025
16 checks passed
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.

3 participants