#define VPTR_ABSTRACT_VTABLE_CLASS(name, base) \
public: name(TADDR addr, TADDR vtAddr) : base(addr, vtAddr) {}
+#define VPTR_ABSTRACT_VTABLE_CLASS_AND_CTOR(name, base) \
+ VPTR_ABSTRACT_VTABLE_CLASS(name, base)
+
#define VPTR_ABSTRACT_VTABLE_CLASS_NO_CTOR_BODY(name, base) \
public: name(TADDR addr, TADDR vtAddr);
friend struct _DacGlobals; \
public: name(int dummy) : base(dummy) {}
+#define VPTR_ABSTRACT_VTABLE_CLASS_AND_CTOR(name, base) \
+ VPTR_ABSTRACT_VTABLE_CLASS(name, base) \
+ name() : base() {}
+
#else // FEATURE_PAL
#define VPTR_VTABLE_CLASS(name, base)
#define VPTR_BASE_VTABLE_CLASS(name)
#define VPTR_BASE_VTABLE_CLASS_AND_CTOR(name)
#define VPTR_ABSTRACT_VTABLE_CLASS(name, base)
+#define VPTR_ABSTRACT_VTABLE_CLASS_AND_CTOR(name, base)
#endif // FEATURE_PAL
VPTR_CLASS(AppDomainLoaderAllocator)
VPTR_CLASS(AssemblyLoaderAllocator)
-#ifndef FEATURE_PAL
VPTR_CLASS(AssemblySecurityDescriptor)
VPTR_CLASS(ApplicationSecurityDescriptor)
-#endif // FEATURE_PAL
class ISecurityDescriptor
{
public:
-#ifndef FEATURE_PAL
- VPTR_BASE_VTABLE_CLASS(ISecurityDescriptor)
-#endif
+ VPTR_BASE_VTABLE_CLASS_AND_CTOR(ISecurityDescriptor)
+
virtual ~ISecurityDescriptor() { LIMITED_METHOD_CONTRACT; }
virtual BOOL IsFullyTrusted() = 0;
class IApplicationSecurityDescriptor : public ISecurityDescriptor
{
public:
-#ifndef FEATURE_PAL
- VPTR_ABSTRACT_VTABLE_CLASS(IApplicationSecurityDescriptor, ISecurityDescriptor)
-#endif
+ VPTR_ABSTRACT_VTABLE_CLASS_AND_CTOR(IApplicationSecurityDescriptor, ISecurityDescriptor)
#ifndef DACCESS_COMPILE
public:
class IAssemblySecurityDescriptor : public ISecurityDescriptor
{
public:
-#ifndef FEATURE_PAL
- VPTR_ABSTRACT_VTABLE_CLASS(IAssemblySecurityDescriptor, ISecurityDescriptor)
-#endif
+ VPTR_ABSTRACT_VTABLE_CLASS_AND_CTOR(IAssemblySecurityDescriptor, ISecurityDescriptor)
#ifndef DACCESS_COMPILE
virtual SharedSecurityDescriptor *GetSharedSecDesc() = 0;
//--------------------
#ifndef DACCESS_COMPILE
inline SecurityDescriptor(AppDomain *pAppDomain, DomainAssembly *pAssembly, PEFile* pPEFile, LoaderAllocator *pLoaderAllocator);
-#endif // #ifndef DACCESS_COMPILE
+#ifdef FEATURE_PAL
+ SecurityDescriptor() {}
+#endif // FEATURE_PAL
+#endif // !DACCESS_COMPILE
};
template<typename IT>
class SecurityDescriptorBase : public IT, public SecurityDescriptor
{
public:
-#ifndef FEATURE_PAL
VPTR_ABSTRACT_VTABLE_CLASS(SecurityDescriptorBase, IT) // needed for the DAC
-#endif
inline SecurityDescriptorBase(AppDomain *pAppDomain, DomainAssembly *pAssembly, PEFile* pPEFile, LoaderAllocator *pLoaderAllocator);
class ApplicationSecurityDescriptor : public SecurityDescriptorBase<IApplicationSecurityDescriptor>
{
public:
-#ifndef FEATURE_PAL
VPTR_VTABLE_CLASS(ApplicationSecurityDescriptor, SecurityDescriptorBase<IApplicationSecurityDescriptor>)
-#endif
private:
// Dependency in managed : System.Security.HostSecurityManager.cs
class AssemblySecurityDescriptor : public SecurityDescriptorBase<IAssemblySecurityDescriptor>
{
public:
-#ifndef FEATURE_PAL
VPTR_VTABLE_CLASS(AssemblySecurityDescriptor, SecurityDescriptorBase<IAssemblySecurityDescriptor>)
-#endif
private:
PsetCacheEntry* m_arrPassedLinktimeDemands[MAX_PASSED_DEMANDS];