<html>
    <head>
      <base href="http://llvm.org/bugs/" />
    </head>
    <body><span class="vcard"><a class="email" href="mailto:anton.travnikov@gmail.com" title="Anton <anton.travnikov@gmail.com>"> <span class="fn">Anton</span></a>
</span> changed
              <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED WORKSFORME - AND operator compiled like OR operator (and vice versa) in FOR loop with text arrays"
   href="http://llvm.org/bugs/show_bug.cgi?id=21343">bug 21343</a>
        <br>
             <table border="1" cellspacing="0" cellpadding="8">
          <tr>
            <th>What</th>
            <th>Removed</th>
            <th>Added</th>
          </tr>

         <tr>
           <td style="text-align:right;">Status</td>
           <td>REOPENED
           </td>
           <td>RESOLVED
           </td>
         </tr>

         <tr>
           <td style="text-align:right;">Resolution</td>
           <td>---
           </td>
           <td>WORKSFORME
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED WORKSFORME - AND operator compiled like OR operator (and vice versa) in FOR loop with text arrays"
   href="http://llvm.org/bugs/show_bug.cgi?id=21343#c4">Comment # 4</a>
              on <a class="bz_bug_link 
          bz_status_RESOLVED  bz_closed"
   title="RESOLVED WORKSFORME - AND operator compiled like OR operator (and vice versa) in FOR loop with text arrays"
   href="http://llvm.org/bugs/show_bug.cgi?id=21343">bug 21343</a>
              from <span class="vcard"><a class="email" href="mailto:anton.travnikov@gmail.com" title="Anton <anton.travnikov@gmail.com>"> <span class="fn">Anton</span></a>
</span></b>
        <pre>(In reply to <a href="show_bug.cgi?id=21343#c3">comment #3</a>)
<span class="quote">> OR is the required operation for the logic you're trying to do.

> You want the loop to stop when (s[tmp_i] == '*' && s[tmp_i + 1] == '/')
> right? So you need to loop while the opposite is true. Which would be
> !(s[tmp_i] == '*' && s[tmp_i + 1] == '/'). If we apply DeMorgan's law to
> propagate the inversion all the way through, we get (s[tmp_i] != '*' ||
> s[tmp_i + 1] != '/'). Which is what your code has.</span >

Thank you very much for exhaustive explanations!</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>