Currently only DWARF operator DW_OP_lit0 is accepted other in variants like DW_OP_lit1-31 are rejected.
Summary
llvm doesnt accept DW_OP_lit[1-31], it accepts only DW_OP_lit0.
it produces below error.
. . . .
invalid expression
!DIExpression(53, 30, 159)
. . . .
Current patch completes support for DWARF operator DW_OP_lit[1-31].
Testing
- Added unit test for validation thru llvm-dwarfdump
- check-debuginfo
- check-llvm
I know you did not introduce this, so I won't insist you change it, but LLVM style says do not use else after a continue.