after successful completion of the Task thread, which function is executed in the main thread and which syntax has it. if not successful then this function will not work. ?

  • Uh ... "after the successful completion of the Task thread" - and why does Task have a separate thread that ends with it? and why something at this point should be performed in the main thread? - VladD
  • The one that made await from the main thread? - Qwertiy
  • @Qwertiy: If there is no message loop in the main thread, the result may be unexpected. - VladD
  • @VladD, do we even have an option when there is no message loop in the main thread? It seems that this thread is the main one and is considered in which there is a message loop? Or am I confused in terminology? - Qwertiy
  • @Qwertiy: Well, if we have a console program, for example. All awaits are returned to the thread pool. - VladD

0