Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion crates/cxx-qt-lib/src/core/qanystringview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
// https://code.qt.io/cgit/qt/qtbase.git/tree/src/corelib/text/qanystringview.h
assert_alignment_and_size(QAnyStringView, {
::std::size_t a0;
void* a1;
::std::size_t a1;
});

static_assert(::std::is_trivially_copy_assignable<QAnyStringView>::value);
Expand Down
5 changes: 2 additions & 3 deletions crates/cxx-qt-lib/src/core/qanystringview.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
//
// SPDX-License-Identifier: MIT OR Apache-2.0
use crate::{QByteArray, QString};
use core::ffi::c_void;
use core::marker::PhantomData;
use core::mem::MaybeUninit;
use cxx::{type_id, ExternType};
Expand Down Expand Up @@ -72,8 +71,8 @@ mod ffi {
#[repr(C)]
pub struct QAnyStringView<'a> {
/// `QAnyStringView` has two members, a pointer and a `size_t`
_space: MaybeUninit<[usize; 1]>,
_space2: MaybeUninit<[c_void; 1]>,
_data: MaybeUninit<usize>,
_size: MaybeUninit<isize>,

/// Needed to keep the lifetime in check
_phantom: PhantomData<&'a usize>,
Expand Down
Loading