From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16625 invoked by alias); 18 Feb 2014 14:14:17 -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 16615 invoked by uid 89); 18 Feb 2014 14:14:16 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00,SPF_PASS autolearn=ham version=3.3.2 X-HELO: usevmg21.ericsson.net Received: from usevmg21.ericsson.net (HELO usevmg21.ericsson.net) (198.24.6.65) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Tue, 18 Feb 2014 14:14:13 +0000 Received: from EUSAAHC002.ericsson.se (Unknown_Domain [147.117.188.78]) by usevmg21.ericsson.net (Symantec Mail Security) with SMTP id 41.53.11484.4BA63035; Tue, 18 Feb 2014 15:14:12 +0100 (CET) Received: from [142.133.110.254] (147.117.188.8) by smtps-am.internal.ericsson.com (147.117.188.78) with Microsoft SMTP Server (TLS) id 14.2.347.0; Tue, 18 Feb 2014 09:14:08 -0500 Message-ID: <53036AC9.5080604@ericsson.com> Date: Tue, 18 Feb 2014 14:14:00 -0000 From: Simon Marchi User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: Subject: Re: [PATCH] Doxygenate defs.h References: <530285BC.90102@earthlink.net> <201402172217.s1HMHOAT001833@glazunov.sibelius.xs4all.nl> <8738jg4pj1.fsf@oracle.com> In-Reply-To: <8738jg4pj1.fsf@oracle.com> Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2014-02/txt/msg00565.txt.bz2 On 14-02-18 06:40 AM, Jose E. Marchesi wrote: > > > This is a first patch that modifies source code to be more useful with > > Doxygen. It does little more than add an extra "*" to comment blocks > > that document the source construct immediately following. > > > > In keeping with our usual practice, I have not changed anything outside > > comments, and the comments themselves are only minimally tweaked, > > despite the great temptation to expand on some of the more cryptic. :-) > > > > I'll push this in a couple days if people are willing to live with this > > format for comments. Next up, minsyms.h. > > Sorry, no, I'm not willing to live with this. It's making the > comments significantly harder to read. And what benefit does the > documentation have over just reading the header file? There really is > only one thing that the old internals documentation tried to provide > that the comments in the source code aren't very good at: explaining > how the interfaces work together. And that's not something Doxygen is > going to provide. > > I am of the same opinion. Usually only managers ever "use" > Doxygen-generated "documentation" of C programs, and mostly only because > it is required as a deliverable by contractual reasons. > > Most developers will just open the header files and read them, using > some indexing tool (ctags, CEDET/Emacs, whatever Eclipse uses..) for > jumping through references. IMO polluting the comments like this, > restating the obvious with marks like @param, will only make them more > difficult to read with no practical benefit: what gdb hacker will ever > fire up a Firefox or similar to find out what the parameters to some > function are? > > If the decision to use Doxygen has been already taken, would it be > possible to at least avoid these @param marks? > I agree that the @param adds some weight to the code, but it doesn't really bother me. What I like of it is that it adds some form of standardization, both for the form and the content. Currently, function headers (when they exist) are usually one paragraph that sometimes describe some of the arguments. This format makes sure you have at least one statement describing the function and then one line per argument. If the structure of the comments is always the same, it might actually be easier to read, even though it's more text. Simon ///////////////////////////////////////////////// /// at least we're not using comments like this... oh god why. /////////////////////////////////////////////////