title: VS2015 Debugger showing wrong values?
body: <p><strong>EDIT: When I run this code in Visual Studio 2013, the debugger is showing <code>Utc</code>, not <code>Local</code>. It's a bug in Visual Studio 2015 Debugger.</strong></p>
  
  <p>EDIT: Have taken the code and put in stand-alone console app, but cannot reproduce in either version of VS. Bummer.</p>
  
  <p>Can someone explain to me how what you see in this screenshot is possible?!</p>
  
  <ol>
  <li>On line 298, <code>endingTimePeriodStartDate</code> is redefined as its <code>Date</code> value but set to <code>DateTimeKind.Utc</code>.</li>
  <li>On Line 300, if <code>endingTimePeriodStartDate</code> is not actually <code>DateTimeKind.Utc</code>, an exception is thrown.</li>
  <li>The debugger breakpoint on line 305 is hit, meaning the exception on line 302 was not thrown, meaning <code>endingTimePeriodStartDate.Kind == DateTimeKind.Utc</code></li>
  <li>(I also did a <code>System.Diagnostic.Debug.WriteLine(endingTimePeriodStartDate.Kind)</code> before line 305 and it prints “Utc” in the Output window).</li>
  <li>When I look at <code>endingTimePeriodStartDate</code> in the Locals and Watch debugger windows, and when I mouse hover over the variable, the <code>Kind</code> property shows <code>DateTimeKind.Local</code></li>
  </ol>
  
  <p><a href="https://i.stack.imgur.com/D4Spo.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/D4Spo.png" alt="enter image description here"></a></p>