From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24456 invoked by alias); 22 Dec 2013 08:09:13 -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 24445 invoked by uid 89); 22 Dec 2013 08:09:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.1 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Sun, 22 Dec 2013 08:09:09 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id E293A1164CD; Sun, 22 Dec 2013 03:09:48 -0500 (EST) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 6PGvVvqekG8m; Sun, 22 Dec 2013 03:09:48 -0500 (EST) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id 77250116426; Sun, 22 Dec 2013 03:09:48 -0500 (EST) Received: by joel.gnat.com (Postfix, from userid 1000) id A6A8FE0C9B; Sun, 22 Dec 2013 12:09:03 +0400 (RET) Date: Sun, 22 Dec 2013 08:09:00 -0000 From: Joel Brobecker To: asmwarrior Cc: "gdb-patches@sourceware.org" Subject: Re: [RFC, doc] fix document error on the grammar of GDB/MI output format syntax Message-ID: <20131222080903.GA4605@adacore.com> References: <52B69693.10107@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <52B69693.10107@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-SW-Source: 2013-12/txt/msg00861.txt.bz2 > The change log could be: Fix syntax description error about GDB/MI "out-of-band-record", there should be a "new line" in end. > > Thanks. > > Yuanhui Zhang I may have given you bad advice when we discussed this on gdb@. Looking at the patch, I see you're repeating the "nl", which was what I thought we could avoid. But now that we're trying to implement the suggestion, and re-reading the grammar, it might make better logical sense to group the marker used for a given output report (Eg: "*" or "=") and the associated nl in the same rule. Concretely, this is the patch I would suggest instead (you'll notice that I removed one such "nl") to move it elsewhere. I think it's an extension of what you originally suggested? Sorry about flip-flopping on you like that... -- Joel diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo index b7551c2..f392733 100644 --- a/gdb/doc/gdb.texinfo +++ b/gdb/doc/gdb.texinfo @@ -29166,16 +29166,16 @@ corresponding output for that command will also be prefixed by that same @code{@var{exec-async-output} | @var{status-async-output} | @var{notify-async-output}} @item @var{exec-async-output} @expansion{} -@code{[ @var{token} ] "*" @var{async-output}} +@code{[ @var{token} ] "*" @var{async-output}} @var{nl} @item @var{status-async-output} @expansion{} -@code{[ @var{token} ] "+" @var{async-output}} +@code{[ @var{token} ] "+" @var{async-output}} @var{nl} @item @var{notify-async-output} @expansion{} -@code{[ @var{token} ] "=" @var{async-output}} +@code{[ @var{token} ] "=" @var{async-output}} @var{nl} @item @var{async-output} @expansion{} -@code{@var{async-class} ( "," @var{result} )* @var{nl}} +@code{@var{async-class} ( "," @var{result} )* @item @var{result-class} @expansion{} @code{"done" | "running" | "connected" | "error" | "exit"} @@ -29207,13 +29207,13 @@ depending on the needs---this is still in development). @code{@var{console-stream-output} | @var{target-stream-output} | @var{log-stream-output}} @item @var{console-stream-output} @expansion{} -@code{"~" @var{c-string}} +@code{"~" @var{c-string}} @var{nl} @item @var{target-stream-output} @expansion{} -@code{"@@" @var{c-string}} +@code{"@@" @var{c-string}} @var{nl} @item @var{log-stream-output} @expansion{} -@code{"&" @var{c-string}} +@code{"&" @var{c-string}} @var{nl} @item @var{nl} @expansion{} @code{CR | CR-LF}