Ever wondered whats the use of .pdb files? Among others, it keeps track of which IL command came from which C# instruction. So you get all the information like line number in source code if ever your program crashes(Yes programs I have written have crashed many times,!).
When you build a C# project in debug mode, and this assembly is converted to machine instructions by CLR, it keeps track of which machine instructions map to which C# code, which enables us to do just in time debugging after the program has started running using VisualStudio.
If you start the program directly from Visual Studio, even if the Release environment is used, CLR is forced to keep map between machine instructions and C# code!
When you build a C# project in debug mode, and this assembly is converted to machine instructions by CLR, it keeps track of which machine instructions map to which C# code, which enables us to do just in time debugging after the program has started running using VisualStudio.
If you start the program directly from Visual Studio, even if the Release environment is used, CLR is forced to keep map between machine instructions and C# code!