Change find_pcs_for_symtab_line to return a std::vector

This changes find_pcs_for_symtab_line to return a std::vector.  This
allows the removal of some cleanups.

gdb/ChangeLog
2017-04-12  Tom Tromey  <tom@tromey.com>

	* symtab.h (find_pcs_for_symtab_line): Change return type.
	* symtab.c (find_pcs_for_symtab_line): Change return type.
	* python/py-linetable.c (build_line_table_tuple_from_pcs): Change
	type of "vec".  Update.
	(ltpy_get_pcs_for_line): Update.
	* linespec.c (decode_digits_ordinary): Update.
This commit is contained in:
Tom Tromey 2017-04-06 16:38:56 -06:00
parent 93921405a4
commit 67d8990150
5 changed files with 28 additions and 30 deletions

View file

@ -20,7 +20,7 @@
#if !defined (SYMTAB_H)
#define SYMTAB_H 1
#include "vec.h"
#include <vector>
#include "gdb_vecs.h"
#include "gdbtypes.h"
#include "common/enum-flags.h"
@ -1618,8 +1618,8 @@ void iterate_over_symtabs (const char *name,
gdb::function_view<bool (symtab *)> callback);
VEC (CORE_ADDR) *find_pcs_for_symtab_line (struct symtab *symtab, int line,
struct linetable_entry **best_entry);
std::vector<CORE_ADDR> find_pcs_for_symtab_line
(struct symtab *symtab, int line, struct linetable_entry **best_entry);
/* Prototype for callbacks for LA_ITERATE_OVER_SYMBOLS. The callback
is called once per matching symbol SYM. The callback should return