Remove "typedef enum ..."

I noticed a few spots in GDB that use "typedef enum".  However, in C++
this isn't as useful, as the tag is automatically entered as a
typedef.  This patch removes most uses of "typedef enum" -- the
exceptions being in some nat-* code I can't compile, and
glibc_thread_db.h, which I think is more or less a copy of some C code
from elsewhere.

Tested by rebuilding.
This commit is contained in:
Tom Tromey
2022-04-27 14:32:49 -06:00
parent c42dd30d73
commit 0d1703b8fb
14 changed files with 35 additions and 38 deletions

View File

@ -129,12 +129,12 @@ struct pending_stop
DEBUG_EVENT event;
};
typedef enum
enum handle_exception_result
{
HANDLE_EXCEPTION_UNHANDLED = 0,
HANDLE_EXCEPTION_HANDLED,
HANDLE_EXCEPTION_IGNORED
} handle_exception_result;
};
/* A single Windows process. An object of this type (or subclass) is
created by the client. Some methods must be provided by the client

View File

@ -206,7 +206,7 @@ x86_get_debug_register_length ()
#define X86_DR_WATCH_HIT(dr6, i) ((dr6) & (1 << (i)))
/* Types of operations supported by x86_handle_nonaligned_watchpoint. */
typedef enum { WP_INSERT, WP_REMOVE, WP_COUNT } x86_wp_op_t;
enum x86_wp_op_t { WP_INSERT, WP_REMOVE, WP_COUNT };
/* Print the values of the mirrored debug registers. */