Unify QQmlDirParser version parsing and error reporting
authorJ-P Nurmi <jpnurmi@theqtcompany.com>
Wed, 7 Jan 2015 12:32:33 +0000 (13:32 +0100)
committerJ-P Nurmi <jpnurmi@theqtcompany.com>
Wed, 7 Jan 2015 13:44:05 +0000 (14:44 +0100)
commit353e43cb6d73ee97ebff1a8c737b2c133b135ab8
treee2ebd8f500fffd5b6c4c828a95ae08a59608fe3b
parentfae16f9d2fca773276eba150d0414fb2f303d179
Unify QQmlDirParser version parsing and error reporting

Add a parseVersion() helper function to avoid duplicating
the same version parsing logic three times.

Change-Id: I4e5b6a8c86ee3a26c4eb91c660a81176ac0346cf
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
src/qml/qml/qqmldirparser.cpp
tests/auto/qml/qqmldirparser/data/invalid-versioned-dependency/qmldir [new file with mode: 0644]
tests/auto/qml/qqmldirparser/data/invalid-versioned-script/qmldir [new file with mode: 0644]
tests/auto/qml/qqmldirparser/tst_qqmldirparser.cpp