> On 10 Jun 2018, at 21:26, Jakub Jelinek <ja...@redhat.com> wrote:
>> http://wiki.dwarfstd.org/index.php?title=DWARF_Language_Support
>
> Well, you should better be looking at the pdfs of the standards, that is
> more precise.
Ok
> And there it says:
> Names marked with † and their associated values are reserved,
> but the languages they represent are not supported in DWARF Version 2.
> ...
> DW_LANG_Ada83† 0x0003
>
> so, using DW_LANG_Ada83 is fine for dwarf-2.
Good,
>> 2018-06-10 Olivier Hainque <hain...@adacore.com>
>>
>> * dwarf2out.c (gen_compile_unit_die): fallout to DW_LANG_Ada83
>> for Ada with strict dwarf2.
>
> Use uppercase Fallout.
> Otherwise ok for trunk.
Great, thanks!
FWIW, I was surprised by a gotcha while writing tests for this,
where both
{ dg-final { scan-assembler "0x3.*DW_AT_language" } }
and { dg-final { scan-assembler "0xd.*DW_AT_language" } }
matched for Ada95 (0xd) with -gdwarf-3.
scan-assembler uses "regexp" without --line, and 0x3 happened
to match from a much earlier line in the output, with an assembly
output like
bla 0x3 blo
<some other dwarf>
0xd # DW_AT_language
I adjusted the regex not to match newline characters and the
test is now more accurate, then I noticed that other language tests
use '.*' so might be affected as well, unless I'm missing something.
Regards,
Olivier