[LLVMbugs] [Bug 16385] New: Using std::bind with std::function leads to stack overflow

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Jun 20 00:22:33 PDT 2013


            Bug ID: 16385
           Summary: Using std::bind with std::function leads to stack
           Product: libc++
           Version: 3.2
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: release blocker
          Priority: P
         Component: All Bugs
          Assignee: hhinnant at apple.com
          Reporter: spam at madsitenet.de
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 10709
  --> http://llvm.org/bugs/attachment.cgi?id=10709&action=edit

I'm using the 3.3 sources from the following page:

If the first parameter to a std::bind is a std::function, the code does not
work. The stack shows up to 63k recursive calls to:
std::__1__function<float (float,
float)>::function<std::__1::__bind<std::__1::function<float (float, float)>&,
float, float > > ()

How to compile:
clang++ -std=c++11 -stdlib=libc++ -lcxxrt -ldl a.cpp

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/20130620/1ed9ed4f/attachment.html>

More information about the llvm-bugs mailing list