Skip to content

Commit 2b01031

Browse files
Copilotericstj333fred
authored
Add missing type forward for CompilerServices.Closure (#119197)
* Initial plan * Add missing type forwards for CompilerServices.Closure, CallSiteOps, and RuntimeOps Co-authored-by: ericstj <[email protected]> * Fix reference source * Remove obsolete CallSiteOps and RuntimeOps types per feedback Co-authored-by: ericstj <[email protected]> * Apply suggestions from code review Remove empty lines added by copilot Co-authored-by: Fred Silberberg <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: ericstj <[email protected]> Co-authored-by: Eric St. John <[email protected]> Co-authored-by: Fred Silberberg <[email protected]>
1 parent e24b55f commit 2b01031

File tree

3 files changed

+8
-4
lines changed

3 files changed

+8
-4
lines changed

src/libraries/System.Linq.Expressions/ref/System.Linq.Expressions.cs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1215,6 +1215,13 @@ internal CallSite() { }
12151215
[System.Diagnostics.CodeAnalysis.RequiresDynamicCodeAttribute("Creating arrays at runtime requires dynamic code generation.")]
12161216
public static System.Runtime.CompilerServices.CallSite<T> Create(System.Runtime.CompilerServices.CallSiteBinder binder) { throw null; }
12171217
}
1218+
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
1219+
public sealed partial class Closure
1220+
{
1221+
public readonly object[] Constants;
1222+
public readonly object[]? Locals;
1223+
public Closure(object[] constants, object[]? locals) { }
1224+
}
12181225
public abstract partial class DebugInfoGenerator
12191226
{
12201227
protected DebugInfoGenerator() { }

src/libraries/System.Linq.Expressions/src/CompatibilitySuppressions.xml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,6 @@
99
<DiagnosticId>CP0001</DiagnosticId>
1010
<Target>T:System.Runtime.CompilerServices.CallSiteOps</Target>
1111
</Suppression>
12-
<Suppression>
13-
<DiagnosticId>CP0001</DiagnosticId>
14-
<Target>T:System.Runtime.CompilerServices.Closure</Target>
15-
</Suppression>
1612
<Suppression>
1713
<DiagnosticId>CP0001</DiagnosticId>
1814
<Target>T:System.Runtime.CompilerServices.RuntimeOps</Target>

src/libraries/shims/System.Core/src/System.Core.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,7 @@
184184
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.CallSite<>))]
185185
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.CallSiteBinder))]
186186
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.CallSiteHelpers))]
187+
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.Closure))]
187188
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.DebugInfoGenerator))]
188189
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.DynamicAttribute))]
189190
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.CompilerServices.ExtensionAttribute))]

0 commit comments

Comments
 (0)