Received: by 2002:a17:90a:1609:0:0:0:0 with SMTP id n9csp2278572pja; Thu, 26 Mar 2020 12:31:40 -0700 (PDT) X-Google-Smtp-Source: ADFU+vs7RqEXdWdvCx4RRNj0UrBy+mc+e+ATlvCdg5FPcJpuMpED0LOBaY38jU/y9f7B89cTIq3Z X-Received: by 2002:a4a:2a09:: with SMTP id k9mr6419677oof.64.1585251100200; Thu, 26 Mar 2020 12:31:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585251100; cv=none; d=google.com; s=arc-20160816; b=hMTwOlgqvJk5fHo/WSM9aZOlAVDX3KepPxckW+C96s+q3LzmfGiH71IngxNwG0KNlA 9wihqbtyAwD3ir7JNTqIOztT3qIQX84vRnXEoZzvFhdd8FRYDCi+mnRAS4E+jAcLBfrF MHAgrzL4AstYsS9G51mzynKZ2Dieh2ldLC0aQTLWw57jwP71RmQmSCi9nhn6tD4i1vZh KSsIrJmNkggRmKXRfAJVQwhg4CxfMThpmVZYXiOYTYkVrk1fm6clsT1OLtuQ2Uo48SMp 7WEG9r19k2KRZoqhz7eikP+h9L4SuCi6cCgmApwnonY4BYzG73d+x4WJ2sRzlZ9VEsFr JEzg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=RiybZnpQ2WaLYTPz6WPtaCIYyJYUacUfjAVruDdMh28=; b=l+Roclv2lDSGT84s3rVrTA2JgJrpnj3oeE+ZlWr2RYGFxNDP8+NnOYrS6OwiqOwa/2 +3TSzDq17Ylt9rVUKrhvyxvJ8F3xz73+DLq4CObxrPS7ze6Gk0IdwS75HeOCqARjTbda SG5Lg7mFeOljdN03zFC7LPXw8j6W21P3CrVM18fXks5ndc0u5YW2lOcWTdQxL7u8fUpd sYy6BFmI46QqjzSn8i6TAXJAEkSPOP9HSWOMvUZCpz1TdQ+NwbVVakctMs2NAkjH5+qK 8RLRKiCB4i0SW1IfrzVjKV2e2np8g0uZbGdvoxe2GeGlNcwHjOA+QMhXraE0X38bWQg6 CeuA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=WyNS53qV; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l11si1432080oop.3.2020.03.26.12.31.25; Thu, 26 Mar 2020 12:31:40 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=WyNS53qV; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727822AbgCZT3s (ORCPT + 99 others); Thu, 26 Mar 2020 15:29:48 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:33752 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726496AbgCZT3s (ORCPT ); Thu, 26 Mar 2020 15:29:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=RiybZnpQ2WaLYTPz6WPtaCIYyJYUacUfjAVruDdMh28=; b=WyNS53qVaBPLJxtnyg6zCRT8aW NAQI18Fv5s/ccyV5MYoUvVjm9fZ/8VhPGZDJDezjc+jtIBJS9D3KHB5vZ12w1IMDa/Q9izMz8Z83v 5wodJSYCjlOoMtWFOB29IdV1qxCD6qGhT1w/KRDFoAuAweulmwlo46fVxKlB7pyqRpYV2korbzWWB bPTZQn/LZm1RvvVfDidjUO2UnCuna1AmNMSdxt/R7tbEhmPRKz8/4RwC22ROwd1Zs+cj+kouAN10L pLuWABYvg9fVxcVuJCIb0UDE/zWdLLBcAR8qq+23S9RUGIe70n0euFuQuTQaQxJYeyGCjW6L5hN0c eViGdNag==; Received: from willy by bombadil.infradead.org with local (Exim 4.92.3 #3 (Red Hat Linux)) id 1jHYCJ-0004JK-Qg; Thu, 26 Mar 2020 19:29:47 +0000 Date: Thu, 26 Mar 2020 12:29:47 -0700 From: Matthew Wilcox To: peter@bikeshed.quignogs.org.uk Cc: linux-kernel@vger.kernel.org, Greg Kroah-Hartman , "Rafael J. Wysocki" , linux-doc@vger.kernel.org, Jonathan Corbet Subject: Re: [PATCH v2 1/1] A compact idiom to add code examples in kerneldoc comments. Message-ID: <20200326192947.GM22483@bombadil.infradead.org> References: <20200311133027.2c77f348@lwn.net> <20200326191628.10052-1-peter@bikeshed.quignogs.org.uk> <20200326191628.10052-2-peter@bikeshed.quignogs.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200326191628.10052-2-peter@bikeshed.quignogs.org.uk> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 26, 2020 at 07:16:28PM +0000, peter@bikeshed.quignogs.org.uk wrote: > From: Peter Lister > > scripts/kernel-doc - When a double colon follows a section heading > (e.g. Example::), write a double colon line to the ReST output to make > the following text (e.g. a code snippet) into a literal block. I think this is a good idea > - > + # $doc_sect is a regex which searches for section names. > + # If it matches: > + # $1 is the section name > + # $2 is a colon if the section name was followed by a double colon. > + # $3 the rest of the content after the colon (or double colon). I would add an extra 'is' after $3. > if (/$doc_sect/i) { # case insensitive for supported section names > $newsection = $1; > - $newcontents = $2; > - > + # If $2 is ':', the section name was followed by a double > + # colon, so insert a containing just '::' to make the Missing word between 'a' and 'containing'?