Commit 848e3dd
committed
CheriRangeChecker: C++20 aggregate type rules
Remove the user-declared (but not user-provided) explicitly-defaulted
(but not explicit) default constructors from ValueSource and
AllocOperands so that these types are considered to be aggregate types
under both C++11 and C++20. Relative to C++11, C++20 additionally
precludes user-declared constructors on aggregates.
Fixes, among others, the following build errors (where the code uses
aggregate initialization syntax for these types):
.../llvm/lib/Target/Mips/CheriRangeChecker.cpp:72:12: error: no matching constructor for initialization of 'ValueSource'
72 | return ValueSource{Src, Offset};
.../llvm/lib/Target/Mips/CheriRangeChecker.cpp:93:16: error: no matching constructor for initialization of 'AllocOperands'
93 | return AllocOperands{Malloc->getArgOperand(0), nullptr, Src,1 parent bd3ac5d commit 848e3dd
1 file changed
+0
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
34 | 33 | | |
35 | 34 | | |
36 | 35 | | |
37 | 36 | | |
38 | | - | |
39 | 37 | | |
40 | 38 | | |
41 | 39 | | |
| |||
0 commit comments