From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1879) id 1FD1C3858C74; Mon, 2 May 2022 20:14:35 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1FD1C3858C74 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Simon Marchi To: gdb-cvs@sourceware.org Subject: [binutils-gdb] gdb: remove type_wanted parameter from a few functions X-Act-Checkin: binutils-gdb X-Git-Author: Simon Marchi X-Git-Refname: refs/heads/master X-Git-Oldrev: b318629fe742b2d9595eee1a2c35e81149ba33b2 X-Git-Newrev: 03ada39ea590fec3bd722e9ea776049213da8b58 Message-Id: <20220502201435.1FD1C3858C74@sourceware.org> Date: Mon, 2 May 2022 20:14:35 +0000 (GMT) X-BeenThere: gdb-cvs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 May 2022 20:14:35 -0000 https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3D03ada39ea590= fec3bd722e9ea776049213da8b58 commit 03ada39ea590fec3bd722e9ea776049213da8b58 Author: Simon Marchi Date: Mon May 2 16:08:19 2022 -0400 gdb: remove type_wanted parameter from a few functions =20 The type_wanted value, passed down to the create_sals_from_location callback, is never used. Remove it. =20 Change-Id: Ic363ee13f6af593a3e875ff7fe46de130cdc190c Diff: --- gdb/breakpoint.c | 26 ++++++++++---------------- gdb/breakpoint.h | 3 +-- 2 files changed, 11 insertions(+), 18 deletions(-) diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c index 83f5e7588e0..7241b7b6985 100644 --- a/gdb/breakpoint.c +++ b/gdb/breakpoint.c @@ -91,8 +91,7 @@ static void breakpoint_re_set_default (struct breakpoint = *); =20 static void create_sals_from_location_default (struct event_location *location, - struct linespec_result *canonical, - enum bptype type_wanted); + struct linespec_result *canonical); =20 static void create_breakpoints_sal (struct gdbarch *, struct linespec_result *, @@ -234,12 +233,10 @@ static int strace_marker_p (struct breakpoint *b); =20 static void bkpt_probe_create_sals_from_location (struct event_location *location, - struct linespec_result *canonical, - enum bptype type_wanted); + struct linespec_result *canonical); static void tracepoint_probe_create_sals_from_location (struct event_location *location, - struct linespec_result *canonical, - enum bptype type_wanted); + struct linespec_result *canonical); =20 const struct breakpoint_ops base_breakpoint_ops =3D { @@ -8892,7 +8889,7 @@ create_breakpoint (struct gdbarch *gdbarch, =20 try { - ops->create_sals_from_location (location, &canonical, type_wanted); + ops->create_sals_from_location (location, &canonical); } catch (const gdb_exception_error &e) { @@ -11960,8 +11957,8 @@ longjmp_breakpoint::~longjmp_breakpoint () =20 static void bkpt_probe_create_sals_from_location (struct event_location *location, - struct linespec_result *canonical, - enum bptype type_wanted) + struct linespec_result *canonical) + { struct linespec_sals lsal; =20 @@ -12079,11 +12076,10 @@ tracepoint::decode_location (struct event_locatio= n *location, static void tracepoint_probe_create_sals_from_location (struct event_location *location, - struct linespec_result *canonical, - enum bptype type_wanted) + struct linespec_result *canonical) { /* We use the same method for breakpoint on probes. */ - bkpt_probe_create_sals_from_location (location, canonical, type_wanted); + bkpt_probe_create_sals_from_location (location, canonical); } =20 void @@ -12150,8 +12146,7 @@ dprintf_breakpoint::after_condition_true (struct bp= stat *bs) =20 static void strace_marker_create_sals_from_location (struct event_location *location, - struct linespec_result *canonical, - enum bptype type_wanted) + struct linespec_result *canonical) { struct linespec_sals lsal; const char *arg_start, *arg; @@ -12894,8 +12889,7 @@ breakpoint_re_set_default (struct breakpoint *b) =20 static void create_sals_from_location_default (struct event_location *location, - struct linespec_result *canonical, - enum bptype type_wanted) + struct linespec_result *canonical) { parse_breakpoint_sals (location, canonical); } diff --git a/gdb/breakpoint.h b/gdb/breakpoint.h index 94ae70698a4..1322bc1b9b9 100644 --- a/gdb/breakpoint.h +++ b/gdb/breakpoint.h @@ -568,8 +568,7 @@ struct breakpoint_ops =20 This function is called inside `create_breakpoint'. */ void (*create_sals_from_location) (struct event_location *location, - struct linespec_result *canonical, - enum bptype type_wanted); + struct linespec_result *canonical); =20 /* This method will be responsible for creating a breakpoint given its S= ALs. Usually, it just calls `create_breakpoints_sal' (for ordinary