https://bugs.llvm.org/show_bug.cgi?id=41867
Bug ID: 41867
Summary: "note: member call on member 'endpoint' of union with
active member 'interface' is not allowed in a constant
expression" note should include the member name
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: C++
Assignee: unassignedclangb...@nondot.org
Reporter: pho...@chromium.org
CC: blitzrak...@gmail.com, dgre...@apple.com,
erik.pilking...@gmail.com, llvm-bugs@lists.llvm.org,
richard-l...@metafoo.co.uk
With the tip-of-tree Clang, this is failing to compile because the
-Winvalid-constexpr has gotten more strict after r360499
(https://github.com/llvm/llvm-project/commit/d05df0ef4362855405ae1df76572909fb0ff55b2):
usb-mass-storage.cpp:30:37: error: constexpr function never produces a
constant expression [-Winvalid-constexpr]
static constexpr usb_descriptor Create(usb_endpoint_descriptor_t
descriptor) {
^
usb-mass-storage.cpp:32:25: note: member call on member 'endpoint' of union
with active member 'interface' is not allowed in a constant expression
retval.endpoint = descriptor;
^
1 error generated.
It would be useful if the note also included the name of the member which is
being called (in this case it's operator= but that's not completely obvious
from the message).
--
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