mirror of https://github.com/icsharpcode/ILSpy.git
Browse Source
An operand boxed for the GetAwaiter call is typed 'object', so the member lookup that decides whether the await needs a cast finds nothing and a redundant cast to the receiver type reaches the output. C# inserts that boxing conversion implicitly, so the box may be dropped -- but only after the lookup confirms the unboxed operand still binds the same GetAwaiter, and only via the resolve result: UnwrapChild detaches the operand from the AST, so running it speculatively leaves a cast with no child behind and decompilation of the whole method falls back to the raw state machine. Assisted-by: Claude:claude-opus-5[1m]:Claude Codepull/4021/head
1 changed files with 22 additions and 4 deletions
Loading…
Reference in new issue