* breakpoint.c: Include "gdb_assert.h".
(deprecated_frame_in_dummy): Assert that generic dummy frames are
not being used.
* Makefile.in (breakpoint.o): Update dependencies.
* ada-lang.c (find_printable_frame): Use get_frame_type instead of
deprecated_frame_in_dummy.
* stack.c (print_frame_info_base): Ditto.
(frame_info): Ditto.
(print_frame_info_base): Ditto. Delete dead code.
Index: tui/ChangeLog
2002-11-23 Andrew Cagney <ac131313@redhat.com>
* tuiStack.c (tuiShowFrameInfo): Use get_frame_type instead of
deprecated_frame_in_dummy. Fix coding style.
* inferior.h (registers_info, stepi_command, nexti_command,
continue_command, interrupt_target_command): Export from infcmd.c.
* frame.h (args_info, selected_frame_level_changed_hook,
return_command): Export from stack.c.
* v850ice.c (stepi_command, nexti_command, continue_command): use
prototypes from inferior.h.
* tracepoint.c (registers_info, args_info, locals_info): Use
prototypes from frame.h and inferior.h.
* Makefile.in (mi-main.o): Add dependency on frame.h.
2002-10-02 Elena Zannoni <ezannoni@redhat.com>
* mi-main.c (mi_cmd_exec_return): Don't use
return_command_wrapper, use return_command instead.
(mi_cmd_exec_interrupt): Don't use
interrupt_target_command_wrapper, use interrupt_target_command
instead.
(return_command_wrapper, interrupt_target_command_wrapper):
Delete.
Include frame.h.
2002-10-02 Elena Zannoni <ezannoni@redhat.com>
* tui-hooks.c (selected_frame_level_changed_hook): Use the one
exported from frame.h.
* tui.c (tui_show_source): Don't access current_source_symtab, use
accessor function instead. Include source.h and symtab.h
* tuiDisassem.c (tuiShowDisassemAndUpdateSource,
tuiVerticalDisassemScroll): Use accessor functions for current
source line and symtab. Include source.h.
* tuiLayout.c (_extractDisplayStartAddr): Use accessor functions
for current source line and symtab. Include source.h.
* tuiWin.c (_makeVisibleWithNewHeight): Ditto.
* tuiSourceWin.c (tuiUpdateSourceWindowAsIs,
tuiHorizontalSourceScroll): Ditto.
* tuiSource.c (tuiVerticalSourceScroll): Ditto.
(tui_initialize_readline): Allow to use space to leave SingleKey
to enter one gdb command.
(tui_enable): Restore the TUI keymap when we are back to TUI.
(tui_disable): Restore normal keymap when leaving TUI.
* tuiIO.c (tui_redisplay_readline): Restore the SingleKey mode
when the buffer becomes empty and we are in tui_one_command_mode.
(tui_command_loop): New function to override gdb loop and make sure
uiout is set according to TUI mode.
(tui_command_loop): Install the specific TUI command hook.
* tuiIO.c (tui_initialize_io): Initialize tui_old_uiout.
(tui_uiout, tui_old_uiout): Make public.
* tuiIO.h (tui_uiout, tui_old_uiout): Declare.
(printable_part): New function from readline/complete.c.
(PUTX): New macro, likewise.
(print_filename): New function, likewise.
(get_y_or_n): New function, likewise and adapted for TUI.
(tui_rl_display_match_list): New function from readline/complete.c
and writes on TUI command window.
(tui_setup_io): Install or remove the readline hook
rl_completion_display_matches_hook so that completion is written
directly in TUI command window instead of in the TUI pipe.
(tui_initialize_io): Use #ifdef TUI_USE_PIPE_FOR_READLINE for the
TUI redirection pipe.
(tui_getc): Likewise for call to tui_readline_output.
(tui_readline_output): Likewise for function.
* tui.c (tui_rl_startup_hook): Always take care of gdb prompt.
status line.
(tuiShowLocatorContent): Use it instead of displayableWinContentAt.
* tuiData.h (PROC_PREFIX): Use "In:" to reduce length of prefix.
(PC_PREFIX): Use upper case.
(SINGLE_KEY, MIN_LINE_WIDTH, MIN_PROC_WIDTH): Define.
(MAX_TARGET_WIDTH, MAX_PID_WIDTH): Define.
* tui.c (tui_commands): Table of single key commands.
(tui_rl_command_key): New function to execute gdb command.
(tui_rl_command_mode): New function to temporarily leave SingleKey.
(tui_rl_next_keymap): New function to enter/leave the SingleKey mode.
(tui_rl_startup_hook): New function to avoid prompt display by
readline functions.
(tui_set_key_mode): New function to set the key mode and install
the readline keymap.
(tui_initialize_readline): Create TUI SingleKey readline map.
(tui_enable): Install rl_startup_hook.
(tui_disable): Remove it.
* tui.h (enum tui_key_mode): Declare.
(tui_set_key_mode, tui_current_key_mode): Declare.
* tuiIO.c (tui_redisplay_readline): Don't display the prompt in
SingleKey mode.
* tuiIO.h (tui_redisplay_readline): Declare.
(tui_update_breakpoint_info): Declare.
(tuiSetHasBreakAt, tuiAllSetHasBreakAt): Remove.
* tuiSourceWin.c (tuiUpdateSourceWindowAsIs): Update breakpoint
information using tui_update_breakpoint_info.
(tui_update_all_breakpoint_info): New function to refresh all
execution windows.
(tui_update_breakpoint_info): New function to recompute the status
of exec info window from breakpoints.
(tuiSetHasBreakAt, tuiAllSetHasBreakAt): Remove.
(tuiSetExecInfoContent): Use the exec info flags computed by
tui_update_breakpoint_info to display a short status about breakpoints.
* tuiData.h (TuiExecInfoContent): New for exec info string.
(TuiWhichElement): Use it.
(TUI_BP_ENABLED, TUI_BP_DISABLED, TUI_BP_HIT): New defines.
(TUI_BP_CONDITIONAL, TUI_BP_HARDWARE): New defines.
(TUI_BP_HIT_POS, TUI_BP_BREAK_POS, TUI_EXEC_POS): Likewise.
(TUI_EXECINFO_SIZE): Likewise.
* tuiData.c (initContentElement): Clear exec info string.
* tui-hooks.c (get_breakpoint): Remove.
(tui_event_create_breakpoint): Call tui_update_all_breakpoint_info.
(tui_event_delete_breakpoint): Likewise.
(tui_event_modify_breakpoint): Likewise.
several lines in a buffer.
(tui_find_disassembly_address): New function to search backward
or forward a disassembly line.
(tuiSetDisassemContent): Use tui_disassemble to obtain the real
content and format it in the window.
(tuiShowDisassemAndUpdateSource): Remove unused locals.
(tuiVerticalDisassemScroll): Use tui_find_disassembly_address to
obtain the address to disassemble for the scrolling.
* tuiDisassem.h (tuiGetBeginAsmAddress): Update.
* tuiSourceWin.c (tuiUpdateSourceWindowAsIs): Don't pass symtab.
(tuiUpdateLocatorInfoFromFrame): Remove.
(tui_set_locator_info): Allocate the content buffer if necessary.
(tui_set_locator_filename): Call tui_set_locator_info directly.
(tuiShowFrameInfo): Likewise and use find_pc_line instead of
find_pc_symtab.
tuiUpdateLocatorFilename.
* tuiStack.c (tuiSetLocatorInfo): Make it static.
(tuiSetLocatorContent): Likewise.
(tuiUpdateLocatorInfoFromFrame): Likewise.
(tuiSwitchFilename): Remove.
(tui_set_locator_filename): New function
(tui_set_locator_info): Rename from tuiSetLocatorInfo to GNU-ify;
use tui_set_locator_filename to record the filename.
(tuiUpdateLocatorFilename): Likewise.
(tuiUpdateLocatorInfoFromFrame): Update.
(tuiSetLocatorContent): Likewise.
* tuiStack.h (tuiClearLocatorContent): Don't declare.
(tuiSetLocatorInfo, tuiSetLocatorContent): Likewise.
(tuiUpdateLocatorInfoFromFrame, tuiSwitchFilename): Likewise.
* tuiStack.c (tuiClearLocatorDisplay): Remove.
(tuiShowLocatorContent): Use wclrtoeol to clear end of status line.
(tuiUpdateLocatorDisplay): Don't call tuiClearLocatorDisplay.
is the size of command window.
(tuiResizeAll): Call it instead of init_page_info.
* tui.c (tui_enable): Call it to resize to TUI command window.
(tui_disable): Likewise for plain screen.
`enable' and `disable' identifiers, because some platforms define
in their system headers symbols with global scope that go by those
names.
* breakpoint.h (enum enable_state): Rename from `enum enable'.
Also rename all the enum members to have the "bp_" prefix.
(struct breakpoint): Rename the `enable' member to `enable_state'.
(enum bpdisp): Rename all members to have the "disp_" prefix.
* breakpoint.c: All users of `enum enable' and `enum bpdisp'
changed.
(args_for_catchpoint_enable): Rename the `enable' member to
`enable_p'. All users changed.
* tracepoint.h (enum enable): Remove.
(struct tracepoint): The member `enabled' is now `int enabled_p'.
* tracepoint.c: All users of the `enabled' member changed.
* printcmd.c (struct display): The `status' member is now an int.
* memattr.h (struct mem_region): Rename the `status' member to
`enabled_p'.
(enum enable): Remove.
* memattr.c: Change all users of the `status' member of struct
mem_region to use `enabled_p' instead.
* infcmd.c (run_stack_dummy): Use disp_del instead of del.
* go32-nat.c: Remove the kludgey work-around for conflicts between
<dos.h> and "breakpoint.h".
* tui/tuiSourceWin.c: Use disp_del instead of del.
* tui/tuiSource.c: Use disp_del instead of del.
* tui/tuiDisassem.c: Use disp_del instead of del.
* tui-out.c: New file, image copied from cli-out.c.
(tui_field_int): Identify "line" fields and keep track of them.
(tui_field_string): Likewise for "file".
(tui_out_new): Use flags = 0 to avoid printing the sources.
leave it in the command window.
(tui_redisplay_readline): Save cursor position to restore the
cursor after we go back from background.
* tuiData.h (TuiCommandInfo): Add start_line member.
* tuiStack.h (tuiUpdateLocatorFilename): Update prototype.
* tuiWin.c (_initialize_tuiWin): Don't cast table of enum in calls
to add_set_enum_cmd.
* tui.c (tui_show_source): New function.
(tuiGetLowDisassemblyAddress): Use CORE_ADDR for newLow.
(tui_switch_mode): Prep or deprep readline terminal;
make sure the \n we return does not redo the last command.
* tui.h (tui_show_source): Declare.
(tui_out_new, tui_install_hooks, tui_remove_hooks): Likewise.
(tui_active, tui_initialize_io, tui_initialize_readline): Likewise.
(tui_is_window_visible): Declare.
* tui.c (tui_show_assembly): New function.
(tui_is_window_visible): New function.
(tui_get_command_dimension): New function.
(tui_delete_other_windows): New function.
(tui_initialize_readline): Bind them to C-X 1 and C-X 2.
(tui_enable): Enable the keypad; call tui_update_variables.
(strcat_to_buf_with_fmt): Remove.
* tui.c (tui_switch_mode): New function.
(tui_initialize_readline): New function.
(tui_enable): New function.
(tui_disable): New function.
(tuiGetLowDisassemblyAddress): Use CORE_ADDR, cleanup.
(tui_vSelectSourceSymtab): Remove.
(tuiInitWindows): Remove.
(_initialize_tui): Remove.
(_tuiReset): Keep but put arround #if 0.
* tuiIO.c: New management for curses and gdb terminal interactions.
(tui_tputs): Remove.
(tuiTermSetup, tuiTermUnsetup): Remove, must use normal curses ops.
(tuiBufferGetc, tui_vStartNewLines, _updateCommandInfo): Remove.
(tui_owns_terminal): Remove.
(tui_redisplay_readline): New function.
(tui_puts): New function.
(tui_prep_terminal): New function.
(tui_deprep_terminal): New function.
(tui_getc): Rename of tuiGetc, simplify and fix.
(tui_setup_io): New function.
(tui_initialize_io): New function.
* tuiWin.h: Declare the new variables.
* tuiWin.c (_initialize_tuiWin): Create TUI configuration variables.
(tui_update_variables): New function.
(translate): New function.
(tui_border_kind_enums, tui_border_mode_enums): New tables.
(tui_border_mode_translate): New table.
(tui_border_kind_translate_*): New tables.
(tui_active_border_mode): New variables.
(tui_border_*): New variables.
each register window.
(tuiCheckRegisterValues): Use REGISTER_RAW_SIZE to obtain the size
of the register to check.
(_tuiRegValueHasChanged): Likewise.
(_tuiRegisterName): Use REGISTER_NAME.
(tui_restore_gdbout): New function.
(_tuiRegisterFormat): Use do_registers_info with gdb_stdout redirected
to a string.
(START_SPECIAL_REGS): Define.
(_tuiGetRegisterRawValue): Use get_saved_register.
(_tuiDisplayRegister): Fix clearing of register window.
(tuiShowFrameInfo): Don't crash when there is no symbol table
associated with the pc.
* tuiSource.c (_hasBreak): Check for null source file.
* tuiWin.c (tuiRefreshAll): Check for null winList[type].
(_tuiSetFocus): Check for null dataWin.
* tuiGeneralWin.c (refreshAll): Check for null list[type].
(TuiGenWinInfo, TuiGenWinInfoPtr): Move from here.
* tuiData.h: To here; include curses includes here.
(setTermHeightTo): Rename of setTermHeight to follow reality.
(setTermWidthTo): Likewise with setTermWidth.
* gdb/config/i386/windows.mh,
gdb/doc/GDBvn.texi, gdb/doc/remote.texi,
gdb/testsuite/gdb.base/README, gdb/testsuite/gdb.base/crossload.exp,
gdb/testsuite/gdb.base/i486-elf.u, gdb/testsuite/gdb.base/i860-elf.u,
gdb/testsuite/gdb.base/m68k-aout.u,
gdb/testsuite/gdb.base/m68k-aout2.u,
gdb/testsuite/gdb.base/m68k-elf.u, gdb/testsuite/gdb.base/mips-ecoff.u,
gdb/testsuite/gdb.base/sparc-aout.u,
gdb/testsuite/gdb.base/sparc-elf.u,
gdb/tui/Makefile,
readline/ChangeLog: These files have been removed over the course
of the last year, but weren't cvs removed from the old GDB repository
on sourceware.
* tui.h: Include stdarg.h instead of varargs.h if we're on an ISO Cish
system.
Without this you'll get a build failure in gdbtk.c because it includes
stdarg.h but tui.h includes varargs.h; gdbtk.c tries to use va_start
and things die.