mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-20 20:43:09 -04:00
gui-apps/quickshell: add 0.3.0
patch fixes a -Wstrict-aliasing warning. the patch is needed for LTO,
but fixes a number of warnings output even when not using LTO, hence
applying it for all users
patch taken from 46e60df2d6
Signed-off-by: Ceres <ceres@ceressees.dev>
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
Fixes strict-aliasing error when building with LTO
|
||||
From: https://github.com/noctalia-dev/noctalia-qs/commit/46e60df2d6ebb4d52d5bde8a63a9a6255e556097
|
||||
|
||||
--- a/src/core/model.hpp
|
||||
+++ b/src/core/model.hpp
|
||||
@@ -170,7 +170,11 @@
|
||||
}
|
||||
|
||||
[[nodiscard]] QList<QObject*> values() override {
|
||||
- return *reinterpret_cast<QList<QObject*>*>(&this->mValuesList);
|
||||
+ QList<QObject*> result;
|
||||
+ result.reserve(this->mValuesList.size());
|
||||
+ for (auto* item: this->mValuesList)
|
||||
+ result.append(reinterpret_cast<QObject*>(item));
|
||||
+ return result;
|
||||
}
|
||||
|
||||
private:
|
||||
Reference in New Issue
Block a user