From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24882 invoked by alias); 20 Dec 2013 01:25:40 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 24873 invoked by uid 89); 20 Dec 2013 01:25:40 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-pd0-f181.google.com Received: from mail-pd0-f181.google.com (HELO mail-pd0-f181.google.com) (209.85.192.181) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Fri, 20 Dec 2013 01:25:39 +0000 Received: by mail-pd0-f181.google.com with SMTP id p10so1855704pdj.12 for ; Thu, 19 Dec 2013 17:25:37 -0800 (PST) X-Received: by 10.68.231.166 with SMTP id th6mr5195869pbc.27.1387502737326; Thu, 19 Dec 2013 17:25:37 -0800 (PST) Received: from [192.168.1.103] ([115.199.122.187]) by mx.google.com with ESMTPSA id y9sm13417719pas.10.2013.12.19.17.25.34 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 19 Dec 2013 17:25:36 -0800 (PST) Message-ID: <52B39C3D.9000805@gmail.com> Date: Fri, 20 Dec 2013 01:25:00 -0000 From: asmwarrior User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:24.0) Gecko/20100101 Thunderbird/24.0 MIME-Version: 1.0 To: Joel Brobecker CC: GDB Development Subject: Re: document issue about GDB/MI output syntax References: <52B2A623.2070009@gmail.com> <20131219180743.GJ26143@adacore.com> In-Reply-To: <20131219180743.GJ26143@adacore.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-SW-Source: 2013-12/txt/msg00068.txt.bz2 On 2013-12-20 2:07, Joel Brobecker wrote: >> Hi, I just found in this page: >> https://sourceware.org/gdb/current/onlinedocs/gdb/GDB_002fMI-Output-Syntax.html#GDB_002fMI-Output-Syntax >> The syntax is not correct: >> >> console-stream-output ==> >> "~" c-string >> target-stream-output ==> >> "@" c-string >> log-stream-output ==> >> "&" c-string >> >> It should be: >> >> console-stream-output ==> >> "~" c-string nl >> target-stream-output ==> >> "@" c-string nl >> log-stream-output ==> >> "&" c-string nl >> >> There is a "nl" missing in those stream-record, right? > > I haven't verified with actual behavior, but something doesn't > look right indeed. Here is the log I start gdb in MI under Windows E:\code\opencv\debugxb>gdb --interpreter=mi =thread-group-added,id="i1" ~"GNU gdb (GDB) 7.6.50.20131219-cvs\n" ~"Copyright (C) 2013 Free Software Foundation, Inc.\n" ~"License GPLv3+: GNU GPL version 3 or later \ nThis is free software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitted by law. Type \"show copying\"\nand \"show wa rranty\" for details.\n" ~"This GDB was configured as \"mingw32\".\nType \"show configuration\" for confi guration details." ~"\nFor bug reporting instructions, please see:\n" ~".\n" ~"Find the GDB manual and other documentation resources online at:\n.\n" ~"For help, type \"help\".\n" ~"Type \"apropos word\" to search for commands related to \"word\".\n" (gdb) You see there are "nl"s after each line of GDB's message. However, I am wondering if we shouldn't > put the "nl" at the end of each [...]-record rule. Looking > at the grammar as currently written, I think we have issues > with other records. > I think the "nl" can be put in a high level rule. E.g. out-of-band-record ==> (async-record | stream-record) "nl" I'm not sure the above grammar is in correct format, just put the "nl" in the end of out-of-band-record. Yuanhui Zhang