diff options
author | Alan Alpert <alan.alpert@nokia.com> | 2010-02-23 11:45:38 (GMT) |
---|---|---|
committer | Alan Alpert <alan.alpert@nokia.com> | 2010-02-23 11:45:38 (GMT) |
commit | d43ec1bdb12649c32f0f0067492857a70bef05b4 (patch) | |
tree | 4b37ea692288f646690e71c0f1c4de0acfa118f1 /src/declarative | |
parent | b4d55d5288ddae325046f62f65cbf667283b3859 (diff) | |
download | Qt-d43ec1bdb12649c32f0f0067492857a70bef05b4.zip Qt-d43ec1bdb12649c32f0f0067492857a70bef05b4.tar.gz Qt-d43ec1bdb12649c32f0f0067492857a70bef05b4.tar.bz2 |
More precise compiler errors
People were having trouble figureing what was wrong based off the
previous error message. This should now be rectified - at least for
users who read the docs.
Reviewed-by: mae
Diffstat (limited to 'src/declarative')
-rw-r--r-- | src/declarative/qml/qmlcompiler.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/declarative/qml/qmlcompiler.cpp b/src/declarative/qml/qmlcompiler.cpp index 4508964..4365b17 100644 --- a/src/declarative/qml/qmlcompiler.cpp +++ b/src/declarative/qml/qmlcompiler.cpp @@ -1132,10 +1132,10 @@ bool QmlCompiler::buildComponent(QmlParser::Object *obj, Property *idProp = 0; if (obj->properties.count() > 1 || (obj->properties.count() == 1 && obj->properties.begin().key() != "id")) - COMPILE_EXCEPTION(*obj->properties.begin(), QCoreApplication::translate("QmlCompiler","Invalid component specification")); + COMPILE_EXCEPTION(*obj->properties.begin(), QCoreApplication::translate("QmlCompiler","Component elements may not contain properties other than id")); if (!obj->scriptBlockObjects.isEmpty()) - COMPILE_EXCEPTION(obj->scriptBlockObjects.first(), QCoreApplication::translate("QmlCompiler","Invalid component specification")); + COMPILE_EXCEPTION(obj->scriptBlockObjects.first(), QCoreApplication::translate("QmlCompiler","Component elements may not contain script blocks")); if (obj->properties.count()) idProp = *obj->properties.begin(); |