From eb1e02fd05688c28686a02f197c5e7cb0a5d6a27 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Wed, 6 Sep 2017 17:18:23 -0600 Subject: Use std::vector in add_using_directive This changes add_using_directive to accept a std::vector and then changes the callers. This allows removing a cleanup. ChangeLog 2017-09-09 Tom Tromey * namespace.h (add_using_directive): Update. * namespace.c (add_using_directive): Change type of excludes to std::vector. * dwarf2read.c (read_import_statement): Use std::vector. (read_namespace): Update. * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update. --- gdb/cp-namespace.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'gdb/cp-namespace.c') diff --git a/gdb/cp-namespace.c b/gdb/cp-namespace.c index f27783a..90ff513 100644 --- a/gdb/cp-namespace.c +++ b/gdb/cp-namespace.c @@ -93,8 +93,9 @@ cp_scan_for_anonymous_namespaces (const struct symbol *const symbol, anonymous namespace. So add symbols in it to the namespace given by the previous component if there is one, or to the global namespace if there isn't. */ + std::vector excludes; add_using_directive (&local_using_directives, - dest, src, NULL, NULL, NULL, 1, + dest, src, NULL, NULL, excludes, 1, &objfile->objfile_obstack); } /* The "+ 2" is for the "::". */ -- cgit v1.1