From bef721e278d9ba3178e679eda38ac86ef2dc0d5d Mon Sep 17 00:00:00 2001 From: Simon Marchi Date: Fri, 2 Dec 2016 17:12:37 -0500 Subject: Introduce enum_flag type for ui_out flags This patch changes the ui_out flags to be an enum flag. gdb/ChangeLog: * ui-out.h: Include "common/enum-flags.h". (enum ui_flags): Rename to ... (enum ui_out_flag): ... this. (ui_out_flags): Define enum flag type. (ui_out_test_flags): Change type of parameter to ui_out_flags. (ui_out_new): Likewise. * ui-out.c (ui_out_test_flags): Likewise. (ui_out_new): Likewise. * cli-out.c (cli_out_new): Update variable type. * mi/mi-out.c (mi_out_new): Likewise. * tui/tui-out.c (tui_out_new): Likewise. --- gdb/ui-out.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gdb/ui-out.c') diff --git a/gdb/ui-out.c b/gdb/ui-out.c index 8f745da..774be2c 100644 --- a/gdb/ui-out.c +++ b/gdb/ui-out.c @@ -702,7 +702,7 @@ ui_out_redirect (struct ui_out *uiout, struct ui_file *outstream) /* Test the flags against the mask given. */ int -ui_out_test_flags (struct ui_out *uiout, int mask) +ui_out_test_flags (struct ui_out *uiout, ui_out_flags mask) { return (uiout->flags & mask); } @@ -923,7 +923,7 @@ ui_out_query_field (struct ui_out *uiout, int colno, struct ui_out * ui_out_new (const struct ui_out_impl *impl, void *data, - int flags) + ui_out_flags flags) { struct ui_out *uiout = new ui_out (); -- cgit v1.1