From patchwork Sat Aug 16 05:56:58 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dirk Gouders X-Patchwork-Id: 4729611 Return-Path: X-Original-To: patchwork-linux-kbuild@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 6DDC0C0338 for ; Sat, 16 Aug 2014 05:59:21 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 82ADB20173 for ; Sat, 16 Aug 2014 05:59:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 92AAA2015D for ; Sat, 16 Aug 2014 05:59:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751042AbaHPF7T (ORCPT ); Sat, 16 Aug 2014 01:59:19 -0400 Received: from services.gouders.net ([141.101.32.176]:47714 "EHLO services.gouders.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750931AbaHPF7S (ORCPT ); Sat, 16 Aug 2014 01:59:18 -0400 Received: from quad.gouders.net (ip-80-226-24-6.vodafone-net.de [80.226.24.6]) (authenticated bits=0) by services.gouders.net (8.14.8/8.14.7) with ESMTP id s7G5vsuv025095 (version=TLSv1/SSLv3 cipher=AES128-SHA256 bits=128 verify=NO); Sat, 16 Aug 2014 07:58:36 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gouders.net; s=gnet; t=1408168717; bh=LBLjEgAlWM5Vae84OBdMRiwna8pSHfzSVsSOc0LjKtI=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=PpPGQ2IEYTaSvN+Hwb48xbuPXY009uGZt8oLOtMj/QQAA9zE56FC+bhBgI8Te52Cp LMKquMRSn1ZVGRG4flHLsfmbUhuwT8jPN6Ehb3eHzXjdI9ValtY6gldwdbpo5rAI8n jeJ2eiHFLDVHa07/G0nG2b+HNFgIZOgFZNmUUrKA= From: Dirk Gouders To: Michal Marek Cc: Dirk Gouders , Masatake YAMATO , linux-kbuild@vger.kernel.org, Jianyu Zhan Subject: [PATCH 3/3] scripts/tags.sh: fix DEFINE_HASHTABLE in emacs case Date: Sat, 16 Aug 2014 07:56:58 +0200 Message-Id: <1408168618-6269-4-git-send-email-dirk@gouders.net> X-Mailer: git-send-email 2.0.2 In-Reply-To: <1408168618-6269-1-git-send-email-dirk@gouders.net> References: <1408168618-6269-1-git-send-email-dirk@gouders.net> Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Spam-Status: No, score=-4.9 required=5.0 tests=BAYES_00, DKIM_ADSP_DISCARD, DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_WEB, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The emacs --regex for DEFINE_HASHTABLE produced a warning because of an unmatched '\('. Further, the whole entry did not work, because the regex needs to match from the beginning of a line, including keywords like 'static'. Finally, '\w' should not be used, because it stops at underscores which are often part of variable names in C, resulting in wrong entries in the tags file. Signed-off-by: Dirk Gouders Inspired-by: Masatake YAMATO --- scripts/tags.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/tags.sh b/scripts/tags.sh index 0f61bd7..fd651f9 100755 --- a/scripts/tags.sh +++ b/scripts/tags.sh @@ -255,7 +255,7 @@ emacs() --regex='/_PE(\([^,)]*\).*/PEVENT_ERRNO__\1/' \ --regex='/PCI_OP_READ(\([a-z]*[a-z]\).*[1-4])/pci_bus_read_config_\1/' \ --regex='/PCI_OP_WRITE(\([a-z]*[a-z]\).*[1-4])/pci_bus_write_config_\1/'\ - --regex='/DEFINE_HASHTABLE\((\w*)/\1/' + --regex='/[^#]*DEFINE_HASHTABLE(\([^,)]*\)/\1/' all_kconfigs | xargs $1 -a \ --regex='/^[ \t]*\(\(menu\)*config\)[ \t]+\([a-zA-Z0-9_]+\)/\3/'