OpenCoverage

qv4variantobject.cpp

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/qml/jsruntime/qv4variantobject.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4using namespace QV4;-
5-
6const QV4::VTable VariantObject::static_vtbl = { (std::is_same<VariantObject::SuperClass, Object>::value) ? nullptr : &VariantObject::SuperClass::static_vtbl, (sizeof(VariantObject::Data) + sizeof(QV4::Value) - 1)/sizeof(QV4::Value), (sizeof(VariantObject::Data) + (VariantObject::NInlineProperties*sizeof(QV4::Value)) + QV4::Chunk::SlotSize - 1)/QV4::Chunk::SlotSize*QV4::Chunk::SlotSize/sizeof(QV4::Value) - (sizeof(VariantObject::Data) + sizeof(QV4::Value) - 1)/sizeof(QV4::Value), VariantObject::IsExecutionContext, VariantObject::IsString, VariantObject::IsObject, VariantObject::IsFunctionObject, VariantObject::IsErrorObject, VariantObject::IsArrayData, VariantObject::IsStringOrSymbol, VariantObject::MyType, { 0, 0, 0, 0 }, "VariantObject", VariantObject::virtualDestroy, VariantObject::Data::markObjects, VariantObject::virtualIsEqualTo, VariantObject::virtualGet, VariantObject::virtualPut, VariantObject::virtualDeleteProperty, VariantObject::virtualHasProperty, VariantObject::virtualGetOwnProperty, VariantObject::virtualDefineOwnProperty, VariantObject::virtualIsExtensible, VariantObject::virtualPreventExtensions, VariantObject::virtualGetPrototypeOf, VariantObject::virtualSetPrototypeOf, VariantObject::virtualGetLength, VariantObject::virtualAdvanceIterator, VariantObject::virtualInstanceOf, VariantObject::virtualCall, VariantObject::virtualCallAsConstructor, };-
7-
8void Heap::VariantObject::init()-
9{-
10 Object::init();-
11 scarceData = new ExecutionEngine::ScarceResourceData;-
12}
executed 98779 times by 153 tests: end of block
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_ecmascripttests
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qjsvalue
  • tst_qjsvalueiterator
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugclient
  • tst_qqmldebugjs
  • tst_qqmldebuglocal
  • tst_qqmldebugservice
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • ...
98779
13-
14void Heap::VariantObject::init(const QVariant &value)-
15{-
16 Object::init();-
17 scarceData = new ExecutionEngine::ScarceResourceData(value);-
18 if (isScarce()
isScarce()Description
TRUEevaluated 142 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEevaluated 29661 times by 56 tests
Evaluated by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsvalue
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickanchors
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • ...
)
142-29661
19 removeVmePropertyReference();
executed 142 times by 1 test: removeVmePropertyReference();
Executed by:
  • tst_qqmlecmascript
142
20}
executed 29803 times by 56 tests: end of block
Executed by:
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_qjsengine
  • tst_qjsvalue
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmllocale
  • tst_qqmlmetaobject
  • tst_qqmlproperty
  • tst_qqmlqt
  • tst_qqmlsettings
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qqmlxmlhttprequest
  • tst_qquickaccessible
  • tst_qquickanchors
  • tst_qquickanimatedimage
  • tst_qquickanimationcontroller
  • tst_qquickanimations
  • tst_qquickapplication
  • ...
29803
21-
22bool VariantObject::Data::isScarce() const-
23{-
24 QVariant::Type t = data().type();-
25 return
executed 184893 times by 153 tests: return t == QVariant::Pixmap || t == QVariant::Image;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_ecmascripttests
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qjsvalue
  • tst_qjsvalueiterator
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugclient
  • tst_qqmldebugjs
  • tst_qqmldebuglocal
  • tst_qqmldebugservice
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • ...
t == QVariant::Pixmap || t == QVariant::Image;
executed 184893 times by 153 tests: return t == QVariant::Pixmap || t == QVariant::Image;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_ecmascripttests
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qjsvalue
  • tst_qjsvalueiterator
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugclient
  • tst_qqmldebugjs
  • tst_qqmldebuglocal
  • tst_qqmldebugservice
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • ...
184893
26}-
27-
28bool VariantObject::virtualIsEqualTo(Managed *m, Managed *other)-
29{-
30 ((m->as<QV4::VariantObject>()) ? static_cast<void>(0) : qt_assert("m->as<QV4::VariantObject>()", __FILE__, 75));-
31 QV4::VariantObject *lv = static_cast<QV4::VariantObject *>(m);-
32-
33 if (QV4::VariantObject *rv = other->as<QV4::VariantObject>()
QV4::VariantOb...riantObject>()Description
TRUEevaluated 26 times by 2 tests
Evaluated by:
  • tst_qjsvalue
  • tst_qqmlecmascript
FALSEnever evaluated
)
0-26
34 return
executed 26 times by 2 tests: return lv->d()->data() == rv->d()->data();
Executed by:
  • tst_qjsvalue
  • tst_qqmlecmascript
lv->d()->data() == rv->d()->data();
executed 26 times by 2 tests: return lv->d()->data() == rv->d()->data();
Executed by:
  • tst_qjsvalue
  • tst_qqmlecmascript
26
35-
36 if (QV4::QQmlValueTypeWrapper *v = other->as<QQmlValueTypeWrapper>()
QV4::QQmlValue...TypeWrapper>()Description
TRUEnever evaluated
FALSEnever evaluated
)
0
37 return
never executed: return v->isEqual(lv->d()->data());
v->isEqual(lv->d()->data());
never executed: return v->isEqual(lv->d()->data());
0
38-
39 return
never executed: return false;
false;
never executed: return false;
0
40}-
41-
42void VariantObject::addVmePropertyReference() const-
43{-
44 if (d()->isScarce()
d()->isScarce()Description
TRUEevaluated 70 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEevaluated 21767 times by 22 tests
Evaluated by:
  • tst_examples
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlqt
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpincharea
  • tst_qquickrepeater
  • tst_qquickscreen
  • tst_qquicktext
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_qquickworkerscript
&& ++
++d()->vmeProp...enceCount == 1Description
TRUEevaluated 64 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEevaluated 6 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
d()->vmePropertyReferenceCount == 1
++d()->vmeProp...enceCount == 1Description
TRUEevaluated 64 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEevaluated 6 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
) {
6-21767
45-
46-
47-
48 d()->addVmePropertyReference();-
49 }
executed 64 times by 1 test: end of block
Executed by:
  • tst_qqmlecmascript
64
50}
executed 21837 times by 22 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmllistmodel
  • tst_qqmllistmodelworkerscript
  • tst_qqmllistreference
  • tst_qqmlmetaobject
  • tst_qqmlqt
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpincharea
  • tst_qquickrepeater
  • tst_qquickscreen
  • tst_qquicktext
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_qquickworkerscript
21837
51-
52void VariantObject::removeVmePropertyReference() const-
53{-
54 if (d()->isScarce()
d()->isScarce()Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEevaluated 4213 times by 17 tests
Evaluated by:
  • tst_examples
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlmetaobject
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpincharea
  • tst_qquickrepeater
  • tst_qquicktext
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_qquickworkerscript
&& --
--d()->vmeProp...enceCount == 0Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEnever evaluated
d()->vmePropertyReferenceCount == 0
--d()->vmeProp...enceCount == 0Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEnever evaluated
) {
0-4213
55-
56-
57-
58 d()->removeVmePropertyReference();-
59 }
executed 6 times by 1 test: end of block
Executed by:
  • tst_qqmlecmascript
6
60}
executed 4219 times by 17 tests: end of block
Executed by:
  • tst_examples
  • tst_qqmlcontext
  • tst_qqmlecmascript
  • tst_qqmlenginedebugservice
  • tst_qqmlmetaobject
  • tst_qqmlvaluetypeproviders
  • tst_qqmlvaluetypes
  • tst_qquickdrag
  • tst_qquickdroparea
  • tst_qquickgridview
  • tst_qquicklistview
  • tst_qquickpincharea
  • tst_qquickrepeater
  • tst_qquicktext
  • tst_qquicktextinput
  • tst_qquickvisualdatamodel
  • tst_qquickworkerscript
4219
61-
62-
63void VariantPrototype::init()-
64{-
65 defineDefaultProperty(([]() noexcept -> QString { enum { Size = sizeof(u"" "preserve")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "preserve" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return
executed 98079 times by 153 tests: return qstring_literal_temp;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_ecmascripttests
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qjsvalue
  • tst_qjsvalueiterator
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugclient
  • tst_qqmldebugjs
  • tst_qqmldebuglocal
  • tst_qqmldebugservice
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • ...
qstring_literal_temp;
executed 98079 times by 153 tests: return qstring_literal_temp;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_ecmascripttests
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qjsvalue
  • tst_qjsvalueiterator
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugclient
  • tst_qqmldebugjs
  • tst_qqmldebuglocal
  • tst_qqmldebugservice
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • ...
}()), method_preserve, 0);
98079
66 defineDefaultProperty(([]() noexcept -> QString { enum { Size = sizeof(u"" "destroy")/2 - 1 }; static const QStaticStringData<Size> qstring_literal = { { { { -1 } }, Size, 0, 0, sizeof(QStringData) }, u"" "destroy" }; QStringDataPtr holder = { qstring_literal.data_ptr() }; const QString qstring_literal_temp(holder); return
executed 98663 times by 153 tests: return qstring_literal_temp;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_ecmascripttests
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qjsvalue
  • tst_qjsvalueiterator
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugclient
  • tst_qqmldebugjs
  • tst_qqmldebuglocal
  • tst_qqmldebugservice
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • ...
qstring_literal_temp;
executed 98663 times by 153 tests: return qstring_literal_temp;
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_ecmascripttests
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qjsvalue
  • tst_qjsvalueiterator
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugclient
  • tst_qqmldebugjs
  • tst_qqmldebuglocal
  • tst_qqmldebugservice
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • ...
}()), method_destroy, 0);
98663
67 defineDefaultProperty(engine()->id_valueOf(), method_valueOf, 0);-
68 defineDefaultProperty(engine()->id_toString(), method_toString, 0);-
69}
executed 98848 times by 153 tests: end of block
Executed by:
  • tst_bindingdependencyapi
  • tst_drawingmodes
  • tst_ecmascripttests
  • tst_examples
  • tst_flickableinterop
  • tst_multipointtoucharea_interop
  • tst_parserstress
  • tst_qjsengine
  • tst_qjsonbinding
  • tst_qjsvalue
  • tst_qjsvalueiterator
  • tst_qmlcachegen
  • tst_qmldiskcache
  • tst_qqmlapplicationengine
  • tst_qqmlbinding
  • tst_qqmlcomponent
  • tst_qqmlconnections
  • tst_qqmlconsole
  • tst_qqmlcontext
  • tst_qqmldebugclient
  • tst_qqmldebugjs
  • tst_qqmldebuglocal
  • tst_qqmldebugservice
  • tst_qqmlecmascript
  • tst_qqmlenginecleanup
  • ...
98848
70-
71ReturnedValue VariantPrototype::method_preserve(const FunctionObject *, const Value *thisObject, const Value *, int)-
72{-
73 const VariantObject *o = thisObject->as<QV4::VariantObject>();-
74 if (o
oDescription
TRUEevaluated 24 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEnever evaluated
&& o->d()->isScarce()
o->d()->isScarce()Description
TRUEevaluated 24 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEnever evaluated
)
0-24
75 o->d()->addVmePropertyReference();
executed 24 times by 1 test: o->d()->addVmePropertyReference();
Executed by:
  • tst_qqmlecmascript
24
76 return
executed 24 times by 1 test: return QV4::Encode::undefined();
Executed by:
  • tst_qqmlecmascript
QV4::Encode::undefined();
executed 24 times by 1 test: return QV4::Encode::undefined();
Executed by:
  • tst_qqmlecmascript
24
77}-
78-
79ReturnedValue VariantPrototype::method_destroy(const FunctionObject *, const Value *thisObject, const Value *, int)-
80{-
81 const VariantObject *o = thisObject->as<QV4::VariantObject>();-
82 if (o
oDescription
TRUEevaluated 32 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEnever evaluated
) {
0-32
83 if (o->d()->isScarce()
o->d()->isScarce()Description
TRUEevaluated 32 times by 1 test
Evaluated by:
  • tst_qqmlecmascript
FALSEnever evaluated
)
0-32
84 o->d()->addVmePropertyReference();
executed 32 times by 1 test: o->d()->addVmePropertyReference();
Executed by:
  • tst_qqmlecmascript
32
85 o->d()->data() = QVariant();-
86 }
executed 32 times by 1 test: end of block
Executed by:
  • tst_qqmlecmascript
32
87 return
executed 32 times by 1 test: return QV4::Encode::undefined();
Executed by:
  • tst_qqmlecmascript
QV4::Encode::undefined();
executed 32 times by 1 test: return QV4::Encode::undefined();
Executed by:
  • tst_qqmlecmascript
32
88}-
89-
90ReturnedValue VariantPrototype::method_toString(const FunctionObject *b, const Value *thisObject, const Value *, int)-
91{-
92 ExecutionEngine *v4 = b->engine();-
93 const VariantObject *o = thisObject->as<QV4::VariantObject>();-
94 if (!o
!oDescription
TRUEnever evaluated
FALSEevaluated 32 times by 5 tests
Evaluated by:
  • tst_qjsengine
  • tst_qjsvalue
  • tst_qqmlecmascript
  • tst_qqmlxmlhttprequest
  • tst_qquickimage
)
0-32
95 return
never executed: return QV4::Encode::undefined();
QV4::Encode::undefined();
never executed: return QV4::Encode::undefined();
0
96 QString result = o->d()->data().toString();-
97 if (result.isEmpty()
result.isEmpty()Description
TRUEevaluated 6 times by 2 tests
Evaluated by:
  • tst_qjsengine
  • tst_qjsvalue
FALSEevaluated 26 times by 3 tests
Evaluated by:
  • tst_qqmlecmascript
  • tst_qqmlxmlhttprequest
  • tst_qquickimage
&& !o->d()->data().canConvert(QVariant::String)
!o->d()->data(...riant::String)Description
TRUEevaluated 4 times by 2 tests
Evaluated by:
  • tst_qjsengine
  • tst_qjsvalue
FALSEevaluated 2 times by 1 test
Evaluated by:
  • tst_qjsvalue
) {
2-26
98 result = QLatin1String("QVariant(")-
99 + QLatin1String(o->d()->data().typeName())-
100 + QLatin1Char(')');-
101 }
executed 4 times by 2 tests: end of block
Executed by:
  • tst_qjsengine
  • tst_qjsvalue
4
102 return
executed 32 times by 5 tests: return Encode(v4->newString(result));
Executed by:
  • tst_qjsengine
  • tst_qjsvalue
  • tst_qqmlecmascript
  • tst_qqmlxmlhttprequest
  • tst_qquickimage
Encode(v4->newString(result));
executed 32 times by 5 tests: return Encode(v4->newString(result));
Executed by:
  • tst_qjsengine
  • tst_qjsvalue
  • tst_qqmlecmascript
  • tst_qqmlxmlhttprequest
  • tst_qquickimage
32
103}-
104-
105ReturnedValue VariantPrototype::method_valueOf(const FunctionObject *b, const Value *thisObject, const Value *, int)-
106{-
107 const VariantObject *o = thisObject->as<QV4::VariantObject>();-
108 if (o
oDescription
TRUEevaluated 30 times by 3 tests
Evaluated by:
  • tst_qjsengine
  • tst_qqmlecmascript
  • tst_qquickimage
FALSEnever evaluated
) {
0-30
109 QVariant v = o->d()->data();-
110 switch (v.type()) {-
111 case
never executed: case QVariant::Invalid:
QVariant::Invalid:
never executed: case QVariant::Invalid:
0
112 return
never executed: return Encode::undefined();
Encode::undefined();
never executed: return Encode::undefined();
0
113 case
never executed: case QVariant::String:
QVariant::String:
never executed: case QVariant::String:
0
114 return
never executed: return Encode(b->engine()->newString(v.toString()));
Encode(b->engine()->newString(v.toString()));
never executed: return Encode(b->engine()->newString(v.toString()));
0
115 case
never executed: case QVariant::Int:
QVariant::Int:
never executed: case QVariant::Int:
0
116 return
never executed: return Encode(v.toInt());
Encode(v.toInt());
never executed: return Encode(v.toInt());
0
117 case
never executed: case QVariant::Double:
QVariant::Double:
never executed: case QVariant::Double:
0
118 case
never executed: case QVariant::UInt:
QVariant::UInt:
never executed: case QVariant::UInt:
0
119 return
never executed: return Encode(v.toDouble());
Encode(v.toDouble());
never executed: return Encode(v.toDouble());
0
120 case
never executed: case QVariant::Bool:
QVariant::Bool:
never executed: case QVariant::Bool:
0
121 return
never executed: return Encode(v.toBool());
Encode(v.toBool());
never executed: return Encode(v.toBool());
0
122 default
executed 30 times by 3 tests: default:
Executed by:
  • tst_qjsengine
  • tst_qqmlecmascript
  • tst_qquickimage
:
executed 30 times by 3 tests: default:
Executed by:
  • tst_qjsengine
  • tst_qqmlecmascript
  • tst_qquickimage
30
123 if (QMetaType::typeFlags(v.userType()) & QMetaType::IsEnumeration
QMetaType::typ...:IsEnumerationDescription
TRUEevaluated 2 times by 1 test
Evaluated by:
  • tst_qjsengine
FALSEevaluated 28 times by 3 tests
Evaluated by:
  • tst_qjsengine
  • tst_qqmlecmascript
  • tst_qquickimage
)
2-28
124 return
executed 2 times by 1 test: return QV4::Encode(Encode(v.toInt()));
Executed by:
  • tst_qjsengine
QV4::Encode(Encode(v.toInt()));
executed 2 times by 1 test: return QV4::Encode(Encode(v.toInt()));
Executed by:
  • tst_qjsengine
2
125 break;
executed 28 times by 3 tests: break;
Executed by:
  • tst_qjsengine
  • tst_qqmlecmascript
  • tst_qquickimage
28
126 }-
127 }-
128 return
executed 28 times by 3 tests: return thisObject->asReturnedValue();
Executed by:
  • tst_qjsengine
  • tst_qqmlecmascript
  • tst_qquickimage
thisObject->asReturnedValue();
executed 28 times by 3 tests: return thisObject->asReturnedValue();
Executed by:
  • tst_qjsengine
  • tst_qqmlecmascript
  • tst_qquickimage
28
129}-
130-
131-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.2.0