aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Kratochvil <jan.kratochvil@redhat.com>2010-06-14 08:26:57 +0000
committerJan Kratochvil <jan.kratochvil@redhat.com>2010-06-14 08:26:57 +0000
commit25b524e8361ae202a314ea75c2d943a1988318f8 (patch)
tree5fb895d68bb0edd62cec89e08cd804572cee3eb4
parentedee3f9217248a6c6b1bcedafafafd11afb704d8 (diff)
downloadfsf-binutils-gdb-25b524e8361ae202a314ea75c2d943a1988318f8.zip
fsf-binutils-gdb-25b524e8361ae202a314ea75c2d943a1988318f8.tar.gz
fsf-binutils-gdb-25b524e8361ae202a314ea75c2d943a1988318f8.tar.bz2
gdb/
* ada-lang.h (ada_print_type): Make varstring const. * ada-typeprint.c (print_func_type): Make name const. (ada_print_type): Make varstring const. * c-lang.h (c_print_type): Make varstring const. * c-typeprint.c (c_print_type): Likewise. * f-lang.h (f_print_type): Likewise. * f-typeprint.c (f_print_type): Likewise. * jv-lang.h (java_print_type): Likewise. * jv-typeprint.c (java_print_type): Likewise. * language.c (unk_lang_print_type): Likewise. * language.h (struct language_defn) <la_print_type>: Likewise. * m2-lang.h (m2_print_type): Likewise. * m2-typeprint.c (m2_print_type): Likewise. * p-lang.h (pascal_print_type): Likewise. * p-typeprint.c (pascal_print_type): Likewise.
-rw-r--r--gdb/ChangeLog18
-rw-r--r--gdb/ada-lang.h2
-rw-r--r--gdb/ada-typeprint.c6
-rw-r--r--gdb/c-lang.h2
-rw-r--r--gdb/c-typeprint.c2
-rw-r--r--gdb/f-lang.h2
-rw-r--r--gdb/f-typeprint.c2
-rw-r--r--gdb/jv-lang.h2
-rw-r--r--gdb/jv-typeprint.c4
-rw-r--r--gdb/language.c6
-rw-r--r--gdb/language.h2
-rw-r--r--gdb/m2-lang.h2
-rw-r--r--gdb/m2-typeprint.c2
-rw-r--r--gdb/p-lang.h3
-rw-r--r--gdb/p-typeprint.c4
15 files changed, 39 insertions, 20 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 03bc857..3907fa3 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,21 @@
+2010-06-14 Jan Kratochvil <jan.kratochvil@redhat.com>
+
+ * ada-lang.h (ada_print_type): Make varstring const.
+ * ada-typeprint.c (print_func_type): Make name const.
+ (ada_print_type): Make varstring const.
+ * c-lang.h (c_print_type): Make varstring const.
+ * c-typeprint.c (c_print_type): Likewise.
+ * f-lang.h (f_print_type): Likewise.
+ * f-typeprint.c (f_print_type): Likewise.
+ * jv-lang.h (java_print_type): Likewise.
+ * jv-typeprint.c (java_print_type): Likewise.
+ * language.c (unk_lang_print_type): Likewise.
+ * language.h (struct language_defn) <la_print_type>: Likewise.
+ * m2-lang.h (m2_print_type): Likewise.
+ * m2-typeprint.c (m2_print_type): Likewise.
+ * p-lang.h (pascal_print_type): Likewise.
+ * p-typeprint.c (pascal_print_type): Likewise.
+
2010-06-11 Stan Shebs <stan@codesourcery.com>
Add per-operation permission flags.
diff --git a/gdb/ada-lang.h b/gdb/ada-lang.h
index c51964a..d1e8ca5 100644
--- a/gdb/ada-lang.h
+++ b/gdb/ada-lang.h
@@ -156,7 +156,7 @@ extern int ada_parse (void); /* Defined in ada-exp.y */
extern void ada_error (char *); /* Defined in ada-exp.y */
/* Defined in ada-typeprint.c */
-extern void ada_print_type (struct type *, char *, struct ui_file *, int,
+extern void ada_print_type (struct type *, const char *, struct ui_file *, int,
int);
extern void ada_print_typedef (struct type *type, struct symbol *new_symbol,
diff --git a/gdb/ada-typeprint.c b/gdb/ada-typeprint.c
index 7e8a649..a02c8d4 100644
--- a/gdb/ada-typeprint.c
+++ b/gdb/ada-typeprint.c
@@ -664,7 +664,7 @@ print_unchecked_union_type (struct type *type, struct ui_file *stream,
for function or procedure NAME if NAME is not null. */
static void
-print_func_type (struct type *type, struct ui_file *stream, char *name)
+print_func_type (struct type *type, struct ui_file *stream, const char *name)
{
int i, len = TYPE_NFIELDS (type);
@@ -714,8 +714,8 @@ print_func_type (struct type *type, struct ui_file *stream, char *name)
LEVEL indicates level of recursion (for nested definitions). */
void
-ada_print_type (struct type *type0, char *varstring, struct ui_file *stream,
- int show, int level)
+ada_print_type (struct type *type0, const char *varstring,
+ struct ui_file *stream, int show, int level)
{
struct type *type = ada_check_typedef (ada_get_base_type (type0));
char *type_name = decoded_type_name (type0);
diff --git a/gdb/c-lang.h b/gdb/c-lang.h
index 8da1ff6..a04fbb2 100644
--- a/gdb/c-lang.h
+++ b/gdb/c-lang.h
@@ -63,7 +63,7 @@ extern void c_error (char *);
extern int c_parse_escape (char **, struct obstack *);
/* Defined in c-typeprint.c */
-extern void c_print_type (struct type *, char *, struct ui_file *, int,
+extern void c_print_type (struct type *, const char *, struct ui_file *, int,
int);
extern void c_print_typedef (struct type *, struct symbol *, struct ui_file *);
diff --git a/gdb/c-typeprint.c b/gdb/c-typeprint.c
index 2697c3a..9a6bc6d 100644
--- a/gdb/c-typeprint.c
+++ b/gdb/c-typeprint.c
@@ -56,7 +56,7 @@ static void c_type_print_modifier (struct type *, struct ui_file *,
/* LEVEL is the depth to indent lines by. */
void
-c_print_type (struct type *type, char *varstring, struct ui_file *stream,
+c_print_type (struct type *type, const char *varstring, struct ui_file *stream,
int show, int level)
{
enum type_code code;
diff --git a/gdb/f-lang.h b/gdb/f-lang.h
index ee3d91f..f5bb82d 100644
--- a/gdb/f-lang.h
+++ b/gdb/f-lang.h
@@ -25,7 +25,7 @@ extern int f_parse (void);
extern void f_error (char *); /* Defined in f-exp.y */
-extern void f_print_type (struct type *, char *, struct ui_file *, int,
+extern void f_print_type (struct type *, const char *, struct ui_file *, int,
int);
extern int f_val_print (struct type *, const gdb_byte *, int, CORE_ADDR,
diff --git a/gdb/f-typeprint.c b/gdb/f-typeprint.c
index 1343f68..ff013d0 100644
--- a/gdb/f-typeprint.c
+++ b/gdb/f-typeprint.c
@@ -52,7 +52,7 @@ void f_type_print_base (struct type *, struct ui_file *, int, int);
/* LEVEL is the depth to indent lines by. */
void
-f_print_type (struct type *type, char *varstring, struct ui_file *stream,
+f_print_type (struct type *type, const char *varstring, struct ui_file *stream,
int show, int level)
{
enum type_code code;
diff --git a/gdb/jv-lang.h b/gdb/jv-lang.h
index 24ca61e..aad5743 100644
--- a/gdb/jv-lang.h
+++ b/gdb/jv-lang.h
@@ -69,7 +69,7 @@ extern struct type *java_lookup_class (char *);
extern int is_object_type (struct type *);
/* Defined in jv-typeprint.c */
-extern void java_print_type (struct type *, char *, struct ui_file *, int,
+extern void java_print_type (struct type *, const char *, struct ui_file *, int,
int);
extern char *java_demangle_type_signature (char *);
diff --git a/gdb/jv-typeprint.c b/gdb/jv-typeprint.c
index 7e96b4d..0189ecf 100644
--- a/gdb/jv-typeprint.c
+++ b/gdb/jv-typeprint.c
@@ -332,8 +332,8 @@ extern void c_type_print_varspec_suffix (struct type *, struct ui_file *,
int, int, int);
void
-java_print_type (struct type *type, char *varstring, struct ui_file *stream,
- int show, int level)
+java_print_type (struct type *type, const char *varstring,
+ struct ui_file *stream, int show, int level)
{
int demangled_args;
diff --git a/gdb/language.c b/gdb/language.c
index 90bb228..3ce08b5 100644
--- a/gdb/language.c
+++ b/gdb/language.c
@@ -64,7 +64,7 @@ static void unk_lang_emit_char (int c, struct type *type,
static void unk_lang_printchar (int c, struct type *type,
struct ui_file *stream);
-static void unk_lang_print_type (struct type *, char *, struct ui_file *,
+static void unk_lang_print_type (struct type *, const char *, struct ui_file *,
int, int);
static int unk_lang_value_print (struct value *, struct ui_file *,
@@ -1097,8 +1097,8 @@ unk_lang_printstr (struct ui_file *stream, struct type *type,
}
static void
-unk_lang_print_type (struct type *type, char *varstring, struct ui_file *stream,
- int show, int level)
+unk_lang_print_type (struct type *type, const char *varstring,
+ struct ui_file *stream, int show, int level)
{
error (_("internal error - unimplemented function unk_lang_print_type called."));
}
diff --git a/gdb/language.h b/gdb/language.h
index 0c04208..aa0523b 100644
--- a/gdb/language.h
+++ b/gdb/language.h
@@ -198,7 +198,7 @@ struct language_defn
/* Print a type using syntax appropriate for this language. */
- void (*la_print_type) (struct type *, char *, struct ui_file *, int,
+ void (*la_print_type) (struct type *, const char *, struct ui_file *, int,
int);
/* Print a typedef using syntax appropriate for this language.
diff --git a/gdb/m2-lang.h b/gdb/m2-lang.h
index 161b4b6..87df81c 100644
--- a/gdb/m2-lang.h
+++ b/gdb/m2-lang.h
@@ -23,7 +23,7 @@ extern int m2_parse (void); /* Defined in m2-exp.y */
extern void m2_error (char *); /* Defined in m2-exp.y */
/* Defined in m2-typeprint.c */
-extern void m2_print_type (struct type *, char *, struct ui_file *, int,
+extern void m2_print_type (struct type *, const char *, struct ui_file *, int,
int);
extern void m2_print_typedef (struct type *, struct symbol *,
diff --git a/gdb/m2-typeprint.c b/gdb/m2-typeprint.c
index 70d8358..592df37 100644
--- a/gdb/m2-typeprint.c
+++ b/gdb/m2-typeprint.c
@@ -67,7 +67,7 @@ int m2_is_unbounded_array (struct type *type);
void
-m2_print_type (struct type *type, char *varstring, struct ui_file *stream,
+m2_print_type (struct type *type, const char *varstring, struct ui_file *stream,
int show, int level)
{
enum type_code code;
diff --git a/gdb/p-lang.h b/gdb/p-lang.h
index 0ea2fc9..7e076d5 100644
--- a/gdb/p-lang.h
+++ b/gdb/p-lang.h
@@ -30,7 +30,8 @@ extern int pascal_parse (void); /* Defined in p-exp.y */
extern void pascal_error (char *); /* Defined in p-exp.y */
/* Defined in p-typeprint.c */
-extern void pascal_print_type (struct type *, char *, struct ui_file *, int, int);
+extern void pascal_print_type (struct type *, const char *, struct ui_file *,
+ int, int);
extern void pascal_print_typedef (struct type *, struct symbol *,
struct ui_file *);
diff --git a/gdb/p-typeprint.c b/gdb/p-typeprint.c
index fc54e01..1792cf8 100644
--- a/gdb/p-typeprint.c
+++ b/gdb/p-typeprint.c
@@ -46,8 +46,8 @@ void pascal_type_print_varspec_prefix (struct type *, struct ui_file *, int, int
/* LEVEL is the depth to indent lines by. */
void
-pascal_print_type (struct type *type, char *varstring, struct ui_file *stream,
- int show, int level)
+pascal_print_type (struct type *type, const char *varstring,
+ struct ui_file *stream, int show, int level)
{
enum type_code code;
int demangled_args;