File tree Expand file tree Collapse file tree 3 files changed +27
-3
lines changed
libraries/System.Private.CoreLib/src
System/Runtime/InteropServices
mono/netcore/System.Private.CoreLib/src/System Expand file tree Collapse file tree 3 files changed +27
-3
lines changed Original file line number Diff line number Diff line change 18
18
<type fullname =" System.Threading.Tasks.Task" feature =" System.Diagnostics.Debugger.IsSupported" featurevalue =" false" >
19
19
<field name =" s_asyncDebuggingEnabled" value =" false" initialize =" false" />
20
20
</type >
21
- <type fullname =" System.Type" feature =" System.Runtime.InteropServices.Marshal.IsComSupported" featurevalue =" false" >
21
+ </assembly >
22
+ <assembly fullname =" System.Private.CoreLib" feature =" System.Runtime.InteropServices.Marshal.IsComSupported" featurevalue =" false" >
23
+ <type fullname =" System.Type" >
22
24
<method signature =" System.Boolean get_IsCOMObject()" body =" stub" value =" false" />
23
25
</type >
26
+ <type fullname =" System.Runtime.InteropServices.Marshal" >
27
+ <method signature =" System.Boolean IsComObject(System.Object)" body =" stub" value =" false" />
28
+ <method signature =" System.Boolean IsTypeVisibleFromCom(System.Type)" body =" stub" value =" false" />
29
+ </type >
24
30
</assembly >
25
31
</linker >
Original file line number Diff line number Diff line change @@ -195,9 +195,24 @@ public static object GetUniqueObjectForIUnknown(IntPtr unknown)
195
195
throw new PlatformNotSupportedException ( SR . PlatformNotSupported_ComInterop ) ;
196
196
}
197
197
198
- public static bool IsComObject ( object o ) => false ;
198
+ public static bool IsComObject ( object o )
199
+ {
200
+ if ( o is null )
201
+ {
202
+ throw new ArgumentNullException ( nameof ( o ) ) ;
203
+ }
204
+
205
+ return false ;
206
+ }
199
207
200
- public static bool IsTypeVisibleFromCom ( Type t ) => false ;
208
+ public static bool IsTypeVisibleFromCom ( Type t )
209
+ {
210
+ if ( t is null )
211
+ {
212
+ throw new ArgumentNullException ( nameof ( t ) ) ;
213
+ }
214
+ return false ;
215
+ }
201
216
202
217
internal static bool IsComSupported => false ;
203
218
Original file line number Diff line number Diff line change @@ -2377,6 +2377,9 @@ public override Guid GUID
2377
2377
{
2378
2378
get
2379
2379
{
2380
+ if ( ! Marshal . IsComSupported )
2381
+ return Guid . Empty ;
2382
+
2380
2383
object [ ] att = GetCustomAttributes ( typeof ( System . Runtime . InteropServices . GuidAttribute ) , true ) ;
2381
2384
if ( att . Length == 0 )
2382
2385
return Guid . Empty ;
You can’t perform that action at this time.
0 commit comments