diff options
author | Ivan Komissarov <abbapoh@gmail.com> | 2023-11-07 21:01:44 +0300 |
---|---|---|
committer | Ivan Komissarov <ABBAPOH@gmail.com> | 2023-11-09 10:04:31 +0000 |
commit | 6dd1ac96dca1d325b75cfc3eca34831023809691 (patch) | |
tree | 98c2bb1af17bb8d935b4645ccf11ca01586a297b /src/lib/corelib/corelib.qbs | |
parent | 0a6b84989775c0a9054ee5167212454da09c416f (diff) |
Add Rust-like Mutex
This change implements a Rust-like Mutex class
that prevents unlocked access to the underlying data.
As seen recently, it is easy to make a mistake and lock
the wrong mutex. Also, this prevents micro-optimizations
where shared state is accessed without locking corresponding
mutex in hope that there is some other barrier.
Change-Id: I52c7a2fa68cc97be07a490c35aa76fe717032fdf
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src/lib/corelib/corelib.qbs')
-rw-r--r-- | src/lib/corelib/corelib.qbs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lib/corelib/corelib.qbs b/src/lib/corelib/corelib.qbs index bf414ff80..1a7890166 100644 --- a/src/lib/corelib/corelib.qbs +++ b/src/lib/corelib/corelib.qbs @@ -514,6 +514,7 @@ QbsLibrary { "generateoptions.h", "installoptions.h", "joblimits.h", + "mutexdata.h", "preferences.h", "processresult.h", "profile.h", |