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

Compilation fails with Rust 1.72 #299

Closed
direc85 opened this issue Aug 27, 2023 · 2 comments
Closed

Compilation fails with Rust 1.72 #299

direc85 opened this issue Aug 27, 2023 · 2 comments

Comments

@direc85
Copy link
Contributor

direc85 commented Aug 27, 2023

error[E0512]: cannot transmute between types of different sizes, or dependently-sized types
   --> qmetaobject/src/scenegraph.rs:158:32
    |
158 |             raw = cpp!(unsafe [type_id as "quint64", len as "std::size_t"] -> *mut c_void as "QSGNode*" {
    |                                ^^^^^^^
    |
    = note: source type: `TypeId` (128 bits)
    = note: target type: `[u8; 8]` (64 bits)
    = note: this error originates in the macro `__cpp_closure_impl` which comes from the expansion of the macro `cpp` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0512]: cannot transmute between types of different sizes, or dependently-sized types
   --> qmetaobject/src/scenegraph.rs:163:58
    |
163 |             mask = cpp!(unsafe [raw as "ContainerNode*", type_id as "quint64", len as "std::size_t"] -> u64 as "quint64" {
    |                                                          ^^^^^^^
    |
    = note: source type: `TypeId` (128 bits)
    = note: target type: `[u8; 8]` (64 bits)
    = note: this error originates in the macro `__cpp_closure_impl` which comes from the expansion of the macro `cpp` (in Nightly builds, run with -Z macro-backtrace for more info)
(...)

This is caused by Rust 1.72 change Use 128 bits for TypeId hash

@direc85 direc85 changed the title Compilation failes with Rust 1.72 Compilation fails with Rust 1.72 Aug 27, 2023
@ogoffart
Copy link
Member

This is strange. I thought commit 947a73b which is included in the version 0.2.9 of the crate would have fixed that already

@direc85
Copy link
Contributor Author

direc85 commented Aug 27, 2023

Ah, indeed it does. I'm trying to compile Whisperfish, which is stuck around 0.2.5, so this bug is irrelevant - and so is the merge request.

@direc85 direc85 closed this as completed Aug 27, 2023
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 a pull request may close this issue.

2 participants