Commit 1832c03
authored
Fix llvm20 compilation error (#5194)
The following is the error message:
/home/yhs/work/bcc/src/cc/frontends/clang/b_frontend_action.cc: In member function
‘bool ebpf::BTypeVisitor::VisitBinaryOperator(clang::BinaryOperator*)’:
/home/yhs/work/bcc/src/cc/frontends/clang/b_frontend_action.cc:1383:64: error:
no matching function for call to ‘clang::FieldDecl::getBitWidthValue(clang::ASTContext&)’
1383 | uint64_t sz = F->isBitField() ? F->getBitWidthValue(C) : C.getTypeSize(F->getType());
| ~~~~~~~~~~~~~~~~~~~^~~
which is due to upstream patch:
llvm/llvm-project#122289
This patch fixed the above compilation error.
Signed-off-by: Yonghong Song <[email protected]>1 parent 68710c4 commit 1832c03
File tree
2 files changed
+14
-1
lines changed- src/cc
- frontends/clang
2 files changed
+14
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1380 | 1380 | | |
1381 | 1381 | | |
1382 | 1382 | | |
| 1383 | + | |
| 1384 | + | |
| 1385 | + | |
1383 | 1386 | | |
| 1387 | + | |
1384 | 1388 | | |
1385 | 1389 | | |
1386 | 1390 | | |
| |||
1410 | 1414 | | |
1411 | 1415 | | |
1412 | 1416 | | |
| 1417 | + | |
| 1418 | + | |
| 1419 | + | |
1413 | 1420 | | |
| 1421 | + | |
1414 | 1422 | | |
1415 | 1423 | | |
1416 | 1424 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
86 | 86 | | |
87 | 87 | | |
88 | 88 | | |
89 | | - | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
90 | 93 | | |
| 94 | + | |
| 95 | + | |
91 | 96 | | |
92 | 97 | | |
93 | 98 | | |
| |||
0 commit comments