<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/62594>62594</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            static lambda call operator is not convertible to function pointer on windows
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
            faisalv
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          faisalv
      </td>
    </tr>
</table>

<pre>
    This code does not work with clang compiled with msvc.
```cpp  
  auto lstatic = []()  static  { return 0; };
  int (*f2)(void) = lstatic; 
```
I am working on a quick patch to fix it (the wrong calling convention `CC_X86ThisCall` is getting assigned in spite of the `static`).
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxUkk-PnDAMxT-NuVg7Cgl_hgOHnR2N1HsPvVUhBHA3JDQxQ_vtKxiqqhISwsHP7_1inRKN3toWyhtIOWhK2j1BSijvmV55CrE9i1kX-t_t14kSmtBb7INN6APjFuInbsQTGqf9iCbMCznbv2pzepoLiDuId6jE6zHLgviqIeqVA7rEmskgqDvuVso7yCvIBvE8QKhvGC2v0aMAdUOo76Buf0XIMx4d74ME2YC8PgP1u8CueKofbf87eX1-QT0fMciPGDxq_LmS-cRFs5mQAw70C-mYwJPFLYY9pnaOjrj-aT1T8AiV-Pj4_u1a7ZQ-tHNQCaSEo2Xefz1p90ge00JsMQy4K0IlTouVANlcsr5VfaMandk2r66qqHOl8mxqdWkaW1V9WdRalULXKu_UNe_qWtVFr8uMWimkEqWo86IsVX4ZrNFKX6vBloUahIZC2FmTuzj3nC8hjhmltNq2kmVTZE531qVzG7zd8Dg89yG2e89bt44JCuEocfqnwsTOtudtOT13vT4QYVhs1BziDmJfl4NXZOqcPdCu3hzwlkCebdz5b-T7sKVsja6dmJcE6h3kA-RjJJ7W7mLCDPKxzz5fb0sMP6xhkI_DcQL5OBL9CQAA__8OM-jX">