Browse Source

Merge pull request #886 from mohe2015/test-async-fix

Fix failed decompilation of catch-when if the method is async.
pull/879/merge
Siegfried Pammer 8 years ago committed by GitHub
parent
commit
b1bb6ee41e
  1. 1
      ICSharpCode.Decompiler/IL/Transforms/CopyPropagation.cs

1
ICSharpCode.Decompiler/IL/Transforms/CopyPropagation.cs

@ -83,6 +83,7 @@ namespace ICSharpCode.Decompiler.IL.Transforms @@ -83,6 +83,7 @@ namespace ICSharpCode.Decompiler.IL.Transforms
// note: the initialization by the caller is the first store -> StoreCount must be 1
return v.IsSingleDefinition;
case VariableKind.StackSlot:
case VariableKind.Exception:
// Variables are be copied only if both they and the target copy variable are generated,
// and if the variable has only a single assignment
return v.IsSingleDefinition && target.Kind == VariableKind.StackSlot;

Loading…
Cancel
Save