Why does a VS 2010 project compilation, generates pdb files, when building in Release and Debug mode?
compilation, visual-studio, visual-studio-2010
Solution
My question is that if we have pdb files in both debug and release mode then why there is need for two compilation mode
There are differences other than PDB generation between debug and release. If you go into the Build properties and go into "Advanced", there are different levels of debug information to be generated - Full, PDB-only and None.
In addition, there are different levels of compile-time optimization, and the presence of different preprocessor symbols (e.g. so that each `Debug.Assert` will be present or absent).
Of course you can have your own varieties of build configuration too, with a variety of options.
Problem
I am building my window service c# project of VS 2010 in Release mode. My first chance to get surprised was that it's creating pdb files even in release in mode. I was not able to load the debug symbols after attaching the process for debugging. My question is that if we have pdb files in both debug and release mode then why there is need for two compilation mode.