[llvm-bugs] [Bug 51465] New: Clang should not warn "capture 'this' is not used" if it is used in another branch of if-constexpr.

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Aug 12 16:52:08 PDT 2021


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

            Bug ID: 51465
           Summary: Clang should not warn "capture 'this' is not used" if
                    it is used in another branch of if-constexpr.
           Product: clang
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: C++2a
          Assignee: unassignedclangbugs at nondot.org
          Reporter: z.zoelec2 at gmail.com
                CC: blitzrakete at gmail.com, erik.pilkington at gmail.com,
                    llvm-bugs at lists.llvm.org, richard-llvm at metafoo.co.uk

The following will fail to compile, even though the member "p" is used in
another branch of the if-constexpr: https://godbolt.org/z/hWbjbWYjq

-- 
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/20210812/a9904ff1/attachment.html>


More information about the llvm-bugs mailing list