QCalendarRegistry: Explicitly disable moving and copying

Add Q_DISABLE_COPY_MOVE to QCalendarRegistry to silence the following
warning produced by QtStaticAnalysisBot:

    class 'QCalendarRegistry' defines a non-default destructor but does
    not define a copy constructor, a copy assignment operator, a move
    constructor or a move assignment operator

QCalendarRegistry is a singleton so it does not need to be moved or
copied.

The warning was introduced by d0ae1ef33a.

Task-number: QTBUG-93004
Pick-to: 6.2
Change-Id: I5e018346415b9d0a1ebc3bbde2ab7c3ad5e6d9d0
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
bb10
Ievgenii Meshcheriakov 2021-08-09 12:27:50 +02:00
parent 62b5d88b0d
commit f636a1efa5
1 changed files with 2 additions and 0 deletions

View File

@ -88,6 +88,8 @@ namespace QtPrivate {
*/
class QCalendarRegistry
{
Q_DISABLE_COPY_MOVE(QCalendarRegistry); // This is a singleton.
/*
Lock protecting the registry from concurrent modification.
*/