<html>
    <head>
      <base href="http://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 with -fms-extensions should treat __inline in C as it treats inline in C++"
   href="http://llvm.org/bugs/show_bug.cgi?id=16766">16766</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>clang with -fms-extensions should treat __inline in C as it treats inline in C++
          </td>
        </tr>

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

        <tr>
          <th>Version</th>
          <td>unspecified
          </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>Frontend
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>reid.kleckner@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvmbugs@cs.uiuc.edu
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr></table>
      <p>
        <div>
        <pre>The MSDN docs spell this out:
<a href="http://msdn.microsoft.com/en-us/library/z8y1yy88.aspx">http://msdn.microsoft.com/en-us/library/z8y1yy88.aspx</a>

"The inline keyword is available only in C++. The __inline and __forceinline
keywords are available in both C and C++."
...
"The __inline keyword is equivalent to inline."

In particular, this code similar to some in winnt.h will cause multiple
definition link errors:
int foo(int);
__inline int foo(int x) { return x; }

Clang will emit a strong definition for foo instead of a weak or linkonce
definition.

This prevents clang from compiling and linking multiple C files that include
windows.h.

I don't think this will break people following C99 inline rules, but it will
cause them to start emitting more linkonce code.</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>