2005-01-28 Andrew Cagney <cagney@gnu.org>
+ * language.h (struct language_defn): Make la_printstr's buffer
+ parameter a const bfd_byte.
+ * p-lang.h (pascal_printstr): Update function to match.
+ * ada-valprint.c (ada_printstr): Update function to match.
+ * scm-lang.c (scm_printstr): Update function to match.
+ * p-lang.c (pascal_printstr): Update function to match.
+ * ada-lang.h (ada_printstr): Update function to match.
+ * m2-lang.c (m2_printstr): Update function to match.
+ * objc-lang.c (objc_printstr): Update function to match.
+ * c-lang.h (c_printstr): Update function to match.
+ * f-lang.c (f_printstr): Update function to match.
+ * c-lang.c (c_printstr): Update function to match.
+ * language.c (unk_lang_printstr): Update function to match.
+
* valprint.c (val_print_type_code_int): Make buffer a const bfd_byte.
* valprint.h (val_print_type_code_int): Ditto.
extern void ada_printchar (int, struct ui_file *);
-extern void ada_printstr (struct ui_file *, char *, unsigned int, int, int);
+extern void ada_printstr (struct ui_file *, const bfd_byte *,
+ unsigned int, int, int);
extern void ada_convert_actuals (struct value *, int, struct value **,
CORE_ADDR *);
}
void
-ada_printstr (struct ui_file *stream, char *string, unsigned int length,
- int width, int force_ellipses)
+ada_printstr (struct ui_file *stream, const bfd_byte *string,
+ unsigned int length, int width, int force_ellipses)
{
printstr (stream, string, length, force_ellipses, width);
}
/* C language support routines for GDB, the GNU debugger.
- Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2002, 2003, 2004
- Free Software Foundation, Inc.
+
+ Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2002,
+ 2003, 2004, 2005 Free Software Foundation, Inc.
This file is part of GDB.
printing LENGTH characters, or if FORCE_ELLIPSES. */
void
-c_printstr (struct ui_file *stream, char *string, unsigned int length,
- int width, int force_ellipses)
+c_printstr (struct ui_file *stream, const bfd_byte *string,
+ unsigned int length, int width, int force_ellipses)
{
unsigned int i;
unsigned int things_printed = 0;
extern void c_printchar (int, struct ui_file *);
-extern void c_printstr (struct ui_file * stream, char *string,
+extern void c_printstr (struct ui_file * stream, const bfd_byte *string,
unsigned int length, int width,
int force_ellipses);
/* Fortran language support routines for GDB, the GNU debugger.
- Copyright 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004
- Free Software Foundation, Inc.
+
+ Copyright 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002,
+ 2003, 2004, 2005 Free Software Foundation, Inc.
+
Contributed by Motorola. Adapted from the C parser by Farooq Butt
(fmbutt@engage.sps.mot.com).
#endif
static struct type *f_create_fundamental_type (struct objfile *, int);
-static void f_printstr (struct ui_file * stream, char *string,
- unsigned int length, int width,
- int force_ellipses);
static void f_printchar (int c, struct ui_file * stream);
static void f_emit_char (int c, struct ui_file * stream, int quoter);
be replaced with a true F77 version. */
static void
-f_printstr (struct ui_file *stream, char *string, unsigned int length,
- int width, int force_ellipses)
+f_printstr (struct ui_file *stream, const bfd_byte *string,
+ unsigned int length, int width, int force_ellipses)
{
unsigned int i;
unsigned int things_printed = 0;
/* Multiple source language support for GDB.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000,
- 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+ 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
Contributed by the Department of Computer Science at the State University
of New York at Buffalo.
static void unk_lang_printchar (int c, struct ui_file *stream);
-static void unk_lang_printstr (struct ui_file * stream, char *string,
- unsigned int length, int width,
- int force_ellipses);
-
static struct type *unk_lang_create_fundamental_type (struct objfile *, int);
static void unk_lang_print_type (struct type *, char *, struct ui_file *,
}
static void
-unk_lang_printstr (struct ui_file *stream, char *string, unsigned int length,
- int width, int force_ellipses)
+unk_lang_printstr (struct ui_file *stream, const bfd_byte *string,
+ unsigned int length, int width, int force_ellipses)
{
error ("internal error - unimplemented function unk_lang_printstr called.");
}
void (*la_printchar) (int ch, struct ui_file * stream);
- void (*la_printstr) (struct ui_file * stream, char *string,
+ void (*la_printstr) (struct ui_file * stream, const bfd_byte *string,
unsigned int length, int width,
int force_ellipses);
/* Modula 2 language support routines for GDB, the GNU debugger.
- Copyright 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2002, 2003, 2004
- Free Software Foundation, Inc.
+
+ Copyright 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2002, 2003,
+ 2004, 2005 Free Software Foundation, Inc.
This file is part of GDB.
extern void _initialize_m2_language (void);
static struct type *m2_create_fundamental_type (struct objfile *, int);
-static void m2_printstr (struct ui_file * stream, char *string,
- unsigned int length, int width,
- int force_ellipses);
static void m2_printchar (int, struct ui_file *);
static void m2_emit_char (int, struct ui_file *, int);
be replaced with a true Modula version. */
static void
-m2_printstr (struct ui_file *stream, char *string, unsigned int length,
- int width, int force_ellipses)
+m2_printstr (struct ui_file *stream, const bfd_byte *string,
+ unsigned int length, int width, int force_ellipses)
{
unsigned int i;
unsigned int things_printed = 0;
/* Objective-C language support routines for GDB, the GNU debugger.
- Copyright 2002, 2003, 2004 Free Software Foundation, Inc.
+ Copyright 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
Contributed by Apple Computer, Inc.
Written by Michael Snyder.
FORCE_ELLIPSES. */
static void
-objc_printstr (struct ui_file *stream, char *string,
+objc_printstr (struct ui_file *stream, const bfd_byte *string,
unsigned int length, int width, int force_ellipses)
{
unsigned int i;
/* Pascal language support routines for GDB, the GNU debugger.
- Copyright 2000, 2002, 2003, 2004 Free Software Foundation, Inc.
+
+ Copyright 2000, 2002, 2003, 2004, 2005 Free Software Foundation,
+ Inc.
This file is part of GDB.
had to stop before printing LENGTH characters, or if FORCE_ELLIPSES. */
void
-pascal_printstr (struct ui_file *stream, char *string, unsigned int length,
- int width, int force_ellipses)
+pascal_printstr (struct ui_file *stream, const bfd_byte *string,
+ unsigned int length, int width, int force_ellipses)
{
unsigned int i;
unsigned int things_printed = 0;
extern void pascal_printchar (int, struct ui_file *);
-extern void pascal_printstr (struct ui_file *, char *, unsigned int, int, int);
+extern void pascal_printstr (struct ui_file *, const bfd_byte *,
+ unsigned int, int, int);
extern struct type *pascal_create_fundamental_type (struct objfile *, int);
/* Scheme/Guile language support routines for GDB, the GNU debugger.
- Copyright 1995, 1996, 1998, 2000, 2001, 2002, 2003, 2004 Free Software
- Foundation, Inc.
+ Copyright 1995, 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005 Free
+ Software Foundation, Inc.
This file is part of GDB.
int *, enum noside);
static struct value *scm_lookup_name (char *);
static int in_eval_c (void);
-static void scm_printstr (struct ui_file * stream, char *string,
- unsigned int length, int width,
- int force_ellipses);
struct type *builtin_type_scm;
}
static void
-scm_printstr (struct ui_file *stream, char *string, unsigned int length,
- int width, int force_ellipses)
+scm_printstr (struct ui_file *stream, const bfd_byte *string,
+ unsigned int length, int width, int force_ellipses)
{
fprintf_filtered (stream, "\"%s\"", string);
}