Change machoread.c to use std::vector
authorTom Tromey <tom@tromey.com>
Fri, 16 Mar 2018 22:44:01 +0000 (16:44 -0600)
committerTom Tromey <tom@tromey.com>
Fri, 23 Mar 2018 16:04:57 +0000 (10:04 -0600)
commit2cc9b3048bcbb827e69059fb6beacb9bccbc5d7c
tree002c28b7d0cbfed89b5206d21bc5e3f2cb6e9408
parentdff7492c9b221aacd4efa6675bb288dfb5d50f80
Change machoread.c to use std::vector

This changes machoread.c to use std::vector rather than VEC.  This
allows removing some cleanups.

Regression tested by the buildbot, though I don't think anything
actually tests macho reading.

gdb/ChangeLog
2018-03-23  Tom Tromey  <tom@tromey.com>

* machoread.c (struct oso_el): Add a constructor.  Don't define as
a typedef.
(macho_register_oso): Remove.
(macho_symtab_read): Take a std::vector.
(oso_el_compare_name): Now a std::sort comparator.
(macho_symfile_read_all_oso): Take a std::vector.
(macho_symfile_read): Use std::vector.  Remove cleanups.
gdb/ChangeLog
gdb/machoread.c