https://bugs.llvm.org/show_bug.cgi?id=43079

            Bug ID: 43079
           Summary: clang  calls the base object constructor (c2), gcc
                    calls the complete object constructor (c1)
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: C++
          Assignee: unassignedclangb...@nondot.org
          Reporter: raf...@espindo.la
                CC: blitzrak...@gmail.com, dgre...@apple.com,
                    erik.pilking...@gmail.com, llvm-bugs@lists.llvm.org,
                    richard-l...@metafoo.co.uk

With libstdc++ 9.1 and

#include <filesystem>
void foo() {
    for (auto& dev : std::filesystem::directory_iterator("slaves")) {
    }
}

clang calls
_ZNSt12__shared_ptrINSt10filesystem7__cxx114_DirELN9__gnu_cxx12_Lock_policyE2EEC2EOS5_
and gcc calls
_ZNSt12__shared_ptrINSt10filesystem7__cxx114_DirELN9__gnu_cxx12_Lock_policyE2EEC1EOS5_.

This is a problem because libstdc++ has

  extern template class
    __shared_ptr<filesystem::_Dir>;

but only
_ZNSt12__shared_ptrINSt10filesystem7__cxx114_DirELN9__gnu_cxx12_Lock_policyE2EEC1
is exported in the .so.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to