public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [commit] c-typeprint.c cleanup
@ 2010-10-13 15:10 Doug Evans
  0 siblings, 0 replies; only message in thread
From: Doug Evans @ 2010-10-13 15:10 UTC (permalink / raw)
  To: gdb-patches

Hi.

fyi, I checked this in.

2010-10-13  Doug Evans  <dje@google.com>

	* c-typeprint.c: Whitespace cleanup.
	(cp_type_print_method_args): Remove unnecessary forward decl.
	(cp_type_print_derivation_info): Ditto.
	(c_type_print_varspec_prefix): Mark as static at definition.
	(c_type_print_modifier): Fix arg descriptions.

Index: c-typeprint.c
===================================================================
RCS file: /cvs/src/src/gdb/c-typeprint.c,v
retrieving revision 1.61
diff -u -p -r1.61 c-typeprint.c
--- c-typeprint.c	11 Oct 2010 19:24:52 -0000	1.61
+++ c-typeprint.c	13 Oct 2010 15:06:25 -0000
@@ -33,16 +33,9 @@
 #include "typeprint.h"
 #include "cp-abi.h"
 #include "jv-lang.h"
-
 #include "gdb_string.h"
 #include <errno.h>
 
-static void cp_type_print_method_args (struct type *mtype, char *prefix,
-				       char *varstring, int staticp,
-				       struct ui_file *stream);
-
-static void cp_type_print_derivation_info (struct ui_file *, struct type *);
-
 static void c_type_print_varspec_prefix (struct type *, struct ui_file *, int,
 				         int, int);
 
@@ -50,9 +43,6 @@ static void c_type_print_varspec_prefix 
 static void c_type_print_modifier (struct type *, struct ui_file *,
 				   int, int);
 \f
-
-
-
 /* LEVEL is the depth to indent lines by.  */
 
 void
@@ -229,7 +219,7 @@ cp_type_print_method_args (struct type *
    between a trailing qualifier and a field, variable, or function
    name.  */
 
-void
+static void
 c_type_print_varspec_prefix (struct type *type, struct ui_file *stream,
 			     int show, int passed_a_ptr, int need_post_space)
 {
@@ -325,7 +315,8 @@ c_type_print_varspec_prefix (struct type
    and address space id if present.
    TYPE is a pointer to the type being printed out.
    STREAM is the output destination.
-   NEED_SPACE = 1 indicates an initial white space is needed */
+   NEED_PRE_SPACE = 1 indicates an initial white space is needed.
+   NEED_POST_SPACE = 1 indicates a final white space is needed.  */
 
 static void
 c_type_print_modifier (struct type *type, struct ui_file *stream,
@@ -426,11 +417,11 @@ c_type_print_args (struct type *type, st
   fprintf_filtered (stream, ")");
 }
 
-
 /* Return true iff the j'th overloading of the i'th method of TYPE
    is a type conversion operator, like `operator int () { ... }'.
    When listing a class's methods, we don't print the return type of
    such operators.  */
+
 static int
 is_type_conversion_operator (struct type *type, int i, int j)
 {
@@ -479,7 +470,6 @@ is_type_conversion_operator (struct type
   return 0;
 }
 
-
 /* Given a C++ qualified identifier QID, strip off the qualifiers,
    yielding the unqualified name.  The return value is a pointer into
    the original string.
@@ -487,6 +477,7 @@ is_type_conversion_operator (struct type
    It's a pity we don't have this information in some more structured
    form.  Even the author of this function feels that writing little
    parsers like this everywhere is stupid.  */
+
 static char *
 remove_qualifiers (char *qid)
 {
@@ -562,7 +553,6 @@ remove_qualifiers (char *qid)
     return qid;
 }
 
-
 /* Print any array sizes, function arguments or close parentheses
    needed after the variable name (to describe its type).
    Args work like c_type_print_varspec_prefix.  */

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

only message in thread, other threads:[~2010-10-13 15:10 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-10-13 15:10 [commit] c-typeprint.c cleanup Doug Evans

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).