constify some cli-utils stuff
authorTom Tromey <tromey@redhat.com>
Tue, 22 Jul 2014 16:47:53 +0000 (10:47 -0600)
committerTom Tromey <tromey@redhat.com>
Wed, 30 Jul 2014 14:02:52 +0000 (08:02 -0600)
commite799154c3bf1aac0bffd869df5eed7a959305d00
tree5f73896f9f771cfa01e7b2bfddcf234632ed6bf4
parent5f08566b92f63e60559577dedfabf9ed517a3ddf
constify some cli-utils stuff

This constifies a few functions in cli-utils -- get_number_trailer and
friends -- and then fixes the fallout.

2014-07-30  Tom Tromey  <tromey@redhat.com>

* breakpoint.c (map_breakpoint_numbers): Update.
* cli/cli-utils.c (get_number_trailer): Make "pp" const.  Update.
(get_number_const): New function.
(get_number): Rewrite using get_number_const.
(init_number_or_range): Make "string" const.
(number_is_in_list): Make "list" const.
* cli/cli-utils.h (get_number_const): Declare.
(struct get_number_or_range_state) <string, end_ptr>: Now const.
(init_number_or_range, number_is_in_list): Update.
* printcmd.c (map_display_numbers): Update.
* value.c (value_from_history_ref): Constify.
* value.h (value_from_history_ref): Update.
gdb/ChangeLog
gdb/breakpoint.c
gdb/cli/cli-utils.c
gdb/cli/cli-utils.h
gdb/printcmd.c
gdb/value.c
gdb/value.h