Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp1971714imm; Mon, 3 Sep 2018 14:39:31 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZZaKF5OonkMkoqR38cYc9W2aumV84wJzrd/6YknmBKInEYclNsGpQM6P/9BKwNxgNxwh8I X-Received: by 2002:a63:a053:: with SMTP id u19-v6mr28130702pgn.394.1536010771803; Mon, 03 Sep 2018 14:39:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536010771; cv=none; d=google.com; s=arc-20160816; b=TCZt2elq3i6MbvI8dtlXdeO0iagaDyJiXlTB5EpPqOv0VQJobKXoR5Ub6c66eVML6d zCiFbeHeWCMqkaD8LBNuevZF+PIBDDKkFxIduBuuRoYtScClj60vrbbV0qTVJycpInYm 3h4KeQEa8p5cGChQm7idgRzWXbeI/2DNUVZIV+EKLNjQg/y/jbz2H9GuY0rdktuQmcAx oG8O0r0j0auQT6Z8toLQbuYCIMtZspHHjX6GYgUB2xxdi+wEIQDmH0gByQN8wTRVLWZA 5RuuvohLVZ5Tl6lHOBiV9LjEweXrRomruW1krpTiFWZlkptjKELvCziO4S/hh3l1JmeH rwWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:arc-authentication-results; bh=j6kejSQyrxC4VjyBT63AHevibPWt9Z5PzpH+C8V8UA0=; b=0X8aNHgTBzXmrZoMx0D1MQRDW+P8VkrbxGD3QAZYl6pfhyNVtzGnTNzkwxPP2WqAnI VrL0kqsBWHyGr6bMhKxZRn6KbRtbLFMjrwAMwTRTOAGX58EWGPNVFV9PDjEISVjN9ckU MbRyyw//uv2xGN/wlzNsV64FJDArcSfovncWDN2eLsQTc5O4BpKrKC/EO6STr1XQO/pp uQmsH2SKEi2de2q5nnKNdnB89XSYh57QHrKUTPNj/DdNUbWY2h+aP9nWLtR8v9V6bqGk TXFrqA3oDchEqyGk03agGLYAQ6M4JkBLdMsgG3REWBhSBE4FiOBDZiGDzb0SuAZzvO4N FlPw== ARC-Authentication-Results: i=1; mx.google.com; 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 m7-v6si18362323plt.7.2018.09.03.14.39.16; Mon, 03 Sep 2018 14:39:31 -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; 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 S1727351AbeIDCAK (ORCPT + 99 others); Mon, 3 Sep 2018 22:00:10 -0400 Received: from ms.lwn.net ([45.79.88.28]:50394 "EHLO ms.lwn.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726135AbeIDCAJ (ORCPT ); Mon, 3 Sep 2018 22:00:09 -0400 Received: from lwn.net (localhost [127.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ms.lwn.net (Postfix) with ESMTPSA id C276D72A; Mon, 3 Sep 2018 21:38:05 +0000 (UTC) Date: Mon, 3 Sep 2018 15:38:04 -0600 From: Jonathan Corbet To: Heinrich Schuchardt Cc: linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/1] docs: kernel-doc: fix parsing of function pointers Message-ID: <20180903153804.2b091448@lwn.net> In-Reply-To: References: <20180903184153.9368-1-xypron.glpk@gmx.de> <20180903130043.059b2e82@lwn.net> Organization: LWN.net MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 3 Sep 2018 22:29:00 +0200 Heinrich Schuchardt wrote: > >> # pointer-to-function > >> $arg =~ tr/#/,/; > >> - $arg =~ m/[^\(]+\(\*?\s*([\w\.]*)\s*\)/; > > m/[^\(]+\(\*?\s*([\w\.]*)\s*\)/; > ^ > Here we allow for 0..1 asterixes. > > If there is no asterix it is not a function pointer. Why should we care > for this case? GCC seems to allow that asterisk (asterix is an indomitable Gaul :) to be missing; not sure if that's officially allowed by the language or not. I also don't know if any code in the kernel elides it, but *somebody* at some point made it optional, presumably with some reason. It would be instructive to take out that "?" and see what changes happen in a docs build; I'll try to find a moment to do that. jon