Issue |
134996
|
Summary |
Add `DynamicAllocLValue` and `TypeInfoLValue` support to `APValue::dump()`
|
Labels |
good first issue,
clang:frontend
|
Assignees |
|
Reporter |
tbaederr
|
`APValue` recently gained support for `dump()`ing lvalues, however, the code to handle them is missing support for lvalue bases of type `TypeInfoLValue` and `DynamicAllocLValue`:
https://github.com/llvm/llvm-project/blob/a29be9f28e8e0d4ca7a8a3cfdffe616ac780c754/clang/lib/AST/TextNodeDumper.cpp#L732-L761
Before the `else {` branch that unconditionally assumes the base to be a `const ValueDecl*`, we need to check whether the base is a dynamic alloc value or a typeid value: https://github.com/llvm/llvm-project/blob/a29be9f28e8e0d4ca7a8a3cfdffe616ac780c754/clang/lib/AST/ExprConstant.cpp#L2124-L2125
... and print something appropriate, or at least not crash.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs