Patchwork [FYI,5/7] Use "false" in compile_cplus_convert_enum

login
register
mail settings
Submitter Tom Tromey
Date May 4, 2019, 8:11 p.m.
Message ID <20190504201147.3095-6-tom@tromey.com>
Download mbox | patch
Permalink /patch/32550/
State New
Headers show

Comments

Tom Tromey - May 4, 2019, 8:11 p.m.
This changes compile_cplus_convert_enum to use "false".

Note that this variable is never modified, which seems like an error.
I filed PR compile/24473 for this.

gdb/ChangeLog
2019-05-04  Tom Tromey  <tom@tromey.com>

	* compile/compile-cplus-types.c (compile_cplus_convert_enum): Use
	"false".
---
 gdb/ChangeLog                     | 5 +++++
 gdb/compile/compile-cplus-types.c | 2 +-
 2 files changed, 6 insertions(+), 1 deletion(-)

Patch

diff --git a/gdb/compile/compile-cplus-types.c b/gdb/compile/compile-cplus-types.c
index ee3bb438a3b..692393085e2 100644
--- a/gdb/compile/compile-cplus-types.c
+++ b/gdb/compile/compile-cplus-types.c
@@ -910,7 +910,7 @@  static gcc_type
 compile_cplus_convert_enum (compile_cplus_instance *instance, struct type *type,
 			    enum gcc_cp_symbol_kind nested_access)
 {
-  int scoped_enum_p = FALSE;
+  bool scoped_enum_p = false;
 
   /* Create a new scope for this type.  */
   compile_scope scope = instance->new_scope (TYPE_NAME (type), type);