@@ -136,7 +136,9 @@ class idl2d
136
136
" threadpoolprivateapiset.h" , " threadpoolapiset.h" , " bemapiset.h" , " wow64apiset.h" ,
137
137
" jobapi.h" , " timezoneapi.h" , " datetimeapi.h" , " stringapiset.h" ,
138
138
" libloaderapi.h" , " securitybaseapi.h" , " namespaceapi.h" , " systemtopologyapi.h" , " processtopologyapi.h" ,
139
- " securityappcontainer.h" , " realtimeapiset.h" , " unknwnbase.idl" , " objidlbase.idl" , " combaseapi.h"
139
+ " securityappcontainer.h" , " realtimeapiset.h" , " unknwnbase.idl" , " objidlbase.idl" , " combaseapi.h" ,
140
+ // Win SDK 8.1
141
+ " mprapidef.h" , " lmerr.h" , " lmcons.h" ,
140
142
])
141
143
win_idl_files ~= f ~ " *" ; // make it optional
142
144
@@ -1215,6 +1217,11 @@ version(all)
1215
1217
replaceTokenSequence(tokens, " typedef struct DECLSPEC_ALIGN($_num)" , " align($_num) typedef struct" , true );
1216
1218
replaceTokenSequence(tokens, " typedef union DECLSPEC_ALIGN($_num)" , " align($_num) typedef union" , true );
1217
1219
replaceTokenSequence(tokens, " struct DECLSPEC_ALIGN($_num)" , " align($_num) struct" , true );
1220
+
1221
+ // win 8.1: remove template _ENUM_FLAG_INTEGER_FOR_SIZE
1222
+ replaceTokenSequence(tokens, " template $args _ENUM_FLAG_INTEGER_FOR_SIZE;" , " /*$0*/" , true );
1223
+ replaceTokenSequence(tokens, " template <> struct _ENUM_FLAG_INTEGER_FOR_SIZE <$arg> { $def };" , " /*$0*/" , true );
1224
+ replaceTokenSequence(tokens, " template <$arg> struct _ENUM_FLAG_SIZED_INTEGER { $def };" , " /*$0*/" , true );
1218
1225
}
1219
1226
1220
1227
if (currentModule == " commctrl" )
@@ -1494,6 +1501,9 @@ version(none) version(vsi)
1494
1501
replaceTokenSequence(tokens, " OLECMDIDF_REFRESH_PROMPTIFOFFLINE = 0x2000, OLECMDIDF_REFRESH_THROUGHSCRIPT = 0x4000 $_not," ,
1495
1502
" OLECMDIDF_REFRESH_PROMPTIFOFFLINE = 0x2000,\n OLECMDIDF_REFRESH_THROUGHSCRIPT = 0x4000, $_not" , true );
1496
1503
replaceTokenSequence(tokens, " OLECMDIDF_REFRESH_PROMPTIFOFFLINE = 0x2000 $_not," , " OLECMDIDF_REFRESH_PROMPTIFOFFLINE = 0x2000, $_not" , true );
1504
+
1505
+ // win SDK 8.1: double define
1506
+ replaceTokenSequence(tokens, " typedef struct tagPAGESET {} PAGESET;" , " " , true );
1497
1507
}
1498
1508
1499
1509
// vsshell.idl
@@ -1526,6 +1536,23 @@ version(none) version(vsi)
1526
1536
{
1527
1537
replaceTokenSequence(tokens, " typedef enum CWMO_FLAGS" , " typedef enum tagCWMO_FLAGS" , true );
1528
1538
}
1539
+ if (currentModule == " lmcons" )
1540
+ {
1541
+ replaceTokenSequence(tokens, " alias NERR_BASE MIN_LANMAN_MESSAGE_ID;" , " enum MIN_LANMAN_MESSAGE_ID = 2100;" , true ); // missing lmerr.h
1542
+ }
1543
+ if (currentModule == " winnt" )
1544
+ {
1545
+ // Win SDK 8.1: remove translation to intrinsics
1546
+ replaceTokenSequence(tokens, " alias _InterlockedAnd InterlockedAnd;" , " /+ $*" , true );
1547
+ replaceTokenSequence(tokens, " InterlockedCompareExchange($args __in LONG ExChange, __in LONG Comperand);" , " $* +/" , true );
1548
+ replaceTokenSequence(tokens, " InterlockedOr(&Barrier, 0);" , " InterlockedExchangeAdd(&Barrier, 0);" , true ); // InterlockedOr exist only as intrinsic
1549
+ }
1550
+ if (currentModule == " ocidl" )
1551
+ {
1552
+ // move alias out of interface declaration, it causes circular definitions with dmd 2.065+
1553
+ replaceTokenSequence(tokens, " interface IOleUndoManager : IUnknown { alias IID_IOleUndoManager SID_SOleUndoManager; $data }" ,
1554
+ " interface IOleUndoManager : IUnknown { $data }\n\n alias IID_IOleUndoManager SID_SOleUndoManager;" , true );
1555
+ }
1529
1556
1530
1557
replaceTokenSequence(tokens, " extern const __declspec(selectany)" , " dconst" , true );
1531
1558
replaceTokenSequence(tokens, " EXTERN_C $args;" , " /+EXTERN_C $args;+/" , true );
@@ -1723,6 +1750,10 @@ version(none)
1723
1750
replaceTokenSequence(tokens, " $_not . UIHierarchyItems*" , " $_not . UIHierarchyItems*" , true );
1724
1751
replaceTokenSequence(tokens, " Collection([$data] ProjectItems $arg)" , " Collection([$data] .ProjectItems $arg)" , true );
1725
1752
}
1753
+ if (currentModule == " dte80a" )
1754
+ {
1755
+ replaceTokenSequence(tokens, " [id($_num), propputref $attr] HRESULT Value" , " [id($_num), propputref $attr]\n HRESULT putref_Value" , true );
1756
+ }
1726
1757
// VS2012 SDK
1727
1758
if (currentModule == " webproperties" )
1728
1759
{
@@ -1874,6 +1905,11 @@ version(all) {
1874
1905
replaceTokenSequence(tokens, " _Acquires_exclusive_lock_($args)" , " /+$*+/" , true );
1875
1906
replaceTokenSequence(tokens, " _Acquires_shared_lock_($args)" , " /+$*+/" , true );
1876
1907
1908
+ // Win SDK 8.1
1909
+ replaceTokenSequence(tokens, " _Post_satisfies_($args)" , " /+$*+/" , true );
1910
+ replaceTokenSequence(tokens, " _Post_readable_byte_size_($args)" , " /+$*+/" , true );
1911
+ replaceTokenSequence(tokens, " _Ret_reallocated_bytes_($args)" , " /+$*+/" , true );
1912
+
1877
1913
replaceTokenSequence(tokens, " __assume_bound($args);" , " /+$*+/" , true );
1878
1914
replaceTokenSequence(tokens, " __asm{$args}$_opt;" , " assert(false, \" asm not translated\" ); asm{naked; nop; /+$args+/}" , true );
1879
1915
replaceTokenSequence(tokens, " __asm $_not{$stmt}" , " assert(false, \" asm not translated\" ); asm{naked; nop; /+$_not $stmt+/} }" , true );
@@ -2170,6 +2206,11 @@ else
2170
2206
case " _Ret_maybenull_" :
2171
2207
case " _Ret_opt_" :
2172
2208
case " _Printf_format_string_" :
2209
+
2210
+ // Windows SDK 8.1
2211
+ case " _Field_z_" :
2212
+ case " _Pre_notnull_" :
2213
+ case " _Frees_ptr_" :
2173
2214
return " /*" ~ text ~ " */" ;
2174
2215
2175
2216
case " __checkReturn" : return " /*__checkReturn*/" ;
0 commit comments