aboutsummaryrefslogtreecommitdiffstats
path: root/src/libs/qmljs/qmljsbundle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/qmljs/qmljsbundle.cpp')
-rw-r--r--src/libs/qmljs/qmljsbundle.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/libs/qmljs/qmljsbundle.cpp b/src/libs/qmljs/qmljsbundle.cpp
index 9789d37492..6c7ee6029b 100644
--- a/src/libs/qmljs/qmljsbundle.cpp
+++ b/src/libs/qmljs/qmljsbundle.cpp
@@ -219,11 +219,11 @@ QStringList QmlBundle::maybeReadTrie(Trie &trie, Utils::JsonObjectValue *config,
return res;
}
Utils::JsonValue *imp0 = config->member(propertyName);
- Utils::JsonArrayValue *imp = ((imp0 != 0) ? imp0->toArray() : 0);
- if (imp != 0) {
+ Utils::JsonArrayValue *imp = ((imp0 != nullptr) ? imp0->toArray() : nullptr);
+ if (imp != nullptr) {
foreach (Utils::JsonValue *v, imp->elements()) {
- Utils::JsonStringValue *impStr = ((v != 0) ? v->toString() : 0);
- if (impStr != 0) {
+ Utils::JsonStringValue *impStr = ((v != nullptr) ? v->toString() : nullptr);
+ if (impStr != nullptr) {
trie.insert(impStr->value());
} else {
res.append(QString::fromLatin1("Expected all elements of array in property \"%1\" "
@@ -251,7 +251,7 @@ bool QmlBundle::readFrom(QString path, QStringList *errors)
return false;
}
JsonObjectValue *config = JsonValue::create(QString::fromUtf8(f.readAll()), &pool)->toObject();
- if (config == 0) {
+ if (config == nullptr) {
if (errors)
(*errors) << QString::fromLatin1("Could not parse json object in file at %1 .").arg(path);
return false;
@@ -259,8 +259,8 @@ bool QmlBundle::readFrom(QString path, QStringList *errors)
QStringList errs;
if (config->hasMember(QLatin1String("name"))) {
JsonValue *n0 = config->member(QLatin1String("name"));
- JsonStringValue *n = ((n0 != 0) ? n0->toString() : 0);
- if (n != 0)
+ JsonStringValue *n = ((n0 != nullptr) ? n0->toString() : nullptr);
+ if (n != nullptr)
m_name = n->value();
else
errs.append(QString::fromLatin1("Property \"name\" in QmlBundle at %1 is expected "