public inbox for gdb-cvs@sourceware.org
help / color / mirror / Atom feed
* [binutils-gdb] Remove c_emit_char
@ 2022-10-10 17:38 Tom Tromey
  0 siblings, 0 replies; only message in thread
From: Tom Tromey @ 2022-10-10 17:38 UTC (permalink / raw)
  To: gdb-cvs

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=c1c7fe59f67f5f4e3ca6f6fea1de46b983be8995

commit c1c7fe59f67f5f4e3ca6f6fea1de46b983be8995
Author: Tom Tromey <tom@tromey.com>
Date:   Fri Feb 11 18:10:00 2022 -0700

    Remove c_emit_char
    
    This renames c_emit_char, removing a layer of indirection.

Diff:
---
 gdb/c-lang.c   | 4 ++--
 gdb/c-lang.h   | 3 ---
 gdb/language.c | 9 ---------
 3 files changed, 2 insertions(+), 14 deletions(-)

diff --git a/gdb/c-lang.c b/gdb/c-lang.c
index 88ccc8aaf41..d6c56f31616 100644
--- a/gdb/c-lang.c
+++ b/gdb/c-lang.c
@@ -144,8 +144,8 @@ classify_type (struct type *elttype, struct gdbarch *gdbarch,
    for printing characters and strings is language specific.  */
 
 void
-c_emit_char (int c, struct type *type,
-	     struct ui_file *stream, int quoter)
+language_defn::emitchar (int c, struct type *type,
+			 struct ui_file *stream, int quoter) const
 {
   const char *encoding;
 
diff --git a/gdb/c-lang.h b/gdb/c-lang.h
index 096eb027fd7..b26996c20b1 100644
--- a/gdb/c-lang.h
+++ b/gdb/c-lang.h
@@ -104,9 +104,6 @@ extern void c_printstr (struct ui_file * stream,
 extern void c_language_arch_info (struct gdbarch *gdbarch,
 				  struct language_arch_info *lai);
 
-extern void c_emit_char (int c, struct type *type,
-			 struct ui_file *stream, int quoter);
-
 /* These are in c-typeprint.c: */
 
 extern void c_type_print_base (struct type *, struct ui_file *,
diff --git a/gdb/language.c b/gdb/language.c
index d3cc14c3079..114ee3aedd9 100644
--- a/gdb/language.c
+++ b/gdb/language.c
@@ -635,15 +635,6 @@ language_defn::value_print_inner
 
 /* See language.h.  */
 
-void
-language_defn::emitchar (int ch, struct type *chtype,
-			 struct ui_file * stream, int quoter) const
-{
-  c_emit_char (ch, chtype, stream, quoter);
-}
-
-/* See language.h.  */
-
 void
 language_defn::printstr (struct ui_file *stream, struct type *elttype,
 			 const gdb_byte *string, unsigned int length,

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-10-10 17:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-10 17:38 [binutils-gdb] Remove c_emit_char Tom Tromey

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).