[PATCH] D138597: DebugInfo: Add/support new DW_LANG codes for recent C and C++ versions

Adrian Prantl via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Dec 6 12:26:53 PST 2022


aprantl accepted this revision.
aprantl added a comment.
This revision is now accepted and ready to land.

This minimal patch LGTM.



================
Comment at: llvm/lib/IR/DIBuilder.cpp:159
 
-  assert(((Lang <= dwarf::DW_LANG_Fortran08 && Lang >= dwarf::DW_LANG_C89) ||
+  assert(((Lang <= dwarf::DW_LANG_Ada2012 && Lang >= dwarf::DW_LANG_C89) ||
           (Lang <= dwarf::DW_LANG_hi_user && Lang >= dwarf::DW_LANG_lo_user)) &&
----------------
dblaikie wrote:
> aprantl wrote:
> > Should we define a DW_LANG_HI_DWARF in the .def file?
> Maybe? I'm not sure - if it has to explicitly write the constant or another enum value in there, I think it's as liable to get missed when updating as this code, perhaps? Open to ideas.
I guess this isn't important enough to spend too much time designing a solution for it. Let's leave it as is.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D138597/new/

https://reviews.llvm.org/D138597



More information about the cfe-commits mailing list