1 /* File generated automatically from tools/winapi/test.dat; do not edit! */
2 /* This file can be copied, modified and distributed without restriction. */
5 * Unit tests for data structure packing
10 #include "wine/test.h"
16 /***********************************************************************
17 * Windows API extension
20 #if (_MSC_VER >= 1300) && defined(__cplusplus)
21 # define FIELD_ALIGNMENT(type, field) __alignof(((type*)0)->field)
22 #elif defined(__GNUC__)
23 # define FIELD_ALIGNMENT(type, field) __alignof__(((type*)0)->field)
25 /* FIXME: Not sure if is possible to do without compiler extension */
28 /***********************************************************************
32 #ifdef FIELD_ALIGNMENT
33 # define TEST_FIELD_ALIGNMENT(type, field, align) \
34 ok(FIELD_ALIGNMENT(type, field) == align, \
35 "FIELD_ALIGNMENT(" #type ", " #field ") == %d (expected " #align ")", \
36 FIELD_ALIGNMENT(type, field))
38 # define TEST_FIELD_ALIGNMENT(type, field, align) do { } while (0)
41 #define TEST_FIELD_OFFSET(type, field, offset) \
42 ok(FIELD_OFFSET(type, field) == offset, \
43 "FIELD_OFFSET(" #type ", " #field ") == %ld (expected " #offset ")", \
44 FIELD_OFFSET(type, field))
46 #define TEST_TYPE_ALIGNMENT(type, align) \
47 ok(TYPE_ALIGNMENT(type) == align, "TYPE_ALIGNMENT(" #type ") == %d (expected " #align ")", TYPE_ALIGNMENT(type))
49 #define TEST_TYPE_SIZE(type, size) \
50 ok(sizeof(type) == size, "sizeof(" #type ") == %d (expected " #size ")", sizeof(type))
52 /***********************************************************************
56 #define TEST_FIELD(type, field_type, field_name, field_offset, field_size, field_align) \
57 TEST_TYPE_SIZE(field_type, field_size); \
58 TEST_FIELD_ALIGNMENT(type, field_name, field_align); \
59 TEST_FIELD_OFFSET(type, field_name, field_offset); \
61 #define TEST_TYPE(type, size, align) \
62 TEST_TYPE_ALIGNMENT(type, align); \
63 TEST_TYPE_SIZE(type, size)
67 /* BY_HANDLE_FILE_INFORMATION (pack 4) */
68 TEST_TYPE(BY_HANDLE_FILE_INFORMATION, 52, 4);
69 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, DWORD, dwFileAttributes, 0, 4, 4);
70 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, FILETIME, ftCreationTime, 4, 8, 4);
71 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, FILETIME, ftLastAccessTime, 12, 8, 4);
72 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, FILETIME, ftLastWriteTime, 20, 8, 4);
73 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, DWORD, dwVolumeSerialNumber, 28, 4, 4);
74 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, DWORD, nFileSizeHigh, 32, 4, 4);
75 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, DWORD, nFileSizeLow, 36, 4, 4);
76 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, DWORD, nNumberOfLinks, 40, 4, 4);
77 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, DWORD, nFileIndexHigh, 44, 4, 4);
78 TEST_FIELD(BY_HANDLE_FILE_INFORMATION, DWORD, nFileIndexLow, 48, 4, 4);
80 /* COMMCONFIG (pack 4) */
81 TEST_TYPE(COMMCONFIG, 52, 4);
82 TEST_FIELD(COMMCONFIG, DWORD, dwSize, 0, 4, 4);
83 TEST_FIELD(COMMCONFIG, WORD, wVersion, 4, 2, 2);
84 TEST_FIELD(COMMCONFIG, WORD, wReserved, 6, 2, 2);
85 TEST_FIELD(COMMCONFIG, DCB, dcb, 8, 28, 4);
86 TEST_FIELD(COMMCONFIG, DWORD, dwProviderSubType, 36, 4, 4);
87 TEST_FIELD(COMMCONFIG, DWORD, dwProviderOffset, 40, 4, 4);
88 TEST_FIELD(COMMCONFIG, DWORD, dwProviderSize, 44, 4, 4);
89 TEST_FIELD(COMMCONFIG, DWORD[1], wcProviderData, 48, 4, 4);
91 /* COMMPROP (pack 4) */
92 TEST_TYPE(COMMPROP, 64, 4);
93 TEST_FIELD(COMMPROP, WORD, wPacketLength, 0, 2, 2);
94 TEST_FIELD(COMMPROP, WORD, wPacketVersion, 2, 2, 2);
95 TEST_FIELD(COMMPROP, DWORD, dwServiceMask, 4, 4, 4);
96 TEST_FIELD(COMMPROP, DWORD, dwReserved1, 8, 4, 4);
97 TEST_FIELD(COMMPROP, DWORD, dwMaxTxQueue, 12, 4, 4);
98 TEST_FIELD(COMMPROP, DWORD, dwMaxRxQueue, 16, 4, 4);
99 TEST_FIELD(COMMPROP, DWORD, dwMaxBaud, 20, 4, 4);
100 TEST_FIELD(COMMPROP, DWORD, dwProvSubType, 24, 4, 4);
101 TEST_FIELD(COMMPROP, DWORD, dwProvCapabilities, 28, 4, 4);
102 TEST_FIELD(COMMPROP, DWORD, dwSettableParams, 32, 4, 4);
103 TEST_FIELD(COMMPROP, DWORD, dwSettableBaud, 36, 4, 4);
104 TEST_FIELD(COMMPROP, WORD, wSettableData, 40, 2, 2);
105 TEST_FIELD(COMMPROP, WORD, wSettableStopParity, 42, 2, 2);
106 TEST_FIELD(COMMPROP, DWORD, dwCurrentTxQueue, 44, 4, 4);
107 TEST_FIELD(COMMPROP, DWORD, dwCurrentRxQueue, 48, 4, 4);
108 TEST_FIELD(COMMPROP, DWORD, dwProvSpec1, 52, 4, 4);
109 TEST_FIELD(COMMPROP, DWORD, dwProvSpec2, 56, 4, 4);
110 TEST_FIELD(COMMPROP, WCHAR[1], wcProvChar, 60, 2, 2);
112 /* COMMTIMEOUTS (pack 4) */
113 TEST_TYPE(COMMTIMEOUTS, 20, 4);
114 TEST_FIELD(COMMTIMEOUTS, DWORD, ReadIntervalTimeout, 0, 4, 4);
115 TEST_FIELD(COMMTIMEOUTS, DWORD, ReadTotalTimeoutMultiplier, 4, 4, 4);
116 TEST_FIELD(COMMTIMEOUTS, DWORD, ReadTotalTimeoutConstant, 8, 4, 4);
117 TEST_FIELD(COMMTIMEOUTS, DWORD, WriteTotalTimeoutMultiplier, 12, 4, 4);
118 TEST_FIELD(COMMTIMEOUTS, DWORD, WriteTotalTimeoutConstant, 16, 4, 4);
120 /* COMSTAT (pack 4) */
121 TEST_TYPE(COMSTAT, 12, 4);
122 TEST_FIELD(COMSTAT, DWORD, status, 0, 4, 4);
123 TEST_FIELD(COMSTAT, DWORD, cbInQue, 4, 4, 4);
124 TEST_FIELD(COMSTAT, DWORD, cbOutQue, 8, 4, 4);
126 /* CREATE_PROCESS_DEBUG_INFO (pack 4) */
127 TEST_TYPE(CREATE_PROCESS_DEBUG_INFO, 40, 4);
128 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, HANDLE, hFile, 0, 4, 4);
129 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, HANDLE, hProcess, 4, 4, 4);
130 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, HANDLE, hThread, 8, 4, 4);
131 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, LPVOID, lpBaseOfImage, 12, 4, 4);
132 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, DWORD, dwDebugInfoFileOffset, 16, 4, 4);
133 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, DWORD, nDebugInfoSize, 20, 4, 4);
134 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, LPVOID, lpThreadLocalBase, 24, 4, 4);
135 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, LPTHREAD_START_ROUTINE, lpStartAddress, 28, 4, 4);
136 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, LPVOID, lpImageName, 32, 4, 4);
137 TEST_FIELD(CREATE_PROCESS_DEBUG_INFO, WORD, fUnicode, 36, 2, 2);
139 /* CREATE_THREAD_DEBUG_INFO (pack 4) */
140 TEST_TYPE(CREATE_THREAD_DEBUG_INFO, 12, 4);
141 TEST_FIELD(CREATE_THREAD_DEBUG_INFO, HANDLE, hThread, 0, 4, 4);
142 TEST_FIELD(CREATE_THREAD_DEBUG_INFO, LPVOID, lpThreadLocalBase, 4, 4, 4);
143 TEST_FIELD(CREATE_THREAD_DEBUG_INFO, LPTHREAD_START_ROUTINE, lpStartAddress, 8, 4, 4);
146 TEST_TYPE(DCB, 28, 4);
147 TEST_FIELD(DCB, DWORD, DCBlength, 0, 4, 4);
148 TEST_FIELD(DCB, DWORD, BaudRate, 4, 4, 4);
149 TEST_FIELD(DCB, WORD, wReserved, 12, 2, 2);
150 TEST_FIELD(DCB, WORD, XonLim, 14, 2, 2);
151 TEST_FIELD(DCB, WORD, XoffLim, 16, 2, 2);
152 TEST_FIELD(DCB, BYTE, ByteSize, 18, 1, 1);
153 TEST_FIELD(DCB, BYTE, Parity, 19, 1, 1);
154 TEST_FIELD(DCB, BYTE, StopBits, 20, 1, 1);
155 TEST_FIELD(DCB, char, XonChar, 21, 1, 1);
156 TEST_FIELD(DCB, char, XoffChar, 22, 1, 1);
157 TEST_FIELD(DCB, char, ErrorChar, 23, 1, 1);
158 TEST_FIELD(DCB, char, EofChar, 24, 1, 1);
159 TEST_FIELD(DCB, char, EvtChar, 25, 1, 1);
161 /* DEBUG_EVENT (pack 4) */
162 TEST_FIELD(DEBUG_EVENT, DWORD, dwDebugEventCode, 0, 4, 4);
163 TEST_FIELD(DEBUG_EVENT, DWORD, dwProcessId, 4, 4, 4);
164 TEST_FIELD(DEBUG_EVENT, DWORD, dwThreadId, 8, 4, 4);
166 /* EXCEPTION_DEBUG_INFO (pack 4) */
167 TEST_TYPE(EXCEPTION_DEBUG_INFO, 84, 4);
168 TEST_FIELD(EXCEPTION_DEBUG_INFO, EXCEPTION_RECORD, ExceptionRecord, 0, 80, 4);
169 TEST_FIELD(EXCEPTION_DEBUG_INFO, DWORD, dwFirstChance, 80, 4, 4);
171 /* EXIT_PROCESS_DEBUG_INFO (pack 4) */
172 TEST_TYPE(EXIT_PROCESS_DEBUG_INFO, 4, 4);
173 TEST_FIELD(EXIT_PROCESS_DEBUG_INFO, DWORD, dwExitCode, 0, 4, 4);
175 /* EXIT_THREAD_DEBUG_INFO (pack 4) */
176 TEST_TYPE(EXIT_THREAD_DEBUG_INFO, 4, 4);
177 TEST_FIELD(EXIT_THREAD_DEBUG_INFO, DWORD, dwExitCode, 0, 4, 4);
179 /* HW_PROFILE_INFOA (pack 4) */
180 TEST_TYPE(HW_PROFILE_INFOA, 124, 4);
181 TEST_FIELD(HW_PROFILE_INFOA, DWORD, dwDockInfo, 0, 4, 4);
182 TEST_FIELD(HW_PROFILE_INFOA, CHAR[HW_PROFILE_GUIDLEN], szHwProfileGuid, 4, 39, 1);
183 TEST_FIELD(HW_PROFILE_INFOA, CHAR[MAX_PROFILE_LEN], szHwProfileName, 43, 80, 1);
185 /* LDT_ENTRY (pack 4) */
186 TEST_FIELD(LDT_ENTRY, WORD, LimitLow, 0, 2, 2);
187 TEST_FIELD(LDT_ENTRY, WORD, BaseLow, 2, 2, 2);
189 /* LOAD_DLL_DEBUG_INFO (pack 4) */
190 TEST_TYPE(LOAD_DLL_DEBUG_INFO, 24, 4);
191 TEST_FIELD(LOAD_DLL_DEBUG_INFO, HANDLE, hFile, 0, 4, 4);
192 TEST_FIELD(LOAD_DLL_DEBUG_INFO, LPVOID, lpBaseOfDll, 4, 4, 4);
193 TEST_FIELD(LOAD_DLL_DEBUG_INFO, DWORD, dwDebugInfoFileOffset, 8, 4, 4);
194 TEST_FIELD(LOAD_DLL_DEBUG_INFO, DWORD, nDebugInfoSize, 12, 4, 4);
195 TEST_FIELD(LOAD_DLL_DEBUG_INFO, LPVOID, lpImageName, 16, 4, 4);
196 TEST_FIELD(LOAD_DLL_DEBUG_INFO, WORD, fUnicode, 20, 2, 2);
198 /* MEMORYSTATUS (pack 4) */
199 TEST_TYPE(MEMORYSTATUS, 32, 4);
200 TEST_FIELD(MEMORYSTATUS, DWORD, dwLength, 0, 4, 4);
201 TEST_FIELD(MEMORYSTATUS, DWORD, dwMemoryLoad, 4, 4, 4);
202 TEST_FIELD(MEMORYSTATUS, SIZE_T, dwTotalPhys, 8, 4, 4);
203 TEST_FIELD(MEMORYSTATUS, SIZE_T, dwAvailPhys, 12, 4, 4);
204 TEST_FIELD(MEMORYSTATUS, SIZE_T, dwTotalPageFile, 16, 4, 4);
205 TEST_FIELD(MEMORYSTATUS, SIZE_T, dwAvailPageFile, 20, 4, 4);
206 TEST_FIELD(MEMORYSTATUS, SIZE_T, dwTotalVirtual, 24, 4, 4);
207 TEST_FIELD(MEMORYSTATUS, SIZE_T, dwAvailVirtual, 28, 4, 4);
209 /* OFSTRUCT (pack 4) */
210 TEST_TYPE(OFSTRUCT, 136, 2);
211 TEST_FIELD(OFSTRUCT, BYTE, cBytes, 0, 1, 1);
212 TEST_FIELD(OFSTRUCT, BYTE, fFixedDisk, 1, 1, 1);
213 TEST_FIELD(OFSTRUCT, WORD, nErrCode, 2, 2, 2);
214 TEST_FIELD(OFSTRUCT, BYTE[4], reserved, 4, 4, 1);
215 TEST_FIELD(OFSTRUCT, BYTE[OFS_MAXPATHNAME], szPathName, 8, 128, 1);
217 /* OSVERSIONINFOA (pack 4) */
218 TEST_TYPE(OSVERSIONINFOA, 148, 4);
219 TEST_FIELD(OSVERSIONINFOA, DWORD, dwOSVersionInfoSize, 0, 4, 4);
220 TEST_FIELD(OSVERSIONINFOA, DWORD, dwMajorVersion, 4, 4, 4);
221 TEST_FIELD(OSVERSIONINFOA, DWORD, dwMinorVersion, 8, 4, 4);
222 TEST_FIELD(OSVERSIONINFOA, DWORD, dwBuildNumber, 12, 4, 4);
223 TEST_FIELD(OSVERSIONINFOA, DWORD, dwPlatformId, 16, 4, 4);
224 TEST_FIELD(OSVERSIONINFOA, CHAR[128], szCSDVersion, 20, 128, 1);
226 /* OSVERSIONINFOEXA (pack 4) */
227 TEST_TYPE(OSVERSIONINFOEXA, 156, 4);
228 TEST_FIELD(OSVERSIONINFOEXA, DWORD, dwOSVersionInfoSize, 0, 4, 4);
229 TEST_FIELD(OSVERSIONINFOEXA, DWORD, dwMajorVersion, 4, 4, 4);
230 TEST_FIELD(OSVERSIONINFOEXA, DWORD, dwMinorVersion, 8, 4, 4);
231 TEST_FIELD(OSVERSIONINFOEXA, DWORD, dwBuildNumber, 12, 4, 4);
232 TEST_FIELD(OSVERSIONINFOEXA, DWORD, dwPlatformId, 16, 4, 4);
233 TEST_FIELD(OSVERSIONINFOEXA, CHAR[128], szCSDVersion, 20, 128, 1);
234 TEST_FIELD(OSVERSIONINFOEXA, WORD, wServicePackMajor, 148, 2, 2);
235 TEST_FIELD(OSVERSIONINFOEXA, WORD, wServicePackMinor, 150, 2, 2);
236 TEST_FIELD(OSVERSIONINFOEXA, WORD, wSuiteMask, 152, 2, 2);
237 TEST_FIELD(OSVERSIONINFOEXA, BYTE, wProductType, 154, 1, 1);
238 TEST_FIELD(OSVERSIONINFOEXA, BYTE, wReserved, 155, 1, 1);
240 /* OSVERSIONINFOEXW (pack 4) */
241 TEST_TYPE(OSVERSIONINFOEXW, 284, 4);
242 TEST_FIELD(OSVERSIONINFOEXW, DWORD, dwOSVersionInfoSize, 0, 4, 4);
243 TEST_FIELD(OSVERSIONINFOEXW, DWORD, dwMajorVersion, 4, 4, 4);
244 TEST_FIELD(OSVERSIONINFOEXW, DWORD, dwMinorVersion, 8, 4, 4);
245 TEST_FIELD(OSVERSIONINFOEXW, DWORD, dwBuildNumber, 12, 4, 4);
246 TEST_FIELD(OSVERSIONINFOEXW, DWORD, dwPlatformId, 16, 4, 4);
247 TEST_FIELD(OSVERSIONINFOEXW, WCHAR[128], szCSDVersion, 20, 256, 2);
248 TEST_FIELD(OSVERSIONINFOEXW, WORD, wServicePackMajor, 276, 2, 2);
249 TEST_FIELD(OSVERSIONINFOEXW, WORD, wServicePackMinor, 278, 2, 2);
250 TEST_FIELD(OSVERSIONINFOEXW, WORD, wSuiteMask, 280, 2, 2);
251 TEST_FIELD(OSVERSIONINFOEXW, BYTE, wProductType, 282, 1, 1);
252 TEST_FIELD(OSVERSIONINFOEXW, BYTE, wReserved, 283, 1, 1);
254 /* OSVERSIONINFOW (pack 4) */
255 TEST_TYPE(OSVERSIONINFOW, 276, 4);
256 TEST_FIELD(OSVERSIONINFOW, DWORD, dwOSVersionInfoSize, 0, 4, 4);
257 TEST_FIELD(OSVERSIONINFOW, DWORD, dwMajorVersion, 4, 4, 4);
258 TEST_FIELD(OSVERSIONINFOW, DWORD, dwMinorVersion, 8, 4, 4);
259 TEST_FIELD(OSVERSIONINFOW, DWORD, dwBuildNumber, 12, 4, 4);
260 TEST_FIELD(OSVERSIONINFOW, DWORD, dwPlatformId, 16, 4, 4);
261 TEST_FIELD(OSVERSIONINFOW, WCHAR[128], szCSDVersion, 20, 256, 2);
263 /* OUTPUT_DEBUG_STRING_INFO (pack 4) */
264 TEST_TYPE(OUTPUT_DEBUG_STRING_INFO, 8, 4);
265 TEST_FIELD(OUTPUT_DEBUG_STRING_INFO, LPSTR, lpDebugStringData, 0, 4, 4);
266 TEST_FIELD(OUTPUT_DEBUG_STRING_INFO, WORD, fUnicode, 4, 2, 2);
267 TEST_FIELD(OUTPUT_DEBUG_STRING_INFO, WORD, nDebugStringLength, 6, 2, 2);
269 /* OVERLAPPED (pack 4) */
270 TEST_TYPE(OVERLAPPED, 20, 4);
271 TEST_FIELD(OVERLAPPED, DWORD, Internal, 0, 4, 4);
272 TEST_FIELD(OVERLAPPED, DWORD, InternalHigh, 4, 4, 4);
273 TEST_FIELD(OVERLAPPED, DWORD, Offset, 8, 4, 4);
274 TEST_FIELD(OVERLAPPED, DWORD, OffsetHigh, 12, 4, 4);
275 TEST_FIELD(OVERLAPPED, HANDLE, hEvent, 16, 4, 4);
277 /* PROCESS_HEAP_ENTRY (pack 4) */
278 TEST_FIELD(PROCESS_HEAP_ENTRY, LPVOID, lpData, 0, 4, 4);
279 TEST_FIELD(PROCESS_HEAP_ENTRY, DWORD, cbData, 4, 4, 4);
280 TEST_FIELD(PROCESS_HEAP_ENTRY, BYTE, cbOverhead, 8, 1, 1);
281 TEST_FIELD(PROCESS_HEAP_ENTRY, BYTE, iRegionIndex, 9, 1, 1);
282 TEST_FIELD(PROCESS_HEAP_ENTRY, WORD, wFlags, 10, 2, 2);
284 /* PROCESS_INFORMATION (pack 4) */
285 TEST_TYPE(PROCESS_INFORMATION, 16, 4);
286 TEST_FIELD(PROCESS_INFORMATION, HANDLE, hProcess, 0, 4, 4);
287 TEST_FIELD(PROCESS_INFORMATION, HANDLE, hThread, 4, 4, 4);
288 TEST_FIELD(PROCESS_INFORMATION, DWORD, dwProcessId, 8, 4, 4);
289 TEST_FIELD(PROCESS_INFORMATION, DWORD, dwThreadId, 12, 4, 4);
291 /* RIP_INFO (pack 4) */
292 TEST_TYPE(RIP_INFO, 8, 4);
293 TEST_FIELD(RIP_INFO, DWORD, dwError, 0, 4, 4);
294 TEST_FIELD(RIP_INFO, DWORD, dwType, 4, 4, 4);
296 /* SECURITY_ATTRIBUTES (pack 4) */
297 TEST_TYPE(SECURITY_ATTRIBUTES, 12, 4);
298 TEST_FIELD(SECURITY_ATTRIBUTES, DWORD, nLength, 0, 4, 4);
299 TEST_FIELD(SECURITY_ATTRIBUTES, LPVOID, lpSecurityDescriptor, 4, 4, 4);
300 TEST_FIELD(SECURITY_ATTRIBUTES, BOOL, bInheritHandle, 8, 4, 4);
302 /* STARTUPINFOA (pack 4) */
303 TEST_TYPE(STARTUPINFOA, 68, 4);
304 TEST_FIELD(STARTUPINFOA, DWORD, cb, 0, 4, 4);
305 TEST_FIELD(STARTUPINFOA, LPSTR, lpReserved, 4, 4, 4);
306 TEST_FIELD(STARTUPINFOA, LPSTR, lpDesktop, 8, 4, 4);
307 TEST_FIELD(STARTUPINFOA, LPSTR, lpTitle, 12, 4, 4);
308 TEST_FIELD(STARTUPINFOA, DWORD, dwX, 16, 4, 4);
309 TEST_FIELD(STARTUPINFOA, DWORD, dwY, 20, 4, 4);
310 TEST_FIELD(STARTUPINFOA, DWORD, dwXSize, 24, 4, 4);
311 TEST_FIELD(STARTUPINFOA, DWORD, dwYSize, 28, 4, 4);
312 TEST_FIELD(STARTUPINFOA, DWORD, dwXCountChars, 32, 4, 4);
313 TEST_FIELD(STARTUPINFOA, DWORD, dwYCountChars, 36, 4, 4);
314 TEST_FIELD(STARTUPINFOA, DWORD, dwFillAttribute, 40, 4, 4);
315 TEST_FIELD(STARTUPINFOA, DWORD, dwFlags, 44, 4, 4);
316 TEST_FIELD(STARTUPINFOA, WORD, wShowWindow, 48, 2, 2);
317 TEST_FIELD(STARTUPINFOA, WORD, cbReserved2, 50, 2, 2);
318 TEST_FIELD(STARTUPINFOA, BYTE *, lpReserved2, 52, 4, 4);
319 TEST_FIELD(STARTUPINFOA, HANDLE, hStdInput, 56, 4, 4);
320 TEST_FIELD(STARTUPINFOA, HANDLE, hStdOutput, 60, 4, 4);
321 TEST_FIELD(STARTUPINFOA, HANDLE, hStdError, 64, 4, 4);
323 /* STARTUPINFOW (pack 4) */
324 TEST_TYPE(STARTUPINFOW, 68, 4);
325 TEST_FIELD(STARTUPINFOW, DWORD, cb, 0, 4, 4);
326 TEST_FIELD(STARTUPINFOW, LPWSTR, lpReserved, 4, 4, 4);
327 TEST_FIELD(STARTUPINFOW, LPWSTR, lpDesktop, 8, 4, 4);
328 TEST_FIELD(STARTUPINFOW, LPWSTR, lpTitle, 12, 4, 4);
329 TEST_FIELD(STARTUPINFOW, DWORD, dwX, 16, 4, 4);
330 TEST_FIELD(STARTUPINFOW, DWORD, dwY, 20, 4, 4);
331 TEST_FIELD(STARTUPINFOW, DWORD, dwXSize, 24, 4, 4);
332 TEST_FIELD(STARTUPINFOW, DWORD, dwYSize, 28, 4, 4);
333 TEST_FIELD(STARTUPINFOW, DWORD, dwXCountChars, 32, 4, 4);
334 TEST_FIELD(STARTUPINFOW, DWORD, dwYCountChars, 36, 4, 4);
335 TEST_FIELD(STARTUPINFOW, DWORD, dwFillAttribute, 40, 4, 4);
336 TEST_FIELD(STARTUPINFOW, DWORD, dwFlags, 44, 4, 4);
337 TEST_FIELD(STARTUPINFOW, WORD, wShowWindow, 48, 2, 2);
338 TEST_FIELD(STARTUPINFOW, WORD, cbReserved2, 50, 2, 2);
339 TEST_FIELD(STARTUPINFOW, BYTE *, lpReserved2, 52, 4, 4);
340 TEST_FIELD(STARTUPINFOW, HANDLE, hStdInput, 56, 4, 4);
341 TEST_FIELD(STARTUPINFOW, HANDLE, hStdOutput, 60, 4, 4);
342 TEST_FIELD(STARTUPINFOW, HANDLE, hStdError, 64, 4, 4);
344 /* SYSLEVEL (pack 4) */
345 TEST_TYPE(SYSLEVEL, 28, 4);
346 TEST_FIELD(SYSLEVEL, CRITICAL_SECTION, crst, 0, 24, 4);
347 TEST_FIELD(SYSLEVEL, INT, level, 24, 4, 4);
349 /* SYSTEMTIME (pack 4) */
350 TEST_TYPE(SYSTEMTIME, 16, 2);
351 TEST_FIELD(SYSTEMTIME, WORD, wYear, 0, 2, 2);
352 TEST_FIELD(SYSTEMTIME, WORD, wMonth, 2, 2, 2);
353 TEST_FIELD(SYSTEMTIME, WORD, wDayOfWeek, 4, 2, 2);
354 TEST_FIELD(SYSTEMTIME, WORD, wDay, 6, 2, 2);
355 TEST_FIELD(SYSTEMTIME, WORD, wHour, 8, 2, 2);
356 TEST_FIELD(SYSTEMTIME, WORD, wMinute, 10, 2, 2);
357 TEST_FIELD(SYSTEMTIME, WORD, wSecond, 12, 2, 2);
358 TEST_FIELD(SYSTEMTIME, WORD, wMilliseconds, 14, 2, 2);
360 /* SYSTEM_POWER_STATUS (pack 4) */
361 TEST_TYPE(SYSTEM_POWER_STATUS, 12, 4);
362 TEST_FIELD(SYSTEM_POWER_STATUS, BYTE, ACLineStatus, 0, 1, 1);
363 TEST_FIELD(SYSTEM_POWER_STATUS, BYTE, BatteryFlag, 1, 1, 1);
364 TEST_FIELD(SYSTEM_POWER_STATUS, BYTE, BatteryLifePercent, 2, 1, 1);
365 TEST_FIELD(SYSTEM_POWER_STATUS, BYTE, reserved, 3, 1, 1);
366 TEST_FIELD(SYSTEM_POWER_STATUS, DWORD, BatteryLifeTime, 4, 4, 4);
367 TEST_FIELD(SYSTEM_POWER_STATUS, DWORD, BatteryFullLifeTime, 8, 4, 4);
369 /* TIME_ZONE_INFORMATION (pack 4) */
370 TEST_TYPE(TIME_ZONE_INFORMATION, 172, 4);
371 TEST_FIELD(TIME_ZONE_INFORMATION, LONG, Bias, 0, 4, 4);
372 TEST_FIELD(TIME_ZONE_INFORMATION, WCHAR[32], StandardName, 4, 64, 2);
373 TEST_FIELD(TIME_ZONE_INFORMATION, SYSTEMTIME, StandardDate, 68, 16, 2);
374 TEST_FIELD(TIME_ZONE_INFORMATION, LONG, StandardBias, 84, 4, 4);
375 TEST_FIELD(TIME_ZONE_INFORMATION, WCHAR[32], DaylightName, 88, 64, 2);
376 TEST_FIELD(TIME_ZONE_INFORMATION, SYSTEMTIME, DaylightDate, 152, 16, 2);
377 TEST_FIELD(TIME_ZONE_INFORMATION, LONG, DaylightBias, 168, 4, 4);
379 /* UNLOAD_DLL_DEBUG_INFO (pack 4) */
380 TEST_TYPE(UNLOAD_DLL_DEBUG_INFO, 4, 4);
381 TEST_FIELD(UNLOAD_DLL_DEBUG_INFO, LPVOID, lpBaseOfDll, 0, 4, 4);
383 /* WIN32_FILE_ATTRIBUTE_DATA (pack 4) */
384 TEST_TYPE(WIN32_FILE_ATTRIBUTE_DATA, 36, 4);
385 TEST_FIELD(WIN32_FILE_ATTRIBUTE_DATA, DWORD, dwFileAttributes, 0, 4, 4);
386 TEST_FIELD(WIN32_FILE_ATTRIBUTE_DATA, FILETIME, ftCreationTime, 4, 8, 4);
387 TEST_FIELD(WIN32_FILE_ATTRIBUTE_DATA, FILETIME, ftLastAccessTime, 12, 8, 4);
388 TEST_FIELD(WIN32_FILE_ATTRIBUTE_DATA, FILETIME, ftLastWriteTime, 20, 8, 4);
389 TEST_FIELD(WIN32_FILE_ATTRIBUTE_DATA, DWORD, nFileSizeHigh, 28, 4, 4);
390 TEST_FIELD(WIN32_FILE_ATTRIBUTE_DATA, DWORD, nFileSizeLow, 32, 4, 4);
392 /* WIN32_FIND_DATAA (pack 4) */
393 TEST_TYPE(WIN32_FIND_DATAA, 320, 4);
394 TEST_FIELD(WIN32_FIND_DATAA, DWORD, dwFileAttributes, 0, 4, 4);
395 TEST_FIELD(WIN32_FIND_DATAA, FILETIME, ftCreationTime, 4, 8, 4);
396 TEST_FIELD(WIN32_FIND_DATAA, FILETIME, ftLastAccessTime, 12, 8, 4);
397 TEST_FIELD(WIN32_FIND_DATAA, FILETIME, ftLastWriteTime, 20, 8, 4);
398 TEST_FIELD(WIN32_FIND_DATAA, DWORD, nFileSizeHigh, 28, 4, 4);
399 TEST_FIELD(WIN32_FIND_DATAA, DWORD, nFileSizeLow, 32, 4, 4);
400 TEST_FIELD(WIN32_FIND_DATAA, DWORD, dwReserved0, 36, 4, 4);
401 TEST_FIELD(WIN32_FIND_DATAA, DWORD, dwReserved1, 40, 4, 4);
402 TEST_FIELD(WIN32_FIND_DATAA, CHAR[260], cFileName, 44, 260, 1);
403 TEST_FIELD(WIN32_FIND_DATAA, CHAR[14], cAlternateFileName, 304, 14, 1);
405 /* WIN32_FIND_DATAW (pack 4) */
406 TEST_TYPE(WIN32_FIND_DATAW, 592, 4);
407 TEST_FIELD(WIN32_FIND_DATAW, DWORD, dwFileAttributes, 0, 4, 4);
408 TEST_FIELD(WIN32_FIND_DATAW, FILETIME, ftCreationTime, 4, 8, 4);
409 TEST_FIELD(WIN32_FIND_DATAW, FILETIME, ftLastAccessTime, 12, 8, 4);
410 TEST_FIELD(WIN32_FIND_DATAW, FILETIME, ftLastWriteTime, 20, 8, 4);
411 TEST_FIELD(WIN32_FIND_DATAW, DWORD, nFileSizeHigh, 28, 4, 4);
412 TEST_FIELD(WIN32_FIND_DATAW, DWORD, nFileSizeLow, 32, 4, 4);
413 TEST_FIELD(WIN32_FIND_DATAW, DWORD, dwReserved0, 36, 4, 4);
414 TEST_FIELD(WIN32_FIND_DATAW, DWORD, dwReserved1, 40, 4, 4);
415 TEST_FIELD(WIN32_FIND_DATAW, WCHAR[260], cFileName, 44, 520, 2);
416 TEST_FIELD(WIN32_FIND_DATAW, WCHAR[14], cAlternateFileName, 564, 28, 2);
418 /* WIN32_STREAM_ID (pack 4) */
419 TEST_TYPE(WIN32_STREAM_ID, 24, 4);
420 TEST_FIELD(WIN32_STREAM_ID, DWORD, dwStreamID, 0, 4, 4);
421 TEST_FIELD(WIN32_STREAM_ID, DWORD, dwStreamAttributes, 4, 4, 4);
422 TEST_FIELD(WIN32_STREAM_ID, LARGE_INTEGER, Size, 8, 8, 4);
423 TEST_FIELD(WIN32_STREAM_ID, DWORD, dwStreamNameSize, 16, 4, 4);
424 TEST_FIELD(WIN32_STREAM_ID, WCHAR[ANYSIZE_ARRAY], cStreamName, 20, 2, 2);
428 START_TEST(generated)