<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - clang goes into an endless loop while trying to produce diagnostics"
   href="https://bugs.llvm.org/show_bug.cgi?id=50797">50797</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>clang goes into an endless loop while trying to produce diagnostics
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>12.0
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Windows NT
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>C
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>jeroen.dobbelaere@synopsys.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>blitzrakete@gmail.com, dgregor@apple.com, erik.pilkington@gmail.com, llvm-bugs@lists.llvm.org, richard-llvm@metafoo.co.uk
          </td>
        </tr></table>
      <p>
        <div>
        <pre>During a creduce session of a csmith triggered issue, I stumbled upon this
unrelated, but still annoying bug:
For the provided program, clang goes into an endless loop.
Based on the backtrace, it might be related to
TransformTypos::RecursiveTransformLoop ; At least, that one is consistently
showing up.


#0  0x0000000004b111e0 in clang::TreeTransform<(anonymous
namespace)::TransformTypos>::TransformCXXDependentScopeMemberExpr(clang::CXXDependentScopeMemberExpr*)
()
#1  0x0000000004b10898 in clang::TreeTransform<(anonymous
namespace)::TransformTypos>::TransformBinaryOperator(clang::BinaryOperator*) ()
#2  0x0000000004ad9d63 in (anonymous
namespace)::TransformTypos::RecursiveTransformLoop(clang::Expr*, bool&) ()
#3  0x0000000004ada6be in clang::Sema::CorrectDelayedTyposInExpr(clang::Expr*,
clang::VarDecl*, bool, llvm::function_ref<clang::ActionResult<clang::Expr*,
true> (clang::Expr*)>) [clone .localalias.8] ()
#4  0x00000000046bfddd in
clang::Parser::ParseParenExpression(clang::Parser::ParenParseOption&, bool,
bool, clang::OpaquePtr<clang::QualType>&, clang::SourceLocation&) [clone .lo


<a href="https://www.godbolt.org/z/5Mxae6fWY">https://www.godbolt.org/z/5Mxae6fWY</a>

Based on godbolt's feedback, this was introduced for llvm-12 and is still
present in trunc
It also only happens when in 'C' mode, C++ mode does not get into a loop.</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>