Skip to content

Commit

Permalink
right number of template arguments
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben Rog-Wilhelm committed Oct 6, 2023
1 parent 848808b commit 11465af
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion extra/recorder_enumerator/src/Config.cs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ public static Converter ConverterFactory(Type type)

if (genericTypeDefinition == SystemLinqEnumerable_SelectIPartitionIterator_Converter.RelevantType)
{
return (Converter)Activator.CreateInstance(typeof(SystemLinqEnumerable_SelectIPartitionIterator_Converter<,>).MakeGenericType(type, type.GenericTypeArguments[0], type.GenericTypeArguments[1]));
return (Converter)Activator.CreateInstance(typeof(SystemLinqEnumerable_SelectIPartitionIterator_Converter<>).MakeGenericType(type));
}

// SystemLinq
Expand Down
4 changes: 2 additions & 2 deletions extra/recorder_enumerator/src/SystemLinqEnumerable.cs
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,10 @@ public override void Read(ref object input, Recorder recorder)
// This seems to exist only in earlier versions of .net; 2 and 3, but the cutoff is unclear
public static class SystemLinqEnumerable_SelectIPartitionIterator_Converter
{
internal static Type RelevantType = typeof(System.Linq.Enumerable).GetNestedType("SelectIPartitionIterator`1", System.Reflection.BindingFlags.NonPublic);
internal static Type RelevantType = typeof(System.Linq.Enumerable).GetNestedType("SelectIPartitionIterator`2", System.Reflection.BindingFlags.NonPublic);
}

public class SystemLinqEnumerable_SelectIPartitionIterator_Converter<Iterator, T> : ConverterFactoryDynamic
public class SystemLinqEnumerable_SelectIPartitionIterator_Converter<Iterator> : ConverterFactoryDynamic
{
internal FieldInfo field_Source = typeof(Iterator).GetPrivateFieldInHierarchy("_source");
internal FieldInfo field_Selector = typeof(Iterator).GetPrivateFieldInHierarchy("_selector");
Expand Down

0 comments on commit 11465af

Please sign in to comment.