OpenCoverage

qqmlexpression.cpp

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/qml/qml/qqmlexpression.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6QQmlExpressionPrivate::QQmlExpressionPrivate()-
7: QQmlJavaScriptExpression(),-
8 expressionFunctionValid(true),-
9 line(0), column(0)-
10{-
11}
executed 1130416 times by 22 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
1130416
12-
13QQmlExpressionPrivate::~QQmlExpressionPrivate()-
14{-
15}-
16-
17void QQmlExpressionPrivate::init(QQmlContextData *ctxt, const QString &expr, QObject *me)-
18{-
19 expression = expr;-
20-
21 QQmlJavaScriptExpression::setContext(ctxt);-
22 setScopeObject(me);-
23 expressionFunctionValid = false;-
24}
executed 1112342 times by 15 tests: end of block
Executed by:
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
1112342
25-
26void QQmlExpressionPrivate::init(QQmlContextData *ctxt, QV4::Function *runtimeFunction, QObject *me)-
27{-
28 expressionFunctionValid = true;-
29 QV4::ExecutionEngine *engine = ctxt->engine->handle();-
30 QV4::Scope scope(engine);-
31 QV4::Scoped<QV4::QmlContext> qmlContext(scope, QV4::QmlContext::create(engine->rootContext(), ctxt, me));-
32 setupFunction(qmlContext, runtimeFunction);-
33-
34 QQmlJavaScriptExpression::setContext(ctxt);-
35 setScopeObject(me);-
36}
executed 18074 times by 11 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
18074
37QQmlExpression::QQmlExpression()-
38: QObject(*new QQmlExpressionPrivate, nullptr)-
39{-
40}
never executed: end of block
0
41QQmlExpression::QQmlExpression(const QQmlScriptString &script, QQmlContext *ctxt, QObject *scope, QObject *parent)-
42: QObject(*new QQmlExpressionPrivate, parent)-
43{-
44 QQmlExpressionPrivate * const d = d_func();-
45 if (ctxt
ctxtDescription
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_qqmlstatemachine
FALSEevaluated 18070 times by 10 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
&& !ctxt->isValid()
!ctxt->isValid()Description
TRUEnever evaluated
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qqmlstatemachine
)
0-18070
46 return;
never executed: return;
0
47-
48 const QQmlScriptStringPrivate *scriptPrivate = script.d.data();-
49 if (!ctxt
!ctxtDescription
TRUEevaluated 18070 times by 10 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
FALSEevaluated 4 times by 1 test
Evaluated by:
  • tst_qqmlstatemachine
&& (!scriptPrivate->context
!scriptPrivate->contextDescription
TRUEnever evaluated
FALSEevaluated 18070 times by 10 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
|| !scriptPrivate->context->isValid()
!scriptPrivate...ext->isValid()Description
TRUEnever evaluated
FALSEevaluated 18070 times by 10 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
))
0-18070
50 return;
never executed: return;
0
51-
52 QQmlContextData *evalCtxtData = QQmlContextData::get(ctxt ? ctxt : scriptPrivate->context);-
53 QObject *scopeObject = scope
scopeDescription
TRUEevaluated 4 times by 1 test
Evaluated by:
  • tst_qqmlstatemachine
FALSEevaluated 18070 times by 10 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
? scope : scriptPrivate->scope;
4-18070
54 QV4::Function *runtimeFunction = nullptr;-
55-
56 if (scriptPrivate->context
scriptPrivate->contextDescription
TRUEevaluated 18074 times by 11 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
FALSEnever evaluated
) {
0-18074
57 QQmlContextData *ctxtdata = QQmlContextData::get(scriptPrivate->context);-
58 QQmlEnginePrivate *engine = QQmlEnginePrivate::get(scriptPrivate->context->engine());-
59 if (engine
engineDescription
TRUEevaluated 18074 times by 11 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
FALSEnever evaluated
&& ctxtdata
ctxtdataDescription
TRUEevaluated 18074 times by 11 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
FALSEnever evaluated
&& !ctxtdata->urlString().isEmpty()
!ctxtdata->url...ng().isEmpty()Description
TRUEevaluated 18074 times by 11 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
FALSEnever evaluated
&& ctxtdata->typeCompilationUnit) {
0-18074
60 d->url = ctxtdata->urlString();-
61 d->line = scriptPrivate->lineNumber;-
62 d->column = scriptPrivate->columnNumber;-
63-
64 if (scriptPrivate->bindingId != QQmlBinding::Invalid
scriptPrivate-...nding::InvalidDescription
TRUEevaluated 18074 times by 11 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
FALSEnever evaluated
)
0-18074
65 runtimeFunction = ctxtdata->typeCompilationUnit->runtimeFunctions.at(scriptPrivate->bindingId);
executed 18074 times by 11 tests: runtimeFunction = ctxtdata->typeCompilationUnit->runtimeFunctions.at(scriptPrivate->bindingId);
Executed by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
18074
66 }
executed 18074 times by 11 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
18074
67 }
executed 18074 times by 11 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
18074
68-
69 if (runtimeFunction
runtimeFunctionDescription
TRUEevaluated 18074 times by 11 tests
Evaluated by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
FALSEnever evaluated
) {
0-18074
70 d->expression = scriptPrivate->script;-
71 d->init(evalCtxtData, runtimeFunction, scopeObject);-
72 }
executed 18074 times by 11 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
else
18074
73 d->init(evalCtxtData, scriptPrivate->script, scopeObject);
never executed: d->init(evalCtxtData, scriptPrivate->script, scopeObject);
0
74}-
75QQmlExpression::QQmlExpression(QQmlContext *ctxt,-
76 QObject *scope,-
77 const QString &expression,-
78 QObject *parent)-
79: QObject(*new QQmlExpressionPrivate, parent)-
80{-
81 QQmlExpressionPrivate * const d = d_func();-
82 d->init(QQmlContextData::get(ctxt), expression, scope);-
83}
executed 1112342 times by 15 tests: end of block
Executed by:
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
1112342
84-
85-
86-
87-
88QQmlExpression::QQmlExpression(QQmlContextData *ctxt, QObject *scope,-
89 const QString &expression)-
90: QObject(*new QQmlExpressionPrivate, nullptr)-
91{-
92 QQmlExpressionPrivate * const d = d_func();-
93 d->init(ctxt, expression, scope);-
94}
never executed: end of block
0
95-
96-
97-
98-
99QQmlExpression::~QQmlExpression()-
100{-
101}-
102-
103-
104-
105-
106-
107QQmlEngine *QQmlExpression::engine() const-
108{-
109 const QQmlExpressionPrivate * const d = d_func();-
110 return
executed 1130746 times by 21 tests: return d->context()?d->context()->engine:nullptr;
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
d->context()?d->context()->engine:nullptr;
executed 1130746 times by 21 tests: return d->context()?d->context()->engine:nullptr;
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
1130746
111}-
112-
113-
114-
115-
116-
117QQmlContext *QQmlExpression::context() const-
118{-
119 const QQmlExpressionPrivate * const d = d_func();-
120 QQmlContextData *data = d->context();-
121 return
executed 4 times by 1 test: return data?data->asQQmlContext():nullptr;
Executed by:
  • tst_qqmlcontext
data?data->asQQmlContext():nullptr;
executed 4 times by 1 test: return data?data->asQQmlContext():nullptr;
Executed by:
  • tst_qqmlcontext
4
122}-
123-
124-
125-
126-
127QString QQmlExpression::expression() const-
128{-
129 const QQmlExpressionPrivate * const d = d_func();-
130 return
never executed: return d->expression;
d->expression;
never executed: return d->expression;
0
131}-
132-
133-
134-
135-
136void QQmlExpression::setExpression(const QString &expression)-
137{-
138 QQmlExpressionPrivate * const d = d_func();-
139-
140 d->resetNotifyOnValueChanged();-
141 d->expression = expression;-
142 d->expressionFunctionValid = false;-
143}
executed 128 times by 1 test: end of block
Executed by:
  • tst_qqmllistmodel
128
144-
145-
146QV4::ReturnedValue QQmlExpressionPrivate::v4value(bool *isUndefined)-
147{-
148 if (!expressionFunctionValid
!expressionFunctionValidDescription
TRUEevaluated 1112468 times by 14 tests
Evaluated by:
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
FALSEevaluated 18104 times by 13 tests
Evaluated by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_scenegraph
) {
18104-1112468
149 createQmlBinding(context(), scopeObject(), expression, url, line);-
150 expressionFunctionValid = true;-
151 if (hasError()
hasError()Description
TRUEevaluated 6 times by 3 tests
Evaluated by:
  • tst_qqmlecmascript
  • tst_qqmlexpression
  • tst_qquickvisualdatamodel
FALSEevaluated 1112462 times by 14 tests
Evaluated by:
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
) {
6-1112462
152 if (isUndefined
isUndefinedDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qqmlexpression
FALSEevaluated 4 times by 2 tests
Evaluated by:
  • tst_qqmlecmascript
  • tst_qquickvisualdatamodel
)
2-4
153 *
executed 2 times by 1 test: *isUndefined = true;
Executed by:
  • tst_qqmlexpression
isUndefined = true;
executed 2 times by 1 test: *isUndefined = true;
Executed by:
  • tst_qqmlexpression
2
154 return
executed 6 times by 3 tests: return QV4::Encode::undefined();
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlexpression
  • tst_qquickvisualdatamodel
QV4::Encode::undefined();
executed 6 times by 3 tests: return QV4::Encode::undefined();
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlexpression
  • tst_qquickvisualdatamodel
6
155 }-
156 }
executed 1112462 times by 14 tests: end of block
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
1112462
157-
158 return
executed 1130566 times by 21 tests: return evaluate(isUndefined);
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
evaluate(isUndefined);
executed 1130566 times by 21 tests: return evaluate(isUndefined);
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
1130566
159}-
160-
161QVariant QQmlExpressionPrivate::value(bool *isUndefined)-
162{-
163 QQmlExpression * const q = q_func();-
164-
165 if (!context()
!context()Description
TRUEnever evaluated
FALSEevaluated 1130572 times by 21 tests
Evaluated by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
|| !context()->isValid()
!context()->isValid()Description
TRUEnever evaluated
FALSEevaluated 1130572 times by 21 tests
Evaluated by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
) {
0-1130572
166 QMessageLogger(__FILE__, 270, __PRETTY_FUNCTION__).warning("QQmlExpression: Attempted to evaluate an expression in an invalid context");-
167 return
never executed: return QVariant();
QVariant();
never executed: return QVariant();
0
168 }-
169-
170 QQmlEngine *engine = q->engine();-
171 QQmlEnginePrivate *ep = QQmlEnginePrivate::get(engine);-
172 QVariant rv;-
173-
174 ep->referenceScarceResources();-
175-
176 {-
177 QV4::Scope scope(engine->handle());-
178 QV4::ScopedValue result(scope, v4value(isUndefined));-
179 if (!hasError()
!hasError()Description
TRUEevaluated 1130554 times by 21 tests
Evaluated by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
FALSEevaluated 18 times by 4 tests
Evaluated by:
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qquickvisualdatamodel
)
18-1130554
180 rv = scope.engine->toVariant(result, -1);
executed 1130554 times by 21 tests: rv = scope.engine->toVariant(result, -1);
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
1130554
181 }-
182-
183 ep->dereferenceScarceResources();-
184-
185 return
executed 1130572 times by 21 tests: return rv;
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
rv;
executed 1130572 times by 21 tests: return rv;
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
1130572
186}-
187QVariant QQmlExpression::evaluate(bool *valueIsUndefined)-
188{-
189 QQmlExpressionPrivate * const d = d_func();-
190 return
executed 1130572 times by 21 tests: return d->value(valueIsUndefined);
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
d->value(valueIsUndefined);
executed 1130572 times by 21 tests: return d->value(valueIsUndefined);
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlstatemachine
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpathview
  • tst_qquickpositioners
  • tst_qquickrepeater
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
1130572
191}-
192-
193-
194-
195-
196-
197bool QQmlExpression::notifyOnValueChanged() const-
198{-
199 const QQmlExpressionPrivate * const d = d_func();-
200 return
never executed: return d->notifyOnValueChanged();
d->notifyOnValueChanged();
never executed: return d->notifyOnValueChanged();
0
201}-
202void QQmlExpression::setNotifyOnValueChanged(bool notifyOnChange)-
203{-
204 QQmlExpressionPrivate * const d = d_func();-
205 d->setNotifyOnValueChanged(notifyOnChange);-
206}
executed 58 times by 2 tests: end of block
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
58
207-
208-
209-
210-
211-
212QString QQmlExpression::sourceFile() const-
213{-
214 const QQmlExpressionPrivate * const d = d_func();-
215 return
never executed: return d->url;
d->url;
never executed: return d->url;
0
216}-
217-
218-
219-
220-
221-
222int QQmlExpression::lineNumber() const-
223{-
224 const QQmlExpressionPrivate * const d = d_func();-
225 return
never executed: return qmlSourceCoordinate(d->line);
qmlSourceCoordinate(d->line);
never executed: return qmlSourceCoordinate(d->line);
0
226}-
227-
228-
229-
230-
231-
232int QQmlExpression::columnNumber() const-
233{-
234 const QQmlExpressionPrivate * const d = d_func();-
235 return
never executed: return qmlSourceCoordinate(d->column);
qmlSourceCoordinate(d->column);
never executed: return qmlSourceCoordinate(d->column);
0
236}-
237-
238-
239-
240-
241-
242void QQmlExpression::setSourceLocation(const QString &url, int line, int column)-
243{-
244 QQmlExpressionPrivate * const d = d_func();-
245 d->url = url;-
246 d->line = qmlSourceCoordinate(line);-
247 d->column = qmlSourceCoordinate(column);-
248}
never executed: end of block
0
249-
250-
251-
252-
253-
254-
255-
256QObject *QQmlExpression::scopeObject() const-
257{-
258 const QQmlExpressionPrivate * const d = d_func();-
259 return
never executed: return d->scopeObject();
d->scopeObject();
never executed: return d->scopeObject();
0
260}-
261-
262-
263-
264-
265-
266-
267-
268bool QQmlExpression::hasError() const-
269{-
270 const QQmlExpressionPrivate * const d = d_func();-
271 return
executed 84392 times by 17 tests: return d->hasError();
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
d->hasError();
executed 84392 times by 17 tests: return d->hasError();
Executed by:
  • tst_examples
  • tst_qqmlecmascript
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmlxmlhttprequest
  • tst_qquickanimations
  • tst_qquickbehaviors
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpositioners
  • tst_qquickstates
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_scenegraph
84392
272}-
273-
274-
275-
276-
277-
278-
279-
280void QQmlExpression::clearError()-
281{-
282 QQmlExpressionPrivate * const d = d_func();-
283 d->clearError();-
284}
never executed: end of block
0
285QQmlError QQmlExpression::error() const-
286{-
287 const QQmlExpressionPrivate * const d = d_func();-
288 return
executed 174 times by 5 tests: return d->error(engine());
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qquickvisualdatamodel
d->error(engine());
executed 174 times by 5 tests: return d->error(engine());
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlexpression
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qquickvisualdatamodel
174
289}-
290void QQmlExpressionPrivate::expressionChanged()-
291{-
292 QQmlExpression * const q = q_func();-
293 q->valueChanged();-
294}
executed 34 times by 2 tests: end of block
Executed by:
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
34
295-
296QString QQmlExpressionPrivate::expressionIdentifier() const-
297{-
298 return
never executed: return QLatin1Char('"') + expression + QLatin1Char('"');
QLatin1Char('"') + expression + QLatin1Char('"');
never executed: return QLatin1Char('"') + expression + QLatin1Char('"');
0
299}-
300-
301-
302-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.2.0