[LLVMbugs] [Bug 14175] New: gperftools compilation fails

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Oct 25 01:48:11 PDT 2012


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

             Bug #: 14175
           Summary: gperftools compilation fails
           Product: libc++
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: All Bugs
        AssignedTo: hhinnant at apple.com
        ReportedBy: vvavrychuk at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


gperftools fails to compile with libc++

Error message is

In file included from src/heap-checker.cc:69:
In file included from ../libcxx/include/string:434:
In file included from ../libcxx/include/algorithm:594:
../libcxx/include/memory:1608:18: error: no matching member function for call
to 'construct'
            {__a.construct(__p, _VSTD::forward<_Args>(__args)...);}
             ~~~~^~~~~~~~~
../libcxx/include/memory:1492:14: note: in instantiation of function template
specialization
'std::__1::allocator_traits<STL_Allocator<std::__1::__tree_node<std::__1::pair<std::__1::basic_string<char,
std::__1::char_traits<char>, STL_Allocator<char, HeapLeakChecker::Allocator> >,
std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> > >, void *>, HeapLeakChecker::Allocator>
>::__construct<std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> >, >' requested here
            {__construct(__has_construct<allocator_type, pointer, _Args...>(),
             ^
../libcxx/include/map:1226:20: note: in instantiation of function template
specialization
'std::__1::allocator_traits<STL_Allocator<std::__1::__tree_node<std::__1::pair<std::__1::basic_string<char,
std::__1::char_traits<char>, STL_Allocator<char, HeapLeakChecker::Allocator> >,
std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> > >, void *>, HeapLeakChecker::Allocator>
>::construct<std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> >, >' requested here
    __node_traits::construct(__na, _VSTD::addressof(__h->__value_.second));
                   ^
../libcxx/include/map:1294:29: note: in instantiation of function template
specialization 'std::__1::map<std::__1::basic_string<char,
std::__1::char_traits<char>, STL_Allocator<char, HeapLeakChecker::Allocator> >,
std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> >, std::__1::less<std::__1::basic_string<char,
std::__1::char_traits<char>, STL_Allocator<char, HeapLeakChecker::Allocator> >
>, STL_Allocator<std::__1::pair<const std::__1::basic_string<char,
std::__1::char_traits<char>, STL_Allocator<char, HeapLeakChecker::Allocator> >,
std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> > >, HeapLeakChecker::Allocator>
>::__construct_node<std::__1::basic_string<char, std::__1::char_traits<char>,
STL_Allocator<char, HeapLeakChecker::Allocator> > >' requested here
        __node_holder __h = __construct_node(_VSTD::move(__k));
                            ^
src/heap-checker.cc:815:26: note: in instantiation of member function
'std::__1::map<std::__1::basic_string<char, std::__1::char_traits<char>,
STL_Allocator<char, HeapLeakChecker::Allocator> >,
std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> >, std::__1::less<std::__1::basic_string<char,
std::__1::char_traits<char>, STL_Allocator<char, HeapLeakChecker::Allocator> >
>, STL_Allocator<std::__1::pair<const std::__1::basic_string<char,
std::__1::char_traits<char>, STL_Allocator<char, HeapLeakChecker::Allocator> >,
std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> > >, HeapLeakChecker::Allocator> >::operator[]'
requested here
  (*library_live_objects)[filename].
                         ^
./src/base/stl_allocator.h:90:8: note: candidate function not viable: no known
conversion from 'std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> > *' to 'pointer' (aka
'std::__1::__tree_node<std::__1::pair<std::__1::basic_string<char,
std::__1::char_traits<char>, STL_Allocator<char, HeapLeakChecker::Allocator> >,
std::__1::vector<AllocObject, STL_Allocator<AllocObject,
HeapLeakChecker::Allocator> > >, void *> *') for 1st argument
  void construct(pointer p) { ::new(p) T(); }
       ^
./src/base/stl_allocator.h:89:8: note: candidate function not viable: requires
2 arguments, but 1 was provided
  void construct(pointer p, const T& val) { ::new(p) T(val); }
       ^
1 error generated.

-- 
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