From e6a959d68b8181c816851dcfc91ae0b2b9296df3 Mon Sep 17 00:00:00 2001 From: Pedro Alves Date: Tue, 13 Oct 2015 19:40:50 +0100 Subject: More char constification MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Trivial constifications flagged by G++. E.g.: src/gdb/c-varobj.c: In function ‘void c_describe_child(const varobj*, int, char**, value**, type**, char**)’: src/gdb/c-varobj.c:373:33: error: invalid conversion from ‘const char*’ to ‘char*’ [-fpermissive] char *join = was_ptr ? "->" : "."; ^ gdb/ChangeLog: 2015-10-13 Pedro Alves * ada-lang.c (ada_enum_name): Constify local. * ada-typeprint.c (print_range_bound): Constify locals. * c-varobj.c (c_describe_child): Likewise. * cli/cli-setshow.c (do_set_command): Likewise. * gdb_vecs.c (delim_string_to_char_ptr_vec_append): Likewise. * dwarf2read.c (find_file_and_directory): Likewise. (anonymous_struct_prefix, dwarf2_name): Likewise. * gnu-v3-abi.c (gnuv3_rtti_type): Likewise. * go-lang.c (unpack_mangled_go_symbol): Likewise. * jv-typeprint.c (java_type_print_base): Likewise. * ser-tcp.c (net_open): Likewise. * symfile.c (deduce_language_from_filename): Likewise. * symtab.c (gdb_mangle_name): Likewise. * tui/tui-io.c (tui_redisplay_readline): Likewise. --- gdb/gnu-v3-abi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gdb/gnu-v3-abi.c') diff --git a/gdb/gnu-v3-abi.c b/gdb/gnu-v3-abi.c index b962cd3..09e085b 100644 --- a/gdb/gnu-v3-abi.c +++ b/gdb/gnu-v3-abi.c @@ -296,7 +296,7 @@ gnuv3_rtti_type (struct value *value, const char *class_name; struct type *run_time_type; LONGEST offset_to_top; - char *atsign; + const char *atsign; /* We only have RTTI for class objects. */ if (TYPE_CODE (values_type) != TYPE_CODE_STRUCT) -- cgit v1.1