FreeRDP
spec.h
1 
20 #ifndef WINPR_SPEC_H
21 #define WINPR_SPEC_H
22 
23 #include <winpr/platform.h>
24 
25 WINPR_PRAGMA_DIAG_PUSH
26 WINPR_PRAGMA_DIAG_IGNORED_RESERVED_ID_MACRO
27 WINPR_PRAGMA_DIAG_IGNORED_RESERVED_IDENTIFIER
28 
29 #ifdef _WIN32
30 
31 #include <specstrings.h>
32 #ifndef _COM_Outptr_
33 #define _COM_Outptr_
34 #endif
35 
36 #else
37 
38 #if defined(NONAMELESSUNION)
39 #define DUMMYUNIONNAME u
40 #define DUMMYUNIONNAME1 u1
41 #define DUMMYUNIONNAME2 u2
42 #define DUMMYUNIONNAME3 u3
43 #define DUMMYUNIONNAME4 u4
44 #define DUMMYUNIONNAME5 u5
45 #define DUMMYUNIONNAME6 u6
46 #define DUMMYUNIONNAME7 u7
47 #define DUMMYUNIONNAME8 u8
48 
49 #define DUMMYSTRUCTNAME s
50 #define DUMMYSTRUCTNAME1 s1
51 #define DUMMYSTRUCTNAME2 s2
52 #define DUMMYSTRUCTNAME3 s3
53 #define DUMMYSTRUCTNAME4 s4
54 #define DUMMYSTRUCTNAME5 s5
55 #else
56 #define DUMMYUNIONNAME
57 #define DUMMYUNIONNAME1
58 #define DUMMYUNIONNAME2
59 #define DUMMYUNIONNAME3
60 #define DUMMYUNIONNAME4
61 #define DUMMYUNIONNAME5
62 #define DUMMYUNIONNAME6
63 #define DUMMYUNIONNAME7
64 #define DUMMYUNIONNAME8
65 
66 #define DUMMYSTRUCTNAME
67 #define DUMMYSTRUCTNAME1
68 #define DUMMYSTRUCTNAME2
69 #define DUMMYSTRUCTNAME3
70 #define DUMMYSTRUCTNAME4
71 #define DUMMYSTRUCTNAME5
72 #endif
73 
74 #if (defined(_M_AMD64) || defined(_M_ARM)) && !defined(_WIN32)
75 #define _UNALIGNED __unaligned
76 #else
77 #define _UNALIGNED
78 #endif
79 
80 #ifndef DECLSPEC_ALIGN
81 #if defined(_MSC_VER) && (_MSC_VER >= 1300) && !defined(MIDL_PASS)
82 #define DECLSPEC_ALIGN(x) __declspec(align(x))
83 #elif defined(__GNUC__)
84 #define DECLSPEC_ALIGN(x) __attribute__((__aligned__(x)))
85 #else
86 #define DECLSPEC_ALIGN(x)
87 #endif
88 #endif /* DECLSPEC_ALIGN */
89 
90 #ifdef _M_AMD64
91 #define MEMORY_ALLOCATION_ALIGNMENT 16
92 #else
93 #define MEMORY_ALLOCATION_ALIGNMENT 8
94 #endif
95 
96 #ifdef __GNUC__
97 #ifndef __declspec
98 #define __declspec(e) __attribute__((e))
99 #endif
100 #endif
101 
102 #ifndef DECLSPEC_NORETURN
103 #if (defined(__GNUC__) || defined(_MSC_VER) || defined(__clang__))
104 #define DECLSPEC_NORETURN __declspec(noreturn)
105 #else
106 #define DECLSPEC_NORETURN
107 #endif
108 #endif /* DECLSPEC_NORETURN */
109 
115 #define __field_bcount(size) __notnull __byte_writableTo(size)
116 #define __field_ecount(size) __notnull __elem_writableTo(size)
117 #define __post_invalid _Post_ __notvalid
118 
119 #define __deref_in
120 #define __deref_in_ecount(size)
121 #define __deref_in_bcount(size)
122 #define __deref_in_opt
123 #define __deref_in_ecount_opt(size)
124 #define __deref_in_bcount_opt(size)
125 #define __deref_opt_in
126 #define __deref_opt_in_ecount(size)
127 #define __deref_opt_in_bcount(size)
128 #define __deref_opt_in_opt
129 #define __deref_opt_in_ecount_opt(size)
130 #define __deref_opt_in_bcount_opt(size)
131 #define __out_awcount(expr, size)
132 #define __in_awcount(expr, size)
133 #define __nullnullterminated
134 #define __in_data_source(src_sym)
135 #define __kernel_entry
136 #define __out_data_source(src_sym)
137 #define __analysis_noreturn
138 #define _Check_return_opt_
139 #define _Check_return_wat_
140 
141 #define __inner_exceptthat
142 #define __inner_typefix(ctype)
143 #define _Always_(annos)
144 #define _Analysis_noreturn_
145 #define _Analysis_assume_(expr)
146 #define _At_(target, annos)
147 #define _At_buffer_(target, iter, bound, annos)
148 #define _Check_return_
149 #define _COM_Outptr_
150 #define _COM_Outptr_opt_
151 #define _COM_Outptr_opt_result_maybenull_
152 #define _COM_Outptr_result_maybenull_
153 #define _Const_
154 #define _Deref_in_bound_
155 #define _Deref_in_range_(lb, ub)
156 #define _Deref_inout_bound_
157 #define _Deref_inout_z_
158 #define _Deref_inout_z_bytecap_c_(size)
159 #define _Deref_inout_z_cap_c_(size)
160 #define _Deref_opt_out_
161 #define _Deref_opt_out_opt_
162 #define _Deref_opt_out_opt_z_
163 #define _Deref_opt_out_z_
164 #define _Deref_out_
165 #define _Deref_out_bound_
166 #define _Deref_out_opt_
167 #define _Deref_out_opt_z_
168 #define _Deref_out_range_(lb, ub)
169 #define _Deref_out_z_
170 #define _Deref_out_z_bytecap_c_(size)
171 #define _Deref_out_z_cap_c_(size)
172 #define _Deref_post_bytecap_(size)
173 #define _Deref_post_bytecap_c_(size)
174 #define _Deref_post_bytecap_x_(size)
175 #define _Deref_post_bytecount_(size)
176 #define _Deref_post_bytecount_c_(size)
177 #define _Deref_post_bytecount_x_(size)
178 #define _Deref_post_cap_(size)
179 #define _Deref_post_cap_c_(size)
180 #define _Deref_post_cap_x_(size)
181 #define _Deref_post_count_(size)
182 #define _Deref_post_count_c_(size)
183 #define _Deref_post_count_x_(size)
184 #define _Deref_post_maybenull_
185 #define _Deref_post_notnull_
186 #define _Deref_post_null_
187 #define _Deref_post_opt_bytecap_(size)
188 #define _Deref_post_opt_bytecap_c_(size)
189 #define _Deref_post_opt_bytecap_x_(size)
190 #define _Deref_post_opt_bytecount_(size)
191 #define _Deref_post_opt_bytecount_c_(size)
192 #define _Deref_post_opt_bytecount_x_(size)
193 #define _Deref_post_opt_cap_(size)
194 #define _Deref_post_opt_cap_c_(size)
195 #define _Deref_post_opt_cap_x_(size)
196 #define _Deref_post_opt_count_(size)
197 #define _Deref_post_opt_count_c_(size)
198 #define _Deref_post_opt_count_x_(size)
199 #define _Deref_post_opt_valid_
200 #define _Deref_post_opt_valid_bytecap_(size)
201 #define _Deref_post_opt_valid_bytecap_c_(size)
202 #define _Deref_post_opt_valid_bytecap_x_(size)
203 #define _Deref_post_opt_valid_cap_(size)
204 #define _Deref_post_opt_valid_cap_c_(size)
205 #define _Deref_post_opt_valid_cap_x_(size)
206 #define _Deref_post_opt_z_
207 #define _Deref_post_opt_z_bytecap_(size)
208 #define _Deref_post_opt_z_bytecap_c_(size)
209 #define _Deref_post_opt_z_bytecap_x_(size)
210 #define _Deref_post_opt_z_cap_(size)
211 #define _Deref_post_opt_z_cap_c_(size)
212 #define _Deref_post_opt_z_cap_x_(size)
213 #define _Deref_post_valid_
214 #define _Deref_post_valid_bytecap_(size)
215 #define _Deref_post_valid_bytecap_c_(size)
216 #define _Deref_post_valid_bytecap_x_(size)
217 #define _Deref_post_valid_cap_(size)
218 #define _Deref_post_valid_cap_c_(size)
219 #define _Deref_post_valid_cap_x_(size)
220 #define _Deref_post_z_
221 #define _Deref_post_z_bytecap_(size)
222 #define _Deref_post_z_bytecap_c_(size)
223 #define _Deref_post_z_bytecap_x_(size)
224 #define _Deref_post_z_cap_(size)
225 #define _Deref_post_z_cap_c_(size)
226 #define _Deref_post_z_cap_x_(size)
227 #define _Deref_pre_bytecap_(size)
228 #define _Deref_pre_bytecap_c_(size)
229 #define _Deref_pre_bytecap_x_(size)
230 #define _Deref_pre_bytecount_(size)
231 #define _Deref_pre_bytecount_c_(size)
232 #define _Deref_pre_bytecount_x_(size)
233 #define _Deref_pre_cap_(size)
234 #define _Deref_pre_cap_c_(size)
235 #define _Deref_pre_cap_x_(size)
236 #define _Deref_pre_count_(size)
237 #define _Deref_pre_count_c_(size)
238 #define _Deref_pre_count_x_(size)
239 #define _Deref_pre_invalid_
240 #define _Deref_pre_maybenull_
241 #define _Deref_pre_notnull_
242 #define _Deref_pre_null_
243 #define _Deref_pre_opt_bytecap_(size)
244 #define _Deref_pre_opt_bytecap_c_(size)
245 #define _Deref_pre_opt_bytecap_x_(size)
246 #define _Deref_pre_opt_bytecount_(size)
247 #define _Deref_pre_opt_bytecount_c_(size)
248 #define _Deref_pre_opt_bytecount_x_(size)
249 #define _Deref_pre_opt_cap_(size)
250 #define _Deref_pre_opt_cap_c_(size)
251 #define _Deref_pre_opt_cap_x_(size)
252 #define _Deref_pre_opt_count_(size)
253 #define _Deref_pre_opt_count_c_(size)
254 #define _Deref_pre_opt_count_x_(size)
255 #define _Deref_pre_opt_valid_
256 #define _Deref_pre_opt_valid_bytecap_(size)
257 #define _Deref_pre_opt_valid_bytecap_c_(size)
258 #define _Deref_pre_opt_valid_bytecap_x_(size)
259 #define _Deref_pre_opt_valid_cap_(size)
260 #define _Deref_pre_opt_valid_cap_c_(size)
261 #define _Deref_pre_opt_valid_cap_x_(size)
262 #define _Deref_pre_opt_z_
263 #define _Deref_pre_opt_z_bytecap_(size)
264 #define _Deref_pre_opt_z_bytecap_c_(size)
265 #define _Deref_pre_opt_z_bytecap_x_(size)
266 #define _Deref_pre_opt_z_cap_(size)
267 #define _Deref_pre_opt_z_cap_c_(size)
268 #define _Deref_pre_opt_z_cap_x_(size)
269 #define _Deref_pre_readonly_
270 #define _Deref_pre_valid_
271 #define _Deref_pre_valid_bytecap_(size)
272 #define _Deref_pre_valid_bytecap_c_(size)
273 #define _Deref_pre_valid_bytecap_x_(size)
274 #define _Deref_pre_valid_cap_(size)
275 #define _Deref_pre_valid_cap_c_(size)
276 #define _Deref_pre_valid_cap_x_(size)
277 #define _Deref_pre_writeonly_
278 #define _Deref_pre_z_
279 #define _Deref_pre_z_bytecap_(size)
280 #define _Deref_pre_z_bytecap_c_(size)
281 #define _Deref_pre_z_bytecap_x_(size)
282 #define _Deref_pre_z_cap_(size)
283 #define _Deref_pre_z_cap_c_(size)
284 #define _Deref_pre_z_cap_x_(size)
285 #define _Deref_prepost_bytecap_(size)
286 #define _Deref_prepost_bytecap_x_(size)
287 #define _Deref_prepost_bytecount_(size)
288 #define _Deref_prepost_bytecount_x_(size)
289 #define _Deref_prepost_cap_(size)
290 #define _Deref_prepost_cap_x_(size)
291 #define _Deref_prepost_count_(size)
292 #define _Deref_prepost_count_x_(size)
293 #define _Deref_prepost_opt_bytecap_(size)
294 #define _Deref_prepost_opt_bytecap_x_(size)
295 #define _Deref_prepost_opt_bytecount_(size)
296 #define _Deref_prepost_opt_bytecount_x_(size)
297 #define _Deref_prepost_opt_cap_(size)
298 #define _Deref_prepost_opt_cap_x_(size)
299 #define _Deref_prepost_opt_count_(size)
300 #define _Deref_prepost_opt_count_x_(size)
301 #define _Deref_prepost_opt_valid_
302 #define _Deref_prepost_opt_valid_bytecap_(size)
303 #define _Deref_prepost_opt_valid_bytecap_x_(size)
304 #define _Deref_prepost_opt_valid_cap_(size)
305 #define _Deref_prepost_opt_valid_cap_x_(size)
306 #define _Deref_prepost_opt_z_
307 #define _Deref_prepost_opt_z_bytecap_(size)
308 #define _Deref_prepost_opt_z_cap_(size)
309 #define _Deref_prepost_valid_
310 #define _Deref_prepost_valid_bytecap_(size)
311 #define _Deref_prepost_valid_bytecap_x_(size)
312 #define _Deref_prepost_valid_cap_(size)
313 #define _Deref_prepost_valid_cap_x_(size)
314 #define _Deref_prepost_z_
315 #define _Deref_prepost_z_bytecap_(size)
316 #define _Deref_prepost_z_cap_(size)
317 #define _Deref_ret_bound_
318 #define _Deref_ret_opt_z_
319 #define _Deref_ret_range_(lb, ub)
320 #define _Deref_ret_z_
321 #define _Deref2_pre_readonly_
322 #define _Field_range_(min, max)
323 #define _Field_size_(size)
324 #define _Field_size_bytes_(size)
325 #define _Field_size_bytes_full_(size)
326 #define _Field_size_bytes_full_opt_(size)
327 #define _Field_size_bytes_opt_(size)
328 #define _Field_size_bytes_part_(size, count)
329 #define _Field_size_bytes_part_opt_(size, count)
330 #define _Field_size_full_(size)
331 #define _Field_size_full_opt_(size)
332 #define _Field_size_opt_(size)
333 #define _Field_size_part_(size, count)
334 #define _Field_size_part_opt_(size, count)
335 #define _Field_z_
336 #define _Function_class_(x)
337 #define _Group_(annos)
338 #define _In_
339 #define _In_bound_
340 #define _In_bytecount_(size)
341 #define _In_bytecount_c_(size)
342 #define _In_bytecount_x_(size)
343 #define _In_count_(size)
344 #define _In_count_c_(size)
345 #define _In_count_x_(size)
346 #define _In_defensive_(annotates)
347 #define _In_opt_
348 #define _In_opt_bytecount_(size)
349 #define _In_opt_bytecount_c_(size)
350 #define _In_opt_bytecount_x_(size)
351 #define _In_opt_count_(size)
352 #define _In_opt_count_c_(size)
353 #define _In_opt_count_x_(size)
354 #define _In_opt_ptrdiff_count_(size)
355 #define _In_opt_z_
356 #define _In_opt_z_bytecount_(size)
357 #define _In_opt_z_bytecount_c_(size)
358 #define _In_opt_z_count_(size)
359 #define _In_opt_z_count_c_(size)
360 #define _In_ptrdiff_count_(size)
361 #define _In_range_(lb, ub)
362 #define _In_reads_(size)
363 #define _In_reads_bytes_(size)
364 #define _In_reads_bytes_opt_(size)
365 #define _In_reads_opt_(size)
366 #define _In_reads_opt_z_(size)
367 #define _In_reads_or_z_(size)
368 #define _In_reads_to_ptr_(ptr)
369 #define _In_reads_to_ptr_opt_(ptr)
370 #define _In_reads_to_ptr_opt_z_(ptr)
371 #define _In_reads_to_ptr_z_(ptr)
372 #define _In_reads_z_(size)
373 #define _In_z_
374 #define _In_z_bytecount_(size)
375 #define _In_z_bytecount_c_(size)
376 #define _In_z_count_(size)
377 #define _In_z_count_c_(size)
378 #define _Inout_
379 #define _Inout_bytecap_(size)
380 #define _Inout_bytecap_c_(size)
381 #define _Inout_bytecap_x_(size)
382 #define _Inout_bytecount_(size)
383 #define _Inout_bytecount_c_(size)
384 #define _Inout_bytecount_x_(size)
385 #define _Inout_cap_(size)
386 #define _Inout_cap_c_(size)
387 #define _Inout_cap_x_(size)
388 #define _Inout_count_(size)
389 #define _Inout_count_c_(size)
390 #define _Inout_count_x_(size)
391 #define _Inout_defensive_(annotates)
392 #define _Inout_opt_
393 #define _Inout_opt_bytecap_(size)
394 #define _Inout_opt_bytecap_c_(size)
395 #define _Inout_opt_bytecap_x_(size)
396 #define _Inout_opt_bytecount_(size)
397 #define _Inout_opt_bytecount_c_(size)
398 #define _Inout_opt_bytecount_x_(size)
399 #define _Inout_opt_cap_(size)
400 #define _Inout_opt_cap_c_(size)
401 #define _Inout_opt_cap_x_(size)
402 #define _Inout_opt_count_(size)
403 #define _Inout_opt_count_c_(size)
404 #define _Inout_opt_count_x_(size)
405 #define _Inout_opt_ptrdiff_count_(size)
406 #define _Inout_opt_z_
407 #define _Inout_opt_z_bytecap_(size)
408 #define _Inout_opt_z_bytecap_c_(size)
409 #define _Inout_opt_z_bytecap_x_(size)
410 #define _Inout_opt_z_bytecount_(size)
411 #define _Inout_opt_z_bytecount_c_(size)
412 #define _Inout_opt_z_cap_(size)
413 #define _Inout_opt_z_cap_c_(size)
414 #define _Inout_opt_z_cap_x_(size)
415 #define _Inout_opt_z_count_(size)
416 #define _Inout_opt_z_count_c_(size)
417 #define _Inout_ptrdiff_count_(size)
418 #define _Inout_updates_(size)
419 #define _Inout_updates_all_(size)
420 #define _Inout_updates_all_opt_(size)
421 #define _Inout_updates_bytes_(size)
422 #define _Inout_updates_bytes_all_(size)
423 #define _Inout_updates_bytes_all_opt_(size)
424 #define _Inout_updates_bytes_opt_(size)
425 #define _Inout_updates_bytes_to_(size, count)
426 #define _Inout_updates_bytes_to_opt_(size, count)
427 #define _Inout_updates_opt_(size)
428 #define _Inout_updates_opt_z_(size)
429 #define _Inout_updates_to_(size, count)
430 #define _Inout_updates_to_opt_(size, count)
431 #define _Inout_updates_z_(size)
432 #define _Inout_z_
433 #define _Inout_z_bytecap_(size)
434 #define _Inout_z_bytecap_c_(size)
435 #define _Inout_z_bytecap_x_(size)
436 #define _Inout_z_bytecount_(size)
437 #define _Inout_z_bytecount_c_(size)
438 #define _Inout_z_cap_(size)
439 #define _Inout_z_cap_c_(size)
440 #define _Inout_z_cap_x_(size)
441 #define _Inout_z_count_(size)
442 #define _Inout_z_count_c_(size)
443 #define _Interlocked_operand_
444 #define _Literal_
445 #define _Maybenull_
446 #define _Maybevalid_
447 #define _Maybe_raises_SEH_exception
448 #define _Must_inspect_result_
449 #define _Notliteral_
450 #define _Notnull_
451 #define _Notref_
452 #define _Notvalid_
453 #define _Null_
454 #define _Null_terminated_
455 #define _NullNull_terminated_
456 #define _On_failure_(annos)
457 #define _Out_
458 #define _Out_bound_
459 #define _Out_bytecap_(size)
460 #define _Out_bytecap_c_(size)
461 #define _Out_bytecap_post_bytecount_(cap, count)
462 #define _Out_bytecap_x_(size)
463 #define _Out_bytecapcount_(capcount)
464 #define _Out_bytecapcount_x_(capcount)
465 #define _Out_cap_(size)
466 #define _Out_cap_c_(size)
467 #define _Out_cap_m_(mult, size)
468 #define _Out_cap_post_count_(cap, count)
469 #define _Out_cap_x_(size)
470 #define _Out_capcount_(capcount)
471 #define _Out_capcount_x_(capcount)
472 #define _Out_defensive_(annotates)
473 #define _Out_opt_
474 #define _Out_opt_bytecap_(size)
475 #define _Out_opt_bytecap_c_(size)
476 #define _Out_opt_bytecap_post_bytecount_(cap, count)
477 #define _Out_opt_bytecap_x_(size)
478 #define _Out_opt_bytecapcount_(capcount)
479 #define _Out_opt_bytecapcount_x_(capcount)
480 #define _Out_opt_cap_(size)
481 #define _Out_opt_cap_c_(size)
482 #define _Out_opt_cap_m_(mult, size)
483 #define _Out_opt_cap_post_count_(cap, count)
484 #define _Out_opt_cap_x_(size)
485 #define _Out_opt_capcount_(capcount)
486 #define _Out_opt_capcount_x_(capcount)
487 #define _Out_opt_ptrdiff_cap_(size)
488 #define _Out_opt_z_bytecap_(size)
489 #define _Out_opt_z_bytecap_c_(size)
490 #define _Out_opt_z_bytecap_post_bytecount_(cap, count)
491 #define _Out_opt_z_bytecap_x_(size)
492 #define _Out_opt_z_bytecapcount_(capcount)
493 #define _Out_opt_z_cap_(size)
494 #define _Out_opt_z_cap_c_(size)
495 #define _Out_opt_z_cap_m_(mult, size)
496 #define _Out_opt_z_cap_post_count_(cap, count)
497 #define _Out_opt_z_cap_x_(size)
498 #define _Out_opt_z_capcount_(capcount)
499 #define _Out_ptrdiff_cap_(size)
500 #define _Out_range_(lb, ub)
501 #define _Out_writes_(size)
502 #define _Out_writes_all_(size)
503 #define _Out_writes_all_opt_(size)
504 #define _Out_writes_bytes_(size)
505 #define _Out_writes_bytes_all_(size)
506 #define _Out_writes_bytes_all_opt_(size)
507 #define _Out_writes_bytes_opt_(size)
508 #define _Out_writes_bytes_to_(size, count)
509 #define _Out_writes_bytes_to_opt_(size, count)
510 #define _Out_writes_opt_(size)
511 #define _Out_writes_opt_z_(size)
512 #define _Out_writes_to_(size, count)
513 #define _Out_writes_to_opt_(size, count)
514 #define _Out_writes_to_ptr_(ptr)
515 #define _Out_writes_to_ptr_opt_(ptr)
516 #define _Out_writes_to_ptr_opt_z_(ptr)
517 #define _Out_writes_to_ptr_z_(ptr)
518 #define _Out_writes_z_(size)
519 #define _Out_z_bytecap_(size)
520 #define _Out_z_bytecap_c_(size)
521 #define _Out_z_bytecap_post_bytecount_(cap, count)
522 #define _Out_z_bytecap_x_(size)
523 #define _Out_z_bytecapcount_(capcount)
524 #define _Out_z_cap_(size)
525 #define _Out_z_cap_c_(size)
526 #define _Out_z_cap_m_(mult, size)
527 #define _Out_z_cap_post_count_(cap, count)
528 #define _Out_z_cap_x_(size)
529 #define _Out_z_capcount_(capcount)
530 #define _Outptr_
531 #define _Outptr_opt_
532 #define _Outptr_opt_result_buffer_(size)
533 #define _Outptr_opt_result_buffer_all_(size)
534 #define _Outptr_opt_result_buffer_all_maybenull_(size)
535 #define _Outptr_opt_result_buffer_maybenull_(size)
536 #define _Outptr_opt_result_buffer_to_(size, count)
537 #define _Outptr_opt_result_buffer_to_maybenull_(size, count)
538 #define _Outptr_opt_result_bytebuffer_(size)
539 #define _Outptr_opt_result_bytebuffer_all_(size)
540 #define _Outptr_opt_result_bytebuffer_all_maybenull_(size)
541 #define _Outptr_opt_result_bytebuffer_maybenull_(size)
542 #define _Outptr_opt_result_bytebuffer_to_(size, count)
543 #define _Outptr_opt_result_bytebuffer_to_maybenull_(size, count)
544 #define _Outptr_opt_result_maybenull_
545 #define _Outptr_opt_result_maybenull_z_
546 #define _Outptr_opt_result_nullonfailure_
547 #define _Outptr_opt_result_z_
548 #define _Outptr_result_buffer_(size)
549 #define _Outptr_result_buffer_all_(size)
550 #define _Outptr_result_buffer_all_maybenull_(size)
551 #define _Outptr_result_buffer_maybenull_(size)
552 #define _Outptr_result_buffer_to_(size, count)
553 #define _Outptr_result_buffer_to_maybenull_(size, count)
554 #define _Outptr_result_bytebuffer_(size)
555 #define _Outptr_result_bytebuffer_all_(size)
556 #define _Outptr_result_bytebuffer_all_maybenull_(size)
557 #define _Outptr_result_bytebuffer_maybenull_(size)
558 #define _Outptr_result_bytebuffer_to_(size, count)
559 #define _Outptr_result_bytebuffer_to_maybenull_(size, count)
560 #define _Outptr_result_maybenull_
561 #define _Outptr_result_maybenull_z_
562 #define _Outptr_result_nullonfailure_
563 #define _Outptr_result_z_
564 #define _Outref_
565 #define _Outref_result_buffer_(size)
566 #define _Outref_result_buffer_all_(size)
567 #define _Outref_result_buffer_all_maybenull_(size)
568 #define _Outref_result_buffer_maybenull_(size)
569 #define _Outref_result_buffer_to_(size, count)
570 #define _Outref_result_buffer_to_maybenull_(size, count)
571 #define _Outref_result_bytebuffer_(size)
572 #define _Outref_result_bytebuffer_all_(size)
573 #define _Outref_result_bytebuffer_all_maybenull_(size)
574 #define _Outref_result_bytebuffer_maybenull_(size)
575 #define _Outref_result_bytebuffer_to_(size, count)
576 #define _Outref_result_bytebuffer_to_maybenull_(size, count)
577 #define _Outref_result_maybenull_
578 #define _Outref_result_nullonfailure_
579 #define _Points_to_data_
580 #define _Post_
581 #define _Post_bytecap_(size)
582 #define _Post_bytecount_(size)
583 #define _Post_bytecount_c_(size)
584 #define _Post_bytecount_x_(size)
585 #define _Post_cap_(size)
586 #define _Post_count_(size)
587 #define _Post_count_c_(size)
588 #define _Post_count_x_(size)
589 #define _Post_defensive_
590 #define _Post_equal_to_(expr)
591 #define _Post_invalid_
592 #define _Post_maybenull_
593 #define _Post_maybez_
594 #define _Post_notnull_
595 #define _Post_null_
596 #define _Post_ptr_invalid_
597 #define _Post_readable_byte_size_(size)
598 #define _Post_readable_size_(size)
599 #define _Post_satisfies_(cond)
600 #define _Post_valid_
601 #define _Post_writable_byte_size_(size)
602 #define _Post_writable_size_(size)
603 #define _Post_z_
604 #define _Post_z_bytecount_(size)
605 #define _Post_z_bytecount_c_(size)
606 #define _Post_z_bytecount_x_(size)
607 #define _Post_z_count_(size)
608 #define _Post_z_count_c_(size)
609 #define _Post_z_count_x_(size)
610 #define _Pre_
611 #define _Pre_bytecap_(size)
612 #define _Pre_bytecap_c_(size)
613 #define _Pre_bytecap_x_(size)
614 #define _Pre_bytecount_(size)
615 #define _Pre_bytecount_c_(size)
616 #define _Pre_bytecount_x_(size)
617 #define _Pre_cap_(size)
618 #define _Pre_cap_c_(size)
619 #define _Pre_cap_c_one_
620 #define _Pre_cap_for_(param)
621 #define _Pre_cap_m_(mult, size)
622 #define _Pre_cap_x_(size)
623 #define _Pre_count_(size)
624 #define _Pre_count_c_(size)
625 #define _Pre_count_x_(size)
626 #define _Pre_defensive_
627 #define _Pre_equal_to_(expr)
628 #define _Pre_invalid_
629 #define _Pre_maybenull_
630 #define _Pre_notnull_
631 #define _Pre_null_
632 #define _Pre_opt_bytecap_(size)
633 #define _Pre_opt_bytecap_c_(size)
634 #define _Pre_opt_bytecap_x_(size)
635 #define _Pre_opt_bytecount_(size)
636 #define _Pre_opt_bytecount_c_(size)
637 #define _Pre_opt_bytecount_x_(size)
638 #define _Pre_opt_cap_(size)
639 #define _Pre_opt_cap_c_(size)
640 #define _Pre_opt_cap_c_one_
641 #define _Pre_opt_cap_for_(param)
642 #define _Pre_opt_cap_m_(mult, size)
643 #define _Pre_opt_cap_x_(size)
644 #define _Pre_opt_count_(size)
645 #define _Pre_opt_count_c_(size)
646 #define _Pre_opt_count_x_(size)
647 #define _Pre_opt_ptrdiff_cap_(ptr)
648 #define _Pre_opt_ptrdiff_count_(ptr)
649 #define _Pre_opt_valid_
650 #define _Pre_opt_valid_bytecap_(size)
651 #define _Pre_opt_valid_bytecap_c_(size)
652 #define _Pre_opt_valid_bytecap_x_(size)
653 #define _Pre_opt_valid_cap_(size)
654 #define _Pre_opt_valid_cap_c_(size)
655 #define _Pre_opt_valid_cap_x_(size)
656 #define _Pre_opt_z_
657 #define _Pre_opt_z_bytecap_(size)
658 #define _Pre_opt_z_bytecap_c_(size)
659 #define _Pre_opt_z_bytecap_x_(size)
660 #define _Pre_opt_z_cap_(size)
661 #define _Pre_opt_z_cap_c_(size)
662 #define _Pre_opt_z_cap_x_(size)
663 #define _Pre_ptrdiff_cap_(ptr)
664 #define _Pre_ptrdiff_count_(ptr)
665 #define _Pre_readable_byte_size_(size)
666 #define _Pre_readable_size_(size)
667 #define _Pre_readonly_
668 #define _Pre_satisfies_(cond)
669 #define _Pre_unknown_
670 #define _Pre_valid_
671 #define _Pre_valid_bytecap_(size)
672 #define _Pre_valid_bytecap_c_(size)
673 #define _Pre_valid_bytecap_x_(size)
674 #define _Pre_valid_cap_(size)
675 #define _Pre_valid_cap_c_(size)
676 #define _Pre_valid_cap_x_(size)
677 #define _Pre_writable_byte_size_(size)
678 #define _Pre_writable_size_(size)
679 #define _Pre_writeonly_
680 #define _Pre_z_
681 #define _Pre_z_bytecap_(size)
682 #define _Pre_z_bytecap_c_(size)
683 #define _Pre_z_bytecap_x_(size)
684 #define _Pre_z_cap_(size)
685 #define _Pre_z_cap_c_(size)
686 #define _Pre_z_cap_x_(size)
687 #define _Prepost_bytecount_(size)
688 #define _Prepost_bytecount_c_(size)
689 #define _Prepost_bytecount_x_(size)
690 #define _Prepost_count_(size)
691 #define _Prepost_count_c_(size)
692 #define _Prepost_count_x_(size)
693 #define _Prepost_opt_bytecount_(size)
694 #define _Prepost_opt_bytecount_c_(size)
695 #define _Prepost_opt_bytecount_x_(size)
696 #define _Prepost_opt_count_(size)
697 #define _Prepost_opt_count_c_(size)
698 #define _Prepost_opt_count_x_(size)
699 #define _Prepost_opt_valid_
700 #define _Prepost_opt_z_
701 #define _Prepost_valid_
702 #define _Prepost_z_
703 #define _Printf_format_string_
704 #define _Raises_SEH_exception_
705 #define _Maybe_raises_SEH_exception_
706 #define _Readable_bytes_(size)
707 #define _Readable_elements_(size)
708 #define _Reserved_
709 #define _Result_nullonfailure_
710 #define _Result_zeroonfailure_
711 #define __inner_callback
712 #define _Ret_
713 #define _Ret_bound_
714 #define _Ret_bytecap_(size)
715 #define _Ret_bytecap_c_(size)
716 #define _Ret_bytecap_x_(size)
717 #define _Ret_bytecount_(size)
718 #define _Ret_bytecount_c_(size)
719 #define _Ret_bytecount_x_(size)
720 #define _Ret_cap_(size)
721 #define _Ret_cap_c_(size)
722 #define _Ret_cap_x_(size)
723 #define _Ret_count_(size)
724 #define _Ret_count_c_(size)
725 #define _Ret_count_x_(size)
726 #define _Ret_maybenull_
727 #define _Ret_maybenull_z_
728 #define _Ret_notnull_
729 #define _Ret_null_
730 #define _Ret_opt_
731 #define _Ret_opt_bytecap_(size)
732 #define _Ret_opt_bytecap_c_(size)
733 #define _Ret_opt_bytecap_x_(size)
734 #define _Ret_opt_bytecount_(size)
735 #define _Ret_opt_bytecount_c_(size)
736 #define _Ret_opt_bytecount_x_(size)
737 #define _Ret_opt_cap_(size)
738 #define _Ret_opt_cap_c_(size)
739 #define _Ret_opt_cap_x_(size)
740 #define _Ret_opt_count_(size)
741 #define _Ret_opt_count_c_(size)
742 #define _Ret_opt_count_x_(size)
743 #define _Ret_opt_valid_
744 #define _Ret_opt_z_
745 #define _Ret_opt_z_bytecap_(size)
746 #define _Ret_opt_z_bytecount_(size)
747 #define _Ret_opt_z_cap_(size)
748 #define _Ret_opt_z_count_(size)
749 #define _Ret_range_(lb, ub)
750 #define _Ret_valid_
751 #define _Ret_writes_(size)
752 #define _Ret_writes_bytes_(size)
753 #define _Ret_writes_bytes_maybenull_(size)
754 #define _Ret_writes_bytes_to_(size, count)
755 #define _Ret_writes_bytes_to_maybenull_(size, count)
756 #define _Ret_writes_maybenull_(size)
757 #define _Ret_writes_maybenull_z_(size)
758 #define _Ret_writes_to_(size, count)
759 #define _Ret_writes_to_maybenull_(size, count)
760 #define _Ret_writes_z_(size)
761 #define _Ret_z_
762 #define _Ret_z_bytecap_(size)
763 #define _Ret_z_bytecount_(size)
764 #define _Ret_z_cap_(size)
765 #define _Ret_z_count_(size)
766 #define _Return_type_success_(expr)
767 #define _Scanf_format_string_
768 #define _Scanf_s_format_string_
769 #define _Struct_size_bytes_(size)
770 #define _Success_(expr)
771 #define _Unchanged_(e)
772 #define _Use_decl_annotations_
773 #define _Valid_
774 #define _When_(expr, annos)
775 #define _Writable_bytes_(size)
776 #define _Writable_elements_(size)
777 
778 #define __bcount(size)
779 #define __bcount_opt(size)
780 #define __deref_bcount(size)
781 #define __deref_bcount_opt(size)
782 #define __deref_ecount(size)
783 #define __deref_ecount_opt(size)
784 #define __deref_in
785 #define __deref_in_bcount(size)
786 #define __deref_in_bcount_opt(size)
787 #define __deref_in_ecount(size)
788 #define __deref_in_ecount_opt(size)
789 #define __deref_in_opt
790 #define __deref_inout
791 #define __deref_inout_bcount(size)
792 #define __deref_inout_bcount_full(size)
793 #define __deref_inout_bcount_full_opt(size)
794 #define __deref_inout_bcount_opt(size)
795 #define __deref_inout_bcount_part(size, length)
796 #define __deref_inout_bcount_part_opt(size, length)
797 #define __deref_inout_ecount(size)
798 #define __deref_inout_ecount_full(size)
799 #define __deref_inout_ecount_full_opt(size)
800 #define __deref_inout_ecount_opt(size)
801 #define __deref_inout_ecount_part(size, length)
802 #define __deref_inout_ecount_part_opt(size, length)
803 #define __deref_inout_opt
804 #define __deref_opt_bcount(size)
805 #define __deref_opt_bcount_opt(size)
806 #define __deref_opt_ecount(size)
807 #define __deref_opt_ecount_opt(size)
808 #define __deref_opt_in
809 #define __deref_opt_in_bcount(size)
810 #define __deref_opt_in_bcount_opt(size)
811 #define __deref_opt_in_ecount(size)
812 #define __deref_opt_in_ecount_opt(size)
813 #define __deref_opt_in_opt
814 #define __deref_opt_inout
815 #define __deref_opt_inout_bcount(size)
816 #define __deref_opt_inout_bcount_full(size)
817 #define __deref_opt_inout_bcount_full_opt(size)
818 #define __deref_opt_inout_bcount_opt(size)
819 #define __deref_opt_inout_bcount_part(size, length)
820 #define __deref_opt_inout_bcount_part_opt(size, length)
821 #define __deref_opt_inout_ecount(size)
822 #define __deref_opt_inout_ecount_full(size)
823 #define __deref_opt_inout_ecount_full_opt(size)
824 #define __deref_opt_inout_ecount_opt(size)
825 #define __deref_opt_inout_ecount_part(size, length)
826 #define __deref_opt_inout_ecount_part_opt(size, length)
827 #define __deref_opt_inout_opt
828 #define __deref_opt_out
829 #define __deref_opt_out_bcount(size)
830 #define __deref_opt_out_bcount_full(size)
831 #define __deref_opt_out_bcount_full_opt(size)
832 #define __deref_opt_out_bcount_opt(size)
833 #define __deref_opt_out_bcount_part(size, length)
834 #define __deref_opt_out_bcount_part_opt(size, length)
835 #define __deref_opt_out_ecount(size)
836 #define __deref_opt_out_ecount_full(size)
837 #define __deref_opt_out_ecount_full_opt(size)
838 #define __deref_opt_out_ecount_opt(size)
839 #define __deref_opt_out_ecount_part(size, length)
840 #define __deref_opt_out_ecount_part_opt(size, length)
841 #define __deref_opt_out_opt
842 #define __deref_out
843 #define __deref_out_bcount(size)
844 #define __deref_out_bcount_full(size)
845 #define __deref_out_bcount_full_opt(size)
846 #define __deref_out_bcount_opt(size)
847 #define __deref_out_bcount_part(size, length)
848 #define __deref_out_bcount_part_opt(size, length)
849 #define __deref_out_ecount(size)
850 #define __deref_out_ecount_full(size)
851 #define __deref_out_ecount_full_opt(size)
852 #define __deref_out_ecount_opt(size)
853 #define __deref_out_ecount_part(size, length)
854 #define __deref_out_ecount_part_opt(size, length)
855 #define __deref_out_opt
856 #define __ecount(size)
857 #define __ecount_opt(size)
858 //#define __in /* Conflicts with libstdc++ header macros */
859 #define __in_bcount(size)
860 #define __in_bcount_opt(size)
861 #define __in_ecount(size)
862 #define __in_ecount_opt(size)
863 #define __in_opt
864 #define __inout
865 #define __inout_bcount(size)
866 #define __inout_bcount_full(size)
867 #define __inout_bcount_full_opt(size)
868 #define __inout_bcount_opt(size)
869 #define __inout_bcount_part(size, length)
870 #define __inout_bcount_part_opt(size, length)
871 #define __inout_ecount(size)
872 #define __inout_ecount_full(size)
873 #define __inout_ecount_full_opt(size)
874 #define __inout_ecount_opt(size)
875 #define __inout_ecount_part(size, length)
876 #define __inout_ecount_part_opt(size, length)
877 #define __inout_opt
878 //#define __out /* Conflicts with libstdc++ header macros */
879 #define __out_bcount(size)
880 #define __out_bcount_full(size)
881 #define __out_bcount_full_opt(size)
882 #define __out_bcount_opt(size)
883 #define __out_bcount_part(size, length)
884 #define __out_bcount_part_opt(size, length)
885 #define __out_ecount(size)
886 #define __out_ecount_full(size)
887 #define __out_ecount_full_opt(size)
888 #define __out_ecount_opt(size)
889 #define __out_ecount_part(size, length)
890 #define __out_ecount_part_opt(size, length)
891 #define __out_opt
892 
893 #define __blocksOn(resource)
894 #define __callback
895 #define __checkReturn
896 #define __format_string
897 #define __in_awcount(expr, size)
898 #define __nullnullterminated
899 #define __nullterminated
900 #define __out_awcount(expr, size)
901 #define __override
902 //#define __reserved /* Conflicts with header included by CarbonCore.h on OS X */
903 #define __success(expr)
904 #define __typefix(ctype)
905 
906 #ifndef _countof
907 #ifndef __cplusplus
908 #define _countof(_Array) (sizeof(_Array) / sizeof(_Array[0]))
909 #else
910 extern "C++"
911 {
912  template <typename _CountofType, size_t _SizeOfArray>
913  char (*__countof_helper(_CountofType (&_Array)[_SizeOfArray]))[_SizeOfArray];
914 #define _countof(_Array) sizeof(*__countof_helper(_Array))
915 }
916 #endif
917 #endif
918 
923 #define MINCHAR 0x80
924 #define MAXCHAR 0x7F
925 
926 #ifndef MINSHORT
927 #define MINSHORT 0x8000
928 #endif
929 
930 #ifndef MAXSHORT
931 #define MAXSHORT 0x7FFF
932 #endif
933 
934 #define MINLONG 0x80000000
935 #define MAXLONG 0x7FFFFFFF
936 #define MAXBYTE 0xFF
937 #define MAXWORD 0xFFFF
938 #define MAXDWORD 0xFFFFFFFF
939 
940 #define FIELD_OFFSET(type, field) ((LONG)(LONG_PTR) & (((type*)0)->field))
941 
942 #define RTL_FIELD_SIZE(type, field) (sizeof(((type*)0)->field))
943 
944 #define RTL_SIZEOF_THROUGH_FIELD(type, field) \
945  (FIELD_OFFSET(type, field) + RTL_FIELD_SIZE(type, field))
946 
947 #define RTL_CONTAINS_FIELD(Struct, Size, Field) \
948  ((((PCHAR)(&(Struct)->Field)) + sizeof((Struct)->Field)) <= (((PCHAR)(Struct)) + (Size)))
949 
950 #define RTL_NUMBER_OF_V1(A) (sizeof(A) / sizeof((A)[0]))
951 #define RTL_NUMBER_OF_V2(A) RTL_NUMBER_OF_V1(A)
952 
953 #define RTL_NUMBER_OF(A) RTL_NUMBER_OF_V1(A)
954 
955 #define ARRAYSIZE(A) RTL_NUMBER_OF_V2(A)
956 #define _ARRAYSIZE(A) RTL_NUMBER_OF_V1(A)
957 
958 #define RTL_FIELD_TYPE(type, field) (((type*)0)->field)
959 
960 #define RTL_NUMBER_OF_FIELD(type, field) (RTL_NUMBER_OF(RTL_FIELD_TYPE(type, field)))
961 
962 #define RTL_PADDING_BETWEEN_FIELDS(T, F1, F2) \
963  ((FIELD_OFFSET(T, F2) > FIELD_OFFSET(T, F1)) \
964  ? (FIELD_OFFSET(T, F2) - FIELD_OFFSET(T, F1) - RTL_FIELD_SIZE(T, F1)) \
965  : (FIELD_OFFSET(T, F1) - FIELD_OFFSET(T, F2) - RTL_FIELD_SIZE(T, F2)))
966 
967 #if defined(__cplusplus)
968 #define RTL_CONST_CAST(type) const_cast<type>
969 #else
970 #define RTL_CONST_CAST(type) (type)
971 #endif
972 
973 #define RTL_BITS_OF(sizeOfArg) (sizeof(sizeOfArg) * 8)
974 
975 #define RTL_BITS_OF_FIELD(type, field) (RTL_BITS_OF(RTL_FIELD_TYPE(type, field)))
976 
977 #define CONTAINING_RECORD(address, type, field) \
978  ((type*)((PCHAR)(address) - (ULONG_PTR)(&((type*)0)->field)))
979 
980 #endif
981 
982 #if defined(_WIN32) || defined(__CYGWIN__)
983 #ifdef __GNUC__
984 #define DECLSPEC_EXPORT __attribute__((dllexport))
985 #ifndef DECLSPEC_IMPORT
986 #define DECLSPEC_IMPORT __attribute__((dllimport))
987 #endif /* DECLSPEC_IMPORT */
988 #else
989 #define DECLSPEC_EXPORT __declspec(dllexport)
990 #define DECLSPEC_IMPORT __declspec(dllimport)
991 #endif /* __GNUC__ */
992 #else
993 #if defined(__GNUC__) && __GNUC__ >= 4
994 #define DECLSPEC_EXPORT __attribute__((visibility("default")))
995 #define DECLSPEC_IMPORT
996 #else
997 #define DECLSPEC_EXPORT
998 #define DECLSPEC_IMPORT
999 #endif
1000 #endif
1001 
1002 WINPR_PRAGMA_DIAG_POP
1003 
1004 #endif /* WINPR_SPEC_H */