create_async example c++
IAsyncOperation<int>^ asyncOp = create_async( []() -> int { return 42; }); The function object passed to the simple create_async example above behaves exactly the same as an identical one used in a task<int> constructor as shown below. It is in fact a task body.