This is the mail archive of the
gdb-cvs@sourceware.org
mailing list for the GDB project.
[binutils-gdb] Constify demangle_command
- From: Tom Tromey <tromey at sourceware dot org>
- To: gdb-cvs at sourceware dot org
- Date: 27 Sep 2017 14:58:26 -0000
- Subject: [binutils-gdb] Constify demangle_command
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=1f3f85eba696bfff4fea5e66167ee001c07c4b0b
commit 1f3f85eba696bfff4fea5e66167ee001c07c4b0b
Author: Tom Tromey <tom@tromey.com>
Date: Tue Sep 12 21:16:47 2017 -0600
Constify demangle_command
gdb/ChangeLog
2017-09-27 Tom Tromey <tom@tromey.com>
* demangle.c (demangle_command): Constify.
Diff:
---
gdb/ChangeLog | 4 ++++
gdb/demangle.c | 4 +---
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index a32596e..e089959 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,9 @@
2017-09-27 Tom Tromey <tom@tromey.com>
+ * demangle.c (demangle_command): Constify.
+
+2017-09-27 Tom Tromey <tom@tromey.com>
+
* progspace.c (maintenance_info_program_spaces_command):
Constify.
diff --git a/gdb/demangle.c b/gdb/demangle.c
index 5430fb6..1a97fb7 100644
--- a/gdb/demangle.c
+++ b/gdb/demangle.c
@@ -43,8 +43,6 @@
#define DEFAULT_DEMANGLING_STYLE AUTO_DEMANGLING_STYLE_STRING
#endif
-static void demangle_command (char *, int);
-
/* See documentation in gdb-demangle.h. */
int demangle = 1;
@@ -159,7 +157,7 @@ is_cplus_marker (int c)
/* Demangle the given string in the current language. */
static void
-demangle_command (char *args, int from_tty)
+demangle_command (const char *args, int from_tty)
{
char *demangled;
const char *name;