]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
Use emoji to indicate errors and warnings
authorTom Tromey <tromey@adacore.com>
Fri, 20 Dec 2024 21:00:39 +0000 (14:00 -0700)
committerTom Tromey <tromey@adacore.com>
Fri, 2 May 2025 18:52:09 +0000 (12:52 -0600)
commita048980c4eb93f8a965b4addc7134e8a527874a2
tree8779f44d6de2dd1c8b6107a747e608e363c50061
parent5c87b330e910f8be1443c881fd16a70e685f1f2f
Use emoji to indicate errors and warnings

This patch adds, at long last, some emoji output to gdb.  In
particular, warnings are indicated with the U+26A0 (WARNING SIGN), and
errors with U+274C (CROSS MARK).

There is a new setting to control whether emoji output can be used.
It defaults to "auto", which means emoji will be used if the host
charset is UTF-8.  Note that disabling styling will also disable
emoji, handy for traditionalists.

I've refactored mingw console output a little, so that emoji will not
be printed to the console.  Note the previous code here was a bit
strange in that it assumed that the first use of gdb_console_fputs
would be to stdout.

This version lets the user control the prefixes directly, so different
emoji can be chosen if desired.

Reviewed-By: Eli Zaretskii <eliz@gnu.org>
Reviewed-By: Keith Seitz <keiths@redhat.com>
Reviewed-By: Guinevere Larsen <guinevere@redhat.com>
gdb/NEWS
gdb/cli/cli-style.c
gdb/cli/cli-style.h
gdb/doc/gdb.texinfo
gdb/exceptions.c
gdb/main.c
gdb/main.h
gdb/mingw-hdep.c
gdb/testsuite/gdb.base/style.exp
gdb/utils.c