[llvm-bugs] [Bug 52492] New: [Modules] Explicit/partial specialization is not reachable

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Nov 12 11:48:08 PST 2021


            Bug ID: 52492
           Summary: [Modules] Explicit/partial specialization is not
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Keywords: compile-fail
          Severity: enhancement
          Priority: P
         Component: C++2b
          Assignee: unassignedclangbugs at nondot.org
          Reporter: johelegp at gmail.com
                CC: blitzrakete at gmail.com, erik.pilkington at gmail.com,
                    johelegp at gmail.com, llvm-bugs at lists.llvm.org,
                    richard-llvm at metafoo.co.uk

Another reachability bug. See https://godbolt.org/z/33KxaYj8h, which GCC
accepts: https://godbolt.org/z/do9Yz3sds.

export module mod;
export template <class> inline constexpr bool b{false};
template <> inline constexpr bool b<int>{true};

import mod;
int main() { }

test.cpp:2:15: error: explicit specialization of 'b<int>' must be imported from
module 'mod' before it is required
mod.cpp:3:35: note: explicit specialization declared here is not reachable
template <> inline constexpr bool b<int>{true};
1 error generated.

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/20211112/0e171916/attachment.html>

More information about the llvm-bugs mailing list