<html>
    <head>
      <base href="https://llvm.org/bugs/" />
    </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: assertion failure while checking format strings in libiconv"
   href="https://llvm.org/bugs/show_bug.cgi?id=30474">30474</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>clang: assertion failure while checking format strings in libiconv
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>new-bugs
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

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

        <tr>
          <th>OS</th>
          <td>Linux
          </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>new bugs
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>willdtz@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="attachment.cgi?id=17326" name="attach_17326" title="preprocessed C source from libiconv-1.14">attachment 17326</a> <a href="attachment.cgi?id=17326&action=edit" title="preprocessed C source from libiconv-1.14">[details]</a></span>
preprocessed C source from libiconv-1.14

Assertion failure:

clang-4.0: ~/llvm/latest/include/llvm/Support/Casting.h:237: typename
llvm::cast_retty<X, Y*>::ret_type llvm::cast(Y*) [with X =
clang::UnaryOperator; Y = const clang::Expr; typename llvm::cast_retty<X,
Y*>::ret_type = const clang::UnaryOperator*]: Assertion `isa<X>(Val) &&
"cast<Ty>() argument of incompatible type!"' failed.
...
...
1.      ./iconv.c:401:42: current parser token ')'
2.      ./iconv.c:251:1: parsing function body 'check_subst_formatstring'
3.      ./iconv.c:251:1: in compound statement ('{}')


----------------

Reproducer attached, occurs with:

clang -c input.c -o input.o

Has been occurring with trunk for at least a few days, and still occurs on
trunk as of time of writing.

Let me know if you have any trouble reproducing or if there's anything more I
can do to help resolve this.</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>