Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
6.5
-
c108a817f (dev), 330c3e91e (dev), 5bc63de88 (dev), bda7b2a44 (dev), c09e2d919 (6.5), 3c1b81726 (6.5), c7f5507f0 (6.5)
Description
Compiling
import QtQuick Window { id: win width: 640 height: 480 visible: true title: "Sandbox" property date date: "" Text { text: Qt.formatTime(win.date) } } }
runs into
Warning: main.qml:37:22: Could not compile binding for text: No matching override found. Candidates: argument 0 contains QDateTime of (component in /home/prcs1076/tmp/build-untitled-Dev_Snapshot-Debug/main.qml)::date with type QDateTime but is expected to contain the type QString Function expects 2 arguments, but 1 were provided Function expects 3 arguments, but 1 were provided argument 0 contains QDateTime of (component in /home/prcs1076/tmp/build-untitled-Dev_Snapshot-Debug/main.qml)::date with type QDateTime but is expected to contain the type QTime Function expects 2 arguments, but 1 were provided Function expects 3 arguments, but 1 were provided Function expects 2 arguments, but 1 were provided Function expects 2 arguments, but 1 were provided Function expects 2 arguments, but 1 were provided Function expects 2 arguments, but 1 were provided [compiler] text: Qt.formatTime(win.date) ^^^^^^^^^^
. Same for data types passed from C++.
Attachments
For Gerrit Dashboard: QTBUG-109380 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
453299,15 | QmlCompiler: Handle various date and time conversions correctly | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
453547,10 | QJSEngine: Add efficient conversions for QDateTime and friends | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
453548,11 | V4: Unify type conversions for date and time values | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
453549,13 | QML: Add more overloads to Qt.format{Date|Time|DateTime}() | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |
482165,2 | QJSEngine: Add efficient conversions for QDateTime and friends | 6.5 | qt/qtdeclarative | Status: MERGED | +2 | 0 |
482166,2 | V4: Unify type conversions for date and time values | 6.5 | qt/qtdeclarative | Status: MERGED | +2 | 0 |
482167,2 | QML: Add more overloads to Qt.format{Date|Time|DateTime}() | 6.5 | qt/qtdeclarative | Status: MERGED | +2 | 0 |