Move more code to line-header.c
authorTom Tromey <tom@tromey.com>
Thu, 26 Mar 2020 15:28:08 +0000 (09:28 -0600)
committerTom Tromey <tom@tromey.com>
Thu, 26 Mar 2020 15:28:20 +0000 (09:28 -0600)
commit0df7ad3a675692fcc75c85c43e475015b87a297e
treec0393ec9b1527e4ae97e23c90e7310d1461bc9f6
parent86c0bb4c57111422b30da6b1b20256bd3a06778a
Move more code to line-header.c

This moves some more code out of read.c and into line-header.c.
dwarf_decode_line_header is split into two -- the part remaining in
read.c handles interfacing to the dwarf2_cu; while the part in
line-header.c (more or less) purely handles the actual decoding.

gdb/ChangeLog
2020-03-26  Tom Tromey  <tom@tromey.com>

* dwarf2/line-header.h (dwarf_decode_line_header): Declare.
* dwarf2/read.c
(dwarf2_statement_list_fits_in_line_number_section_complaint):
Move to line-header.c.
(read_checked_initial_length_and_offset, read_formatted_entries):
Likewise.
(dwarf_decode_line_header): Split into two.
* dwarf2/line-header.c
(dwarf2_statement_list_fits_in_line_number_section_complaint):
Move from read.c.
(read_checked_initial_length_and_offset, read_formatted_entries):
Likewise.
(dwarf_decode_line_header): New function, split from read.c.
gdb/ChangeLog
gdb/dwarf2/line-header.c
gdb/dwarf2/line-header.h
gdb/dwarf2/read.c