[LLVMbugs] [Bug 16478] New: Attribute always_inline breaks function pointers

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Jun 27 17:03:16 PDT 2013


http://llvm.org/bugs/show_bug.cgi?id=16478

            Bug ID: 16478
           Summary: Attribute always_inline breaks function pointers
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: joerg at NetBSD.org
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Consider this program:

#include <functional>
#include <string>

int main() {
   std::bind(&std::string::c_str, std::string());
   return 0;
}

Building with Clang against libc++ fails at link time, because string::c_str is
not implemented. As a pointer to the function escapes, I would expect a weak
link_once implementation to be emitted.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20130628/b32108bc/attachment.html>


More information about the llvm-bugs mailing list