Commit 90febd4
committed
[Clang] Only ignore special methods for unused private fields in BuildFieldReferenceExpr
The original code assumed that only special methods might be defined
as defaulted. Since C++20 comparison operators might be defaulted too,
and we *do* want to consider those as using the fields of the class.
Fixes: #1169611 parent d88ed93 commit 90febd4
File tree
2 files changed
+24
-2
lines changed- clang
- lib/Sema
- test/SemaCXX
2 files changed
+24
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1874 | 1874 | | |
1875 | 1875 | | |
1876 | 1876 | | |
1877 | | - | |
1878 | | - | |
| 1877 | + | |
| 1878 | + | |
| 1879 | + | |
| 1880 | + | |
| 1881 | + | |
| 1882 | + | |
| 1883 | + | |
| 1884 | + | |
| 1885 | + | |
| 1886 | + | |
1879 | 1887 | | |
1880 | 1888 | | |
1881 | 1889 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
23 | 37 | | |
24 | 38 | | |
25 | 39 | | |
| |||
0 commit comments