⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vt_test.h

📁 The library provides supports for run-time loaded plugin classes in C++
💻 H
字号:
// Copyright (c) 2007, Arne Steinarson// Licensing for DynObj project - see DynObj-license.txt in this folder#ifndef VT_TEST_H#define VT_TEST_H// Bit offsets in the traits field#define DO_TRAITS_MASK        0x0F#define DO_TRAITS_VT_ES			0	// Entry size divided by 4#define DO_TRAITS_VT_OFF_1ST	4	// void* offset to 1st entry#define DO_TRAITS_VT_OFF		8	// void* offset inside entry#define DO_TRAITS_VT_DEC		12	// Nr of slots used by virtual destructor#define DO_TRAITS_VT_DTOR_POS	15	// Destructor positioning 0 - first, 1 - at end#define DO_TRAITS_VT_IHP		16	// Inheritance padding #define DO_TRAITS_VT_ERROR    0x80000000	// Set if tests failed// The results of testsint doGetDoTraits();// Get the actual slot (void*) of index ixint VTableIndex( int ix );// Are the traits passed here compatible with current compiler/environment?// Returns <0 on error (incompatible)// 0 - Compatible, but virtual destructors use different count//     This is not an issue since don't use them by default.// 1 - Fully compatibleint VTableCompatible( int traits );// Default is to include only basic tests// Define VT_ALL_TESTS to include all testsint InheritPadding(); // >=0, 0 expectedint VTablePos( );	// 0 - at startint DtorEntries(); // >=1, 1 or 2 expectedint VTableEntrySize( int &off_first );#ifdef VT_ALL_TESTSint PodVTableSize();	// 0int Bc1VTableSize(); // 1int Bc3VTableSize();	// 3int Dc1VTableSize(); // 2int Dc3VTableSize(); // 5int CallThisTest();	// 0int CorrectVTableTest();	// 0int TestMembFuncPtr();	// 0int ObjectLayoutTest(); // 0 int InterfaceSize();	// 4/8 - sizeof(void*)int DtorPosition(); // 0-first, 1-at end#endif // VT_ALL_TESTS#endif // VT_TEST_H

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -