Fix whitespace in last change in top.c
[deliverable/binutils-gdb.git] / gdb / cli / cli-option.h
index a26b52f7f29c92fb21bd7deab49442d99a2a5034..3fd0c0cdae94c757a46fa314fdf18b806909e2e3 100644 (file)
@@ -20,8 +20,8 @@
 #ifndef CLI_OPTION_H
 #define CLI_OPTION_H 1
 
-#include "common/gdb_optional.h"
-#include "common/array-view.h"
+#include "gdbsupport/gdb_optional.h"
+#include "gdbsupport/array-view.h"
 #include "completer.h"
 #include <string>
 #include "command.h"
@@ -82,7 +82,7 @@ public:
      returns the address of some member.  */
   union
     {
-      int *(*boolean) (const option_def &, void *ctx);
+      bool *(*boolean) (const option_def &, void *ctx);
       unsigned int *(*uinteger) (const option_def &, void *ctx);
       int *(*integer) (const option_def &, void *ctx);
       const char **(*enumeration) (const option_def &, void *ctx);
@@ -155,7 +155,7 @@ template<typename Context>
 struct boolean_option_def : option_def
 {
   boolean_option_def (const char *long_option_,
-                     int *(*get_var_address_cb_) (Context *),
+                     bool *(*get_var_address_cb_) (Context *),
                      show_value_ftype *show_cmd_cb_,
                      const char *set_doc_,
                      const char *show_doc_ = nullptr,
@@ -165,7 +165,7 @@ struct boolean_option_def : option_def
                  show_cmd_cb_,
                  set_doc_, show_doc_, help_doc_)
   {
-    var_address.boolean = detail::get_var_address<int, Context>;
+    var_address.boolean = detail::get_var_address<bool, Context>;
   }
 };
 
@@ -173,11 +173,11 @@ struct boolean_option_def : option_def
    hood, but unlike boolean options, flag options don't take an on/off
    argument.  */
 
-template<typename Context = int>
+template<typename Context = bool>
 struct flag_option_def : boolean_option_def<Context>
 {
   flag_option_def (const char *long_option_,
-                    int *(*var_address_cb_) (Context *),
+                    bool *(*var_address_cb_) (Context *),
                     const char *set_doc_,
                     const char *help_doc_ = nullptr)
     : boolean_option_def<Context> (long_option_,
This page took 0.025431 seconds and 4 git commands to generate.