Go to file
Gabriel Krisman Bertazi a9f116cbf2 Fix PR gdb/17035: "show user" doesn't list user-defined commands that
have empty bodies.

User-defined commands that have empty bodies weren't being shown because
the print function returned too soon.  Now, it prints the command's name
before checking if it has any body at all.  This also fixes the same
problem on "show user <myemptycommand>", which wasn't being printed due
to a similar reason.

gdb/Changelog:

	* cli/cli-cmds.c (show_user): Use cli_user_command_p to
	decide whether we display the command on "show user".
	* cli/cli-script.c (show_user_1): Only verify cmdlines after
	printing command name.
	* cli/cli-decode.h (cli_user_command_p): Declare new function.
	* cli/cli-decode.c (cli_user_command_p): Create helper function
	to verify whether cmd_list_element is a user-defined command.

gdb/testsuite/Changelog:

	* gdb.base/commands.exp: Add tests to verify user-defined
	commands with empty bodies.
	* gdb.python/py-cmd.exp: Test that we don't show user-defined
	python commands in `show user command`.
	* gdb.python/scm-cmd.exp: Test that we don't show user-defined
	scheme commands in `show user command`.
2014-09-07 20:12:19 -03:00
bfd daily update 2014-09-07 09:30:40 +09:30
binutils MIPS testsuite cleanup - part 1 2014-09-06 17:58:37 +01:00
config
cpu
elfcpp Make Elf_file::section_name() a const function, so that it can be used in 2014-09-02 15:44:58 -07:00
etc
gas MIPS testsuite cleanup - part 3 2014-09-06 18:00:58 +01:00
gdb Fix PR gdb/17035: "show user" doesn't list user-defined commands that 2014-09-07 20:12:19 -03:00
gold Add NaCl (NativeClient) specific classes Target_mips_nacl and 2014-09-03 09:44:11 -07:00
gprof
include [PATCH/AArch64] Implement LSE feature 2014-09-03 14:53:53 +01:00
intl
ld MIPS testsuite cleanup - part 4 2014-09-06 18:02:50 +01:00
libdecnumber
libiberty
opcodes [PATCH/AArch64] Generic support for all system registers using mrs and msr 2014-09-03 14:53:53 +01:00
readline
sim
texinfo
.cvsignore
.gitattributes
.gitignore
ChangeLog Regenerate top-level configure. 2014-09-05 12:23:31 -07:00
compile
config-ml.in
config.guess
config.rpath
config.sub
configure Regenerate top-level configure. 2014-09-05 12:23:31 -07:00
configure.ac
COPYING
COPYING3
COPYING3.LIB
COPYING.LIB
COPYING.LIBGLOSS
COPYING.NEWLIB
depcomp
djunpack.bat
install-sh
libtool.m4
lt~obsolete.m4
ltgcc.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
MAINTAINERS
Makefile.def
Makefile.in
Makefile.tpl
makefile.vms
missing
mkdep
mkinstalldirs
move-if-change
README
README-maintainer-mode
setup.com
src-release.sh
symlink-tree
ylwrap

		   README for GNU development tools

This directory contains various GNU compilers, assemblers, linkers, 
debuggers, etc., plus their support routines, definitions, and documentation.

If you are receiving this as part of a GDB release, see the file gdb/README.
If with a binutils release, see binutils/README;  if with a libg++ release,
see libg++/README, etc.  That'll give you info about this
package -- supported targets, how to use it, how to report bugs, etc.

It is now possible to automatically configure and build a variety of
tools with one command.  To build all of the tools contained herein,
run the ``configure'' script here, e.g.:

	./configure 
	make

To install them (by default in /usr/local/bin, /usr/local/lib, etc),
then do:
	make install

(If the configure script can't determine your type of computer, give it
the name as an argument, for instance ``./configure sun4''.  You can
use the script ``config.sub'' to test whether a name is recognized; if
it is, config.sub translates it to a triplet specifying CPU, vendor,
and OS.)

If you have more than one compiler on your system, it is often best to
explicitly set CC in the environment before running configure, and to
also set CC when running make.  For example (assuming sh/bash/ksh):

	CC=gcc ./configure
	make

A similar example using csh:

	setenv CC gcc
	./configure
	make

Much of the code and documentation enclosed is copyright by
the Free Software Foundation, Inc.  See the file COPYING or
COPYING.LIB in the various directories, for a description of the
GNU General Public License terms under which you can copy the files.

REPORTING BUGS: Again, see gdb/README, binutils/README, etc., for info
on where and how to report problems.