Fix TUI use of "has_break" field
The TUI uses the "has_break" in two different ways: sometimes as a
boolean, and sometimes as flags.
This patch changes the TUI to be more type-safe here, and fixes the
code. I could not find a bug that this caused, so apparently this is
just cosmetic.
This deletes some code from tui_set_disassem_content. Whenver this is
called, I believe the TUI updates the breakpoint information
afterward, so this assignment is redundant; which is good because it
is also incorrect.
gdb/ChangeLog
2019-07-04 Tom Tromey <tom@tromey.com>
PR tui/24724:
* tui/tui-winsource.c (tui_clear_source_content): Update.
(tui_source_window_base::set_is_exec_point_at): Fix comment.
(tui_update_breakpoint_info): Update.
(tui_set_exec_info_content): Update.
* tui/tui-source.c (tui_set_source_content_nil): Update.
* tui/tui-disasm.c (tui_set_disassem_content): Don't set
has_break.
* tui/tui-data.h (enum tui_bp_flag): New.
(tui_bp_flags): New enum flags type.
(struct tui_source_element) <break_mode>: Change type. Rename
from has_break.
(TUI_BP_ENABLED, TUI_BP_DISABLED, TUI_BP_HIT)
(TUI_BP_CONDITIONAL, TUI_BP_HARDWARE): Don't define. Now enum
constants.
* tui/tui-winsource.h: Fix comment.