From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mickey Petersen Newsgroups: gmane.emacs.bugs Subject: bug#61043: 30.0.50; `json-ts-mode': invalid font lock rule Date: Wed, 25 Jan 2023 07:29:23 +0000 Organization: Mastering Emacs Message-ID: <87cz73vzpi.fsf@masteringemacs.org> References: <87lelrwv7f.fsf@masteringemacs.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4634"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e @VERSION@; emacs 30.0.50 Cc: 61043@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jan 25 08:31:09 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pKaFQ-00012I-Hg for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 25 Jan 2023 08:31:09 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pKaFL-0002Uy-Fx; Wed, 25 Jan 2023 02:31:03 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pKaFK-0002UW-IG for bug-gnu-emacs@gnu.org; Wed, 25 Jan 2023 02:31:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pKaFK-0000rC-9a for bug-gnu-emacs@gnu.org; Wed, 25 Jan 2023 02:31:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pKaFK-0007Pp-5C for bug-gnu-emacs@gnu.org; Wed, 25 Jan 2023 02:31:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Mickey Petersen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 25 Jan 2023 07:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61043 X-GNU-PR-Package: emacs Original-Received: via spool by 61043-submit@debbugs.gnu.org id=B61043.167463182328441 (code B ref 61043); Wed, 25 Jan 2023 07:31:02 +0000 Original-Received: (at 61043) by debbugs.gnu.org; 25 Jan 2023 07:30:23 +0000 Original-Received: from localhost ([127.0.0.1]:58140 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pKaEh-0007Of-C1 for submit@debbugs.gnu.org; Wed, 25 Jan 2023 02:30:23 -0500 Original-Received: from mail-ve1eur01on2138.outbound.protection.outlook.com ([40.107.14.138]:21566 helo=EUR01-VE1-obe.outbound.protection.outlook.com) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pKaEf-0007OP-18 for 61043@debbugs.gnu.org; Wed, 25 Jan 2023 02:30:21 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=nFRMP2bd2SelrhFv5Zw+RwIerCU+jo9llU3+XWyGOoI74+lnonQnwlIwlZJo1zJql0NfJSkv0BOo7HOxeKYH5MAv4WEMB/dlGMpVp/5pbmvWbOS4xC0MnrXZFUs7jZfvmzbXeVi0jTx1lneQM+zkwotkci+hL5pdjzq9xaZc4dDtRokhVEHdwBBU2Wmxz75M/OzbxZHOSpWjxA7RN22wIV8eYdTMtMEsgczveqgxT/h258cpiIr/Qigxjxr3gEhbK9zlsv+RBESHUSUnwPgDVopfqP9EOl0fTabrc3dgaObVWVzejoX/Kyc7SfErLSG6LPB8i9Zkt073QsL/l3hpUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=FPUUfpr6WIfZ+z0nll1oGEXwMAaPamvcPUNv5u2Hj6I=; b=mMEHZaUdKeBn2/7V3uxgUrUU2iaaq6iCf893/qc1E1hTIGeE/wySQbjlUrBuQ8xlcVEAx2DA/cCNgu2KW+p8P3FNMZNGMa/4OUzec+6gU90uUwVD++/uqfaJ1caoKV/0ZbgtBkEirTgLiW933mSz+Iwe+CHNVXgX3yvnWmeQR9/xY6B7fmgREosDThuqNuvDLATqoeE/JyTVaa2/Ju14SnEDebZyhbtAYZw0otYZr7k04g09pQrHHAAdYd4g1BFvVJlqQEHWGxoFIV1/kZvpmdWzKOQLCGz1+VJ4Ddc1voKe0br6Mm3784m8A2YZj/UE+t6cvsQXD4q/++535v5VVQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 178.79.136.144) smtp.rcpttodomain=debbugs.gnu.org smtp.mailfrom=masteringemacs.org; dmarc=pass (p=none sp=none pct=100) action=none header.from=masteringemacs.org; dkim=pass (signature was verified) header.d=masteringemacs.org; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semantical.onmicrosoft.com; s=selector1-semantical-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=FPUUfpr6WIfZ+z0nll1oGEXwMAaPamvcPUNv5u2Hj6I=; b=AEnpfOELtuzfjtT6qJmrQZ66nPyBKe4aVWy5l7W4+ZTkff2jZwZcEohMzcyhceAf6h39TC4v5dACIkqBp0Esnox8dqf3V1FL93ah8jHChPN7290gm5Jz3d6oHapJb/WEmBVGLSxPTVo63jAP4CWG+XET8hFaQWwkfoF8i7c3tZ4= Original-Received: from LO2P265CA0107.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:c::23) by CWLP265MB6548.GBRP265.PROD.OUTLOOK.COM (2603:10a6:400:1e4::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6043.21; Wed, 25 Jan 2023 07:30:07 +0000 Original-Received: from LO2GBR01FT011.eop-gbr01.prod.protection.outlook.com (2603:10a6:600:c:cafe::f1) by LO2P265CA0107.outlook.office365.com (2603:10a6:600:c::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6043.21 via Frontend Transport; Wed, 25 Jan 2023 07:30:07 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 178.79.136.144) smtp.mailfrom=masteringemacs.org; dkim=pass (signature was verified) header.d=masteringemacs.org;dmarc=pass action=none header.from=masteringemacs.org; Received-SPF: Pass (protection.outlook.com: domain of masteringemacs.org designates 178.79.136.144 as permitted sender) receiver=protection.outlook.com; client-ip=178.79.136.144; helo=semantical.co.uk; pr=C Original-Received: from semantical.co.uk (178.79.136.144) by LO2GBR01FT011.mail.protection.outlook.com (10.152.42.97) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6043.17 via Frontend Transport; Wed, 25 Jan 2023 07:30:06 +0000 Original-Received: by semantical.co.uk (Postfix, from userid 5001) id 68F5F114002; Wed, 25 Jan 2023 07:30:04 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=masteringemacs.org; s=masteringemacs.org; t=1674631804; bh=FPUUfpr6WIfZ+z0nll1oGEXwMAaPamvcPUNv5u2Hj6I=; h=References:From:To:Cc:Subject:Date:In-reply-to:From; b=pkJYLUubSp/NazvlTMWiybsfgwqxdTkQU004ahcrrRk2yh7620c4mZ93XFxLz5rW/ H3OQUiL3uwAXjZYpTP4FkrHm/xuomOOcFY1JdSG15MqCo/PrqCYUcUKYRSHnc8APPu d2X/VfjeR2dx1/i7Zoz4w5hUijpEqXbXgOIcln5o= In-reply-to: X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: LO2GBR01FT011:EE_|CWLP265MB6548:EE_ X-MS-Office365-Filtering-Correlation-Id: 8c703b8f-7f7c-4d9c-d445-08dafea5fb8d X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Clv1wd0pLfO02Ijye9RUFl6DehS+FioDE0EDHyLjFIPx7WcFwrsxkwCk/HzciF1RN8SIahzUp1ibJr6I9zKk3mEoV27b8Hz1YI6TcrveeUyRh2blWi0LXNxAeZOET8az3g2DOZwEkMpKio39UW+QijcpSH/SxF9YEja0GkthWywAzP393D86utVlhGqOP8TlUS0UB5IyIwnqDXQiTNPqjB5g2sQWWTnYUiq2tj1jRZxl6oiVLT5VP5uHJr/lq+55Jjhb8TfXSEDhriockK1ZRRGDumpmvGh6boSn2e+If48jj8eskdArE+8QlmZmp19u67g4v4o/gvR1qr5cF6+pmTJr6a3bgA/Md3TrLnQGTOaYG6EdXu2npNV4WmMWhRwDRDxAE5GHDpoF+a//Nz7JgaNNSv68DjeOxkZam+gyXF7gxDULMr8+SXAtWPWOyp5pem3db2nADiIDs6YpicksUYFMfGJaYw1yf6rUFqzvbGqSyvbcwnFQsznHHoy/K/GyC8uODyR4mJM+Slz4MoKXCYQuv53W4YeikDBDMcKxOnbil1JJSEh4lWgYuZ7LaRQyLh2JCkXRa9GlPjsnRSm7GkV/5xyGtnXhaOLoHO0Lt4qdhsymaYMKLx2MT5Y7nXMZQ85OkQkkhCF6crW8K+Ot9SkV3ERqzrO6cJfmQ0hzAayBL7+C569Gy9XvGFDJTlCnmBsaSluO7wZrDyXaBrivASQ9U2czFg4jsTcDNeDpLGISZuFiJTTvvXuHe5qVk wopkRsSGJWADLVU0Vj8GWKz9NUcW7QhxF9XH86Jk2tsvRPp28pWSf4ZaCRqKbyuTk41yQLrhn5RTPD3fdR8Tz+usg== X-Forefront-Antispam-Report: CIP:178.79.136.144; CTRY:GB; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:semantical.co.uk; PTR:semantical.co.uk; CAT:NONE; SFS:(13230025)(376002)(346002)(39830400003)(136003)(396003)(451199018)(46966006)(36840700001)(5660300002)(186003)(316002)(2906002)(70206006)(70586007)(4326008)(8936002)(6862004)(8676002)(41300700001)(36916002)(83380400001)(478600001)(966005)(336012)(6666004)(53546011)(26005)(6266002)(2616005)(82310400005)(47076005)(7596003)(7636003)(4744005)(42186006)(356005)(86362001)(36756003)(40480700001)(36860700001)(38230200001)(81973001)(23180200003)(14776008)(79816003); DIR:OUT; SFP:1102; X-OriginatorOrg: masteringemacs.org X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Jan 2023 07:30:06.7281 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 8c703b8f-7f7c-4d9c-d445-08dafea5fb8d X-MS-Exchange-CrossTenant-Id: a4e27e3d-bab0-45e8-8942-e64cf9fbd34f X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=a4e27e3d-bab0-45e8-8942-e64cf9fbd34f; Ip=[178.79.136.144]; Helo=[semantical.co.uk] X-MS-Exchange-CrossTenant-AuthSource: LO2GBR01FT011.eop-gbr01.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CWLP265MB6548 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:254103 Archived-At: Dmitry Gutov writes: > On 24/01/2023 22:09, Mickey Petersen wrote: >> There's a comment font lock rule in `json-ts-mode'. However, that is >> illegal and againt the JSON spec, and indeed the search query fails >> because `comment' is not a valid node type. > > When you say it fails, how does that look to you? > > Here's an example of a JSON file (or, more accurately, a JSON-superset > file) with comments: > https://raw.githubusercontent.com/huytd/vscode-espresso-tutti/master/themes/Espresso%20Tutti-color-theme.json > > The JSON tree-sitter grammar seems to parse them correctly as comments > ("comment" node type), and json-ts-mode highlights them as comments > correctly as a result. It may well be my JSON grammar file that is different then. Which is perhaps even worse: it is easy to find yourself with one of two versions.