[LLVMbugs] [Bug 11713] New: clang++ fails to compile boost::bind with template function

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Jan 5 06:33:06 PST 2012


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

             Bug #: 11713
           Summary: clang++ fails to compile boost::bind with template
                    function
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: release blocker
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: juergen.hunold at ivembh.de
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified


Created attachment 7841
  --> http://llvm.org/bugs/attachment.cgi?id=7841
self-containing testcase

I've got some code using boost::bind and custom templates.
Stripped down testcase attached.

Tested clang:
clang version 3.1 (trunk 147599)
Target: x86_64-unknown-linux-gnu
Thread model: posix

The test case compile with gcc-4.6.1
gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) 

that is from stock ubuntu 11.10

The original code also compiles and work with msvc-9.0 and gcc-4.6.3 mingw

The error message from clang (start) is:

bind.cpp:35:5: error: no matching function for call to 'bind'
    boost::bind(do_work<std::set<std::string> >,

BOOST_ROOT/boost/bind/bind.hpp:1314:5: note: candidate template ignored:
couldn't infer template argument 'R'
    BOOST_BIND(F f, A1 a1, A2 a2)

lots of failed template instantion backtrace stripped ;-))

This happens with Boost trunk, but should be reproducible with Boost 1.48.0,
too.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list