wasabi
PersistedAssemblyBuilder to generate executable
There is no such thing as .exe's generated or used by the Core runtime anymore. When you build a project in MSBuild, and you get an exe, what that actually is is a copy of apphost.exe, which is prebuilt and distributed as a binary within the SDK itself.
15 replies
Help on how async/await works
When you call Foo the first line runs. The second line runs, calling OtherThing, which returns a Task. Because you are awaiting that Task, a new Task is created that is linked to the Task that returns from OtherThing. That new task is set up to, upon completion, jump back into line 3. Whenever that happens, the new task has it's result set to i, and is marked completed, so the caller of Foo then has a Task that will eventually return 1, but only after it's bneen resumed by the first task returned by OtherThing.
12 replies
Help on how async/await works
So, 'async' turns a method into something magical. A state machine. That is organized so that different parts of the method can be invoked independently. What actually happens when await happens is 'control is returned', which literally means the method returns to it's caller. But it returns a Task. That Task can later be used to resume execution of the rest of the method.
12 replies