Skip to content

Commit

Permalink
Fix constraint on FrozenSet.{Try}GetAlternateLookup (dotnet#107846)
Browse files Browse the repository at this point in the history
Normally we would have caught this oversight immediately, as tests would have failed to compile, but unlike the vast majority of our test suites, System.Collections.Immutable's test suite references the implementation assembly rather than the ref assembly, in order to access internals via InternalsVisibleTo. Grrr.
  • Loading branch information
stephentoub committed Sep 16, 2024
1 parent cdc8418 commit 550d381
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ public abstract partial class FrozenDictionary<TKey, TValue>
}
public abstract partial class FrozenSet<T>
{
public System.Collections.Frozen.FrozenSet<T>.AlternateLookup<TAlternate> GetAlternateLookup<TAlternate>() { throw null; }
public bool TryGetAlternateLookup<TAlternate>(out System.Collections.Frozen.FrozenSet<T>.AlternateLookup<TAlternate> lookup) { throw null; }
public readonly partial struct AlternateLookup<TAlternate>
public System.Collections.Frozen.FrozenSet<T>.AlternateLookup<TAlternate> GetAlternateLookup<TAlternate>() where TAlternate : allows ref struct { throw null; }
public bool TryGetAlternateLookup<TAlternate>(out System.Collections.Frozen.FrozenSet<T>.AlternateLookup<TAlternate> lookup) where TAlternate : allows ref struct { throw null; }
public readonly partial struct AlternateLookup<TAlternate> where TAlternate : allows ref struct
{
private readonly object _dummy;
private readonly int _dummyPrimitive;
Expand Down

0 comments on commit 550d381

Please sign in to comment.