C#DecompilerEnhancementHelp Wanted
仓库指标
- Star
- (25,162 star)
- PR 合并指标
- (平均合并 15天 22小时) (30 天内合并 61 个 PR)
描述
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!