C#DecompilerEnhancementHelp Wanted
Description
ILSpy version 5.0.0.4970-preview3
method decompiled with while but foreach expected
protected CompositeDevices(SerializationInfo info, StreamingContext context)
: base(info, context)
{
SerializationInfoEnumerator enumerator = info.GetEnumerator();
while (enumerator.MoveNext())
{
string name = enumerator.Current.Name;
if (name != null && name == "AdditionalParameters")
{
AdditionalParameters = (Dictionary<string, string>)info.GetValue("AdditionalParameters", typeof(Dictionary<string, string>));
}
}
base.CollectionChanged += OnCollectionChanged;
}
please also ref to very similar method CompositeDevices(IEnumerable col) that decompiled to foreach!
target: #1601
PS this assemlby has a lot of other locations that are decompiled to while loop instead of much more expected foreach!