[llvm-bugs] [Bug 34849] New: clang-cl fails to dllexport specialization of class template member function when the class template is dllexport

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Oct 5 11:33:28 PDT 2017


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

            Bug ID: 34849
           Summary: clang-cl fails to dllexport specialization of class
                    template member function when the class template is
                    dllexport
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: hans at chromium.org
                CC: llvm-bugs at lists.llvm.org

struct T;
template <typename> struct __declspec(dllexport) S { void foo(); };

template<> void S<T>::foo() {}  <-- Should be exported.
template struct S<T>;


This happens because the specialization occurs before the instantiation of
S<int>, so the attribute doesn't get inherited.

-- 
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/20171005/fe6d4b08/attachment.html>


More information about the llvm-bugs mailing list