c# - How can I have the VS Debugger break in the correct location for exceptions thrown in Async methods in a Console App? -


i'm writing console app uses lots of async methods; i've made async main method can await in:

static void main(string[] args) {     mainasync(args).wait(); }  static async task mainasync(string[] args) {     // can use await here } 

however, when exception occurs; debugger break me on .wait() call. not experience.

is there can debugger breaks exception occurs rather here? i'm using vs2015 , targeting .net 4.6 if influences answer.


Comments

Popular posts from this blog

Fail to load namespace Spring Security http://www.springframework.org/security/tags -

sql - MySQL query optimization using coalesce -

unity3d - Unity local avoidance in user created world -