From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 119646 invoked by alias); 31 Dec 2019 18:13:12 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 118699 invoked by uid 89); 31 Dec 2019 18:13:12 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-5.5 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.1 spammy=ensures X-HELO: simark.ca Received: from simark.ca (HELO simark.ca) (158.69.221.121) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 31 Dec 2019 18:13:11 +0000 Received: from [10.0.0.11] (unknown [192.222.164.54]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by simark.ca (Postfix) with ESMTPSA id EC9951E50B; Tue, 31 Dec 2019 13:13:08 -0500 (EST) Subject: Re: [RFA] Ensure GDB warnings are styled. To: Philippe Waroquiers , gdb-patches@sourceware.org References: <20191215171056.4842-1-philippe.waroquiers@skynet.be> From: Simon Marchi Message-ID: <5d79be1d-8994-0a19-7ff6-68110f67f27b@simark.ca> Date: Tue, 31 Dec 2019 18:13:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.3.0 MIME-Version: 1.0 In-Reply-To: <20191215171056.4842-1-philippe.waroquiers@skynet.be> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-SW-Source: 2019-12/txt/msg01087.txt.bz2 On 2019-12-15 12:10 p.m., Philippe Waroquiers wrote: > While handling the comments of Tom related to > [RFC] Have an option to tell GDB to detect and possibly handle mismatched exec-files. > https://sourceware.org/ml/gdb-patches/2019-12/msg00621.html > I saw that GDB warnings are produced ignoring the given styles. > > This patch: > * ensures that style markups are properly handled by "warning". > * changes 'set/show data-directory' so that file style is used > in warnings and in 'show message' > * changes all other messages in top.c to use file style when appropriate. > * Uses the above data-directory changes in gdb.base/style.exp > > 2019-12-15 Philippe Waroquiers > > * ui-file.c (stdio_file::can_emit_style_escape) > (tee_file::can_emit_style_escape): Ensure style is used also on > gdb_stderr when gdb_stderr is a tty supporting styling, similarly > to gdb_stdout. > * main.c (set_gdb_data_directory): Use file style to output the > warning that the given pathname is not a directory. > * top.c (show_history_filename, gdb_safe_append_history) > (show_gdb_datadir): Use file style. > > 2019-12-15 Philippe Waroquiers > > * gdb.base/style.exp: Test that warnings are styled. Thanks, that LGTM. Simon