Clarify code with unobvious precedence (#1624)
authorDmitry-Me <Dmitry-Me@users.noreply.github.com>
Fri, 14 Oct 2016 14:02:00 +0000 (17:02 +0300)
committerJan Kotas <jkotas@microsoft.com>
Fri, 14 Oct 2016 14:02:00 +0000 (07:02 -0700)
src/debug/di/rsthread.cpp

index ae9b43c..c2a8d1b 100644 (file)
@@ -8935,8 +8935,13 @@ HRESULT CordbJITILFrame::GetReturnValueForILOffsetImpl(ULONG32 ILoffset, ICorDeb
     bool found = false;
     ULONG32 currentOffset = m_nativeFrame->GetIPOffset();
     for (ULONG32 i = 0; i < count; ++i)
-        if ((found = currentOffset == offsets[i]))
+    {
+        if (currentOffset == offsets[i])
+        {
+            found = true;
             break;
+        }
+    }
 
     if (!found)
         return E_UNEXPECTED;