| Absolute File Name: | /home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/qml/jsruntime/qv4proxy_p.h | 
| Switch to Source code | Preprocessed file | 
| Line | Source | Count | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | - | |||||||||||||
| 2 | - | |||||||||||||
| 3 | namespace QV4 { | - | ||||||||||||
| 4 | - | |||||||||||||
| 5 | namespace Heap { | - | ||||||||||||
| 6 | - | |||||||||||||
| 7 | - | |||||||||||||
| 8 | - | |||||||||||||
| 9 | - | |||||||||||||
| 10 | - | |||||||||||||
| 11 | struct ProxyObjectOffsetStruct { Pointer<Object *, 0> target; Pointer<Object *, 0> handler; }; struct ProxyObjectSizeStruct : Object, ProxyObjectOffsetStruct {}; struct ProxyObjectData { typedef Object SuperClass; static constexpr size_t baseOffset = sizeof(ProxyObjectSizeStruct) - sizeof(ProxyObjectOffsetStruct); Pointer<Object *, | - | ||||||||||||
| 12 | __builtin_offsetof ( | - | ||||||||||||
| 13 | ProxyObjectOffsetStruct | - | ||||||||||||
| 14 | , | - | ||||||||||||
| 15 | target | - | ||||||||||||
| 16 | ) | - | ||||||||||||
| 17 | + baseOffset> target; Pointer<Object *, | - | ||||||||||||
| 18 | __builtin_offsetof ( | - | ||||||||||||
| 19 | ProxyObjectOffsetStruct | - | ||||||||||||
| 20 | , | - | ||||||||||||
| 21 | handler | - | ||||||||||||
| 22 | ) | - | ||||||||||||
| 23 | + baseOffset> handler; }; static_assert(bool(sizeof(ProxyObjectSizeStruct) == sizeof(ProxyObjectData) + ProxyObjectData::baseOffset), "sizeof(ProxyObjectSizeStruct) == sizeof(ProxyObjectData) + ProxyObjectData::baseOffset"); struct ProxyObject : Object, ProxyObjectData { | - | ||||||||||||
| 24 |     static void markObjects(Heap::Base *b, MarkStack *stack) { ProxyObject *o = static_cast<ProxyObject *>(b); ProxyObjectData::SuperClass::markObjects(o, stack); if (o->target
 never executed:   if (o->handlero->target.heapObject()->mark(stack);
 never executed:   }o->handler.heapObject()->mark(stack);never executed:  end of block | 0 | ||||||||||||
| 25 | - | |||||||||||||
| 26 | void init(const QV4::Object *target, const QV4::Object *handler); | - | ||||||||||||
| 27 | }; | - | ||||||||||||
| 28 | - | |||||||||||||
| 29 | - | |||||||||||||
| 30 | - | |||||||||||||
| 31 | - | |||||||||||||
| 32 | struct ProxyOffsetStruct { Pointer<Symbol *, 0> revokableProxySymbol; }; struct ProxySizeStruct : FunctionObject, ProxyOffsetStruct {}; struct ProxyData { typedef FunctionObject SuperClass; static constexpr size_t baseOffset = sizeof(ProxySizeStruct) - sizeof(ProxyOffsetStruct); Pointer<Symbol *, | - | ||||||||||||
| 33 | __builtin_offsetof ( | - | ||||||||||||
| 34 | ProxyOffsetStruct | - | ||||||||||||
| 35 | , | - | ||||||||||||
| 36 | revokableProxySymbol | - | ||||||||||||
| 37 | ) | - | ||||||||||||
| 38 | + baseOffset> revokableProxySymbol; }; static_assert(bool(sizeof(ProxySizeStruct) == sizeof(ProxyData) + ProxyData::baseOffset), "sizeof(ProxySizeStruct) == sizeof(ProxyData) + ProxyData::baseOffset"); struct Proxy : FunctionObject, ProxyData { | - | ||||||||||||
| 39 |     static void markObjects(Heap::Base *b, MarkStack *stack) { Proxy *o = static_cast<Proxy *>(b); ProxyData::SuperClass::markObjects(o, stack); if (o->revokableProxySymbol
 never executed:   }o->revokableProxySymbol.heapObject()->mark(stack);executed 8854 times by 26 tests:  end of blockExecuted by: 
  | 0-8854 | ||||||||||||
| 40 | - | |||||||||||||
| 41 | void init(QV4::ExecutionContext *ctx); | - | ||||||||||||
| 42 | }; | - | ||||||||||||
| 43 | - | |||||||||||||
| 44 | } | - | ||||||||||||
| 45 | - | |||||||||||||
| 46 | struct ProxyObject: Object { | - | ||||||||||||
| 47 |     private: ProxyObject() = delete; ProxyObject(const ProxyObject &) = delete; ProxyObject &operator=(const ProxyObject &) = delete; public: template <typename Type> inline void qt_check_for_QMANAGED_macro(const Type *_q_argument) const { int i = qYouForgotTheQ_MANAGED_Macro(this, _q_argument); i = i + 1; } executed 2435 times by 1 test:   typedef QV4::Heap::ProxyObject Data; typedef Object SuperClass; static const QV4::VTable static_vtbl; static inline const QV4::VTable *staticVTable() { returnend of blockExecuted by: 
 executed 105130 times by 153 tests:   &static_vtbl;return &static_vtbl;Executed by: 
 executed 105130 times by 153 tests:   } void __dataTest() { static_assert (sizeof(*this) == sizeof(Managed), "Classes derived from Managed can't have own data members."); }return &static_vtbl;Executed by: 
 never executed:   QV4::Heap::ProxyObject *d_unchecked() const { returnend of blockexecuted 5990 times by 1 test:   static_cast<QV4::Heap::ProxyObject *>(m());return static_cast<QV4::Heap::ProxyObject *>(m());Executed by: 
 executed 5990 times by 1 test:   } QV4::Heap::ProxyObject *d() const { QV4::Heap::ProxyObject *dptr = d_unchecked(); dptr->_checkIsInitialized(); returnreturn static_cast<QV4::Heap::ProxyObject *>(m());Executed by: 
 executed 4839 times by 1 test:   dptr;return dptr;Executed by: 
 executed 4839 times by 1 test:   } static_assert(bool(std::is_trivial< QV4::Heap::ProxyObject >::value), "std::is_trivial< QV4::Heap::ProxyObject >::value");return dptr;Executed by: 
  | 0-105130 | ||||||||||||
| 48 | public: enum { MyType = Type_ProxyObject }; | - | ||||||||||||
| 49 |     static Heap::InternalClass *defaultInternalClass(QV4::EngineBase *e) { return executed 1158 times by 1 test:   e->internalClasses(QV4::EngineBase::Class_ProxyObject);return e->internalClasses(QV4::EngineBase::Class_ProxyObject);Executed by: 
 executed 1158 times by 1 test:   }return e->internalClasses(QV4::EngineBase::Class_ProxyObject);Executed by: 
  | 1158 | ||||||||||||
| 50 | - | |||||||||||||
| 51 | static ReturnedValue virtualGet(const Managed *m, PropertyKey id, const Value *receiver, bool *hasProperty); | - | ||||||||||||
| 52 | static bool virtualPut(Managed *m, PropertyKey id, const Value &value, Value *receiver); | - | ||||||||||||
| 53 | static bool virtualDeleteProperty(Managed *m, PropertyKey id); | - | ||||||||||||
| 54 | static bool virtualHasProperty(const Managed *m, PropertyKey id); | - | ||||||||||||
| 55 | static PropertyAttributes virtualGetOwnProperty(Managed *m, PropertyKey id, Property *p); | - | ||||||||||||
| 56 | static bool virtualDefineOwnProperty(Managed *m, PropertyKey id, const Property *p, PropertyAttributes attrs); | - | ||||||||||||
| 57 | static bool virtualIsExtensible(const Managed *m); | - | ||||||||||||
| 58 | static bool virtualPreventExtensions(Managed *); | - | ||||||||||||
| 59 | static Heap::Object *virtualGetPrototypeOf(const Managed *); | - | ||||||||||||
| 60 | static bool virtualSetPrototypeOf(Managed *, const Object *); | - | ||||||||||||
| 61 | - | |||||||||||||
| 62 | - | |||||||||||||
| 63 | - | |||||||||||||
| 64 | - | |||||||||||||
| 65 | }; | - | ||||||||||||
| 66 | - | |||||||||||||
| 67 | struct Proxy : FunctionObject | - | ||||||||||||
| 68 | { | - | ||||||||||||
| 69 |     private: Proxy() = delete; Proxy(const Proxy &) = delete; Proxy &operator=(const Proxy &) = delete; public: template <typename Type> inline void qt_check_for_QMANAGED_macro(const Type *_q_argument) const { int i = qYouForgotTheQ_MANAGED_Macro(this, _q_argument); i = i + 1; } never executed:   typedef QV4::Heap::Proxy Data; typedef FunctionObject SuperClass; static const QV4::VTable static_vtbl; static inline const QV4::VTable *staticVTable() { returnend of blockexecuted 295978 times by 153 tests:   &static_vtbl;return &static_vtbl;Executed by: 
 executed 295978 times by 153 tests:   } void __dataTest() { static_assert (sizeof(*this) == sizeof(Managed), "Classes derived from Managed can't have own data members."); }return &static_vtbl;Executed by: 
 never executed:   QV4::Heap::Proxy *d_unchecked() const { returnend of blockexecuted 197347 times by 153 tests:   static_cast<QV4::Heap::Proxy *>(m());return static_cast<QV4::Heap::Proxy *>(m());Executed by: 
 executed 197347 times by 153 tests:   } QV4::Heap::Proxy *d() const { QV4::Heap::Proxy *dptr = d_unchecked(); dptr->_checkIsInitialized(); returnreturn static_cast<QV4::Heap::Proxy *>(m());Executed by: 
 executed 98829 times by 153 tests:   dptr;return dptr;Executed by: 
 executed 98829 times by 153 tests:   } static_assert(bool(std::is_trivial< QV4::Heap::Proxy >::value), "std::is_trivial< QV4::Heap::Proxy >::value");return dptr;Executed by: 
  | 0-295978 | ||||||||||||
| 70 | - | |||||||||||||
| 71 | static ReturnedValue virtualCallAsConstructor(const FunctionObject *f, const Value *argv, int argc, const Value *); | - | ||||||||||||
| 72 | static ReturnedValue virtualCall(const FunctionObject *, const Value *thisObject, const Value *argv, int argc); | - | ||||||||||||
| 73 | - | |||||||||||||
| 74 | static ReturnedValue method_revocable(const FunctionObject *, const Value *thisObject, const Value *argv, int argc); | - | ||||||||||||
| 75 | - | |||||||||||||
| 76 | static ReturnedValue method_revoke(const FunctionObject *, const Value *thisObject, const Value *argv, int argc); | - | ||||||||||||
| 77 | }; | - | ||||||||||||
| 78 | - | |||||||||||||
| 79 | } | - | ||||||||||||
| 80 | - | |||||||||||||
| 81 | - | |||||||||||||
| Switch to Source code | Preprocessed file |