diff options
| author | Marc Mutz <marc.mutz@qt.io> | 2023-08-18 20:54:14 +0200 |
|---|---|---|
| committer | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2023-08-23 09:00:31 +0200 |
| commit | 17f2b6d2e9379d7edaf5acd17a6547ca46b12f2b (patch) | |
| tree | 7cbdcf91c73d2eb42240009b11c712e1c08325bb /src/corelib/tools/qcommandlineparser.cpp | |
| parent | c8d04c1a37c5f307a8e27f8897d5868286fb32cb (diff) | |
QDeadlineTimer: make the (Qt::TimerType) ctor explicit
Qt::TimerType is not a faithful representation of a QDeadlineTimer.
It's missing the actual deadline, and so should not be allowed to
participate in implicit conversions.
Consider whether you'd like to see such code:
foo.setTimeout(Qt::PreciseTimer); // HU???
So split the old (TimerType = CoarseTimer) ctor into an explicit
default ctor (applying NSDMI to make it =default'able) and a new
explicit (TimerType) ctor.
[ChangeLog][Potentially Source-Incompatible Changes][QtCore] The
QDeadlineTimer(Qt::TimerType) constructor is no longer implicit. To
keep old source working, wrap the Qt::TimerType argument in
QDeadlineTimer{}. This is backwards-compatible with older Qt versions.
[ChangeLog][QtCore][QDeadlineTimer] The (Qt::TimerType) constructor is
now explicit (was: implicit).
Found in API-review.
Pick-to: 6.6
Change-Id: I72aaaad5201bd288a6fd6af398573aaa9d0eda5a
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/corelib/tools/qcommandlineparser.cpp')
0 files changed, 0 insertions, 0 deletions
