This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[fixme] Missing "break" in switch -- intentional fall through?


This switch statement lacks any break statements, and in one case it makes a difference. I can't decide the intent, so I'd like to toss it to you Ada guys.

IMO, an intentional fall through should always have a comment.

Index: ada-lang.c
===================================================================
RCS file: /cvs/src/src/gdb/ada-lang.c,v
retrieving revision 1.285
diff -u -p -u -p -r1.285 ada-lang.c
--- ada-lang.c	17 Feb 2011 06:42:56 -0000	1.285
+++ ada-lang.c	26 Feb 2011 20:18:32 -0000
@@ -4762,6 +4762,7 @@ compare_names (const char *string1, cons
 	  else
 	    return -1;
 	}
+      /* FIXME -- fall through???  */
     default:
       if (*string2 == '(')
 	return strcmp_iw_ordered (string1, string2);

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]