+ 1

Visual Studio crashes... doesn't matter what I write

output: 'ConsoleApp2.exe' (CLR v4.0.30319: DefaultDomain): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_32\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled. 'ConsoleApp2.exe' (CLR v4.0.30319: DefaultDomain): Loaded 'c:\users\lee\documents\visual studio 2017\Projects\ConsoleApp2\ConsoleApp2\bin\Debug\ConsoleApp2.exe'. Symbols loaded. The program '[16648] ConsoleApp2.exe' has exited with code 0 (0x0).

26th Apr 2017, 2:31 AM
Leepingtoconclusion
2 Answers
+ 1
That looks like a normal exit code. Did you set a breakpoint? Note that if you assign a variable but don't ever use it the compiler will optimize it out. Turn off optimization, do something with the variable, or manually break with a call to the Debugger library. int x = 0; // variable never used, debugger won't break here unless optimization is turned off return 0; int x = 1; // debugger will break int y = 2; int z = x + y; return 0; System.Diagnostics.Debugger.Break(); // will always break return 0;
26th Apr 2017, 3:01 AM
Mason Krei
Mason Krei - avatar
0
Did you figure this out?
28th Apr 2017, 5:37 PM
Mason Krei
Mason Krei - avatar