From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yuan Fu Newsgroups: gmane.emacs.bugs Subject: bug#60882: 30.0.50; enabling c-ts-mode in header files Date: Thu, 19 Jan 2023 13:58:45 -0800 Message-ID: <9E28D207-7F11-4895-8C91-20B86016322F@gmail.com> References: <877cxlgrc3.fsf@web.de> Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.300.101.1.3\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13474"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 60882@debbugs.gnu.org To: felix.dick@web.de Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Jan 19 23:00:15 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 1pIcxC-0003IY-Iv for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 19 Jan 2023 23:00:14 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pIcx5-0000ub-4e; Thu, 19 Jan 2023 17:00:07 -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 1pIcx1-0000s8-9u for bug-gnu-emacs@gnu.org; Thu, 19 Jan 2023 17:00:03 -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 1pIcx0-0005v0-PU for bug-gnu-emacs@gnu.org; Thu, 19 Jan 2023 17:00:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pIcx0-0001zj-Cm for bug-gnu-emacs@gnu.org; Thu, 19 Jan 2023 17:00:02 -0500 X-Loop: help-debbugs@gnu.org In-Reply-To: <877cxlgrc3.fsf@web.de> Resent-From: Yuan Fu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 19 Jan 2023 22:00:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 60882 X-GNU-PR-Package: emacs Original-Received: via spool by 60882-submit@debbugs.gnu.org id=B60882.16741655447565 (code B ref 60882); Thu, 19 Jan 2023 22:00:02 +0000 Original-Received: (at 60882) by debbugs.gnu.org; 19 Jan 2023 21:59:04 +0000 Original-Received: from localhost ([127.0.0.1]:44908 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pIcw4-0001xx-Cb for submit@debbugs.gnu.org; Thu, 19 Jan 2023 16:59:04 -0500 Original-Received: from mail-pg1-f179.google.com ([209.85.215.179]:47011) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pIcw2-0001xR-Jh for 60882@debbugs.gnu.org; Thu, 19 Jan 2023 16:59:03 -0500 Original-Received: by mail-pg1-f179.google.com with SMTP id d10so2668928pgm.13 for <60882@debbugs.gnu.org>; Thu, 19 Jan 2023 13:59:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:cc:date:message-id:subject:mime-version :content-transfer-encoding:from:from:to:cc:subject:date:message-id :reply-to; bh=PLAX4RJFAtfn8KEM3PZavtm+xKipIMchOvsfeUKwci8=; b=TTAn+k56yiMysG2ddCK82jbMG+SxhZ4yKUB10Y7pPD6rQ6HtXay425rfc4IkGds8z3 M5y3feYPvHWJwjku504N6r3lu0mx3uEt8vQnbk5IRm4KV3HkZZZS3Jfp/9oR5heplinC 7Cc9QnttIFC3s4opWf2LpfPfLymxavFsOE/9uCAwzIcqa6zNypyD/kzC8t18aoy/acLe ipk64bSim6LNDTvWXOh5cUNu785CbPCkemRVWoJwtHxXbfbAUcHbO3+pkA5LFJKi+pAG poHj24GyS/I8GWTHJlxFcWpxCw8oXv5lAYKnHCQ1oQ/Q8rgrbvYuveEY/dUbW4mdqYmM is8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:cc:date:message-id:subject:mime-version :content-transfer-encoding:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PLAX4RJFAtfn8KEM3PZavtm+xKipIMchOvsfeUKwci8=; b=lvOOK5Gn00ri8fuBTAhk8gyRt/V3i5mCF+0wxZVKepqlceiKFoHUTzSUQo7B1Sa5Hc jRZtDBUDW3897kRsE02qW7PHJH3Ts4Ti0KSAoDJPvir+nN9JAsPbpATKNfZjILV2xwG6 2d+7H35fxbUtyvxXSWMcEMDMlfLq9tWhcpkeQiw+FV+gjktpaUyzAASzWnZKdOtxVJxx Je9/ptvwR4z6wpQEA0MRvtgr0VLXcSemD90rKgTGPYM5CvKPh7qXJ6XV87b9OeQiEi6n H4oO9mrT7Nn0xpHzqgJbLZrMqhz/4t/Cd2ZAZ+TiqZnRaZN99aZEf3z8AWmXMw3gt1Jd IQqg== X-Gm-Message-State: AFqh2kpeUPkvP/KvTe98kq7GKyquTZ8QicEzhxrLit8DYa0uBkQZPy+6 LmHeHl8AtMcXT2u+K7luQhF7RQpqtR4= X-Google-Smtp-Source: AMrXdXsAlpqZHlWm3PqDMQbgqpXTvU0xS4V6aq6kYcLVWhry4BoAAbtz8WkRhwvvoI0ETkXyqs3wyg== X-Received: by 2002:aa7:8006:0:b0:58b:cacd:2d12 with SMTP id j6-20020aa78006000000b0058bcacd2d12mr12055365pfi.28.1674165536666; Thu, 19 Jan 2023 13:58:56 -0800 (PST) Original-Received: from smtpclient.apple (cpe-172-117-161-177.socal.res.rr.com. [172.117.161.177]) by smtp.gmail.com with ESMTPSA id 129-20020a621587000000b00575d1ba0ecfsm9806528pfv.133.2023.01.19.13.58.56 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 19 Jan 2023 13:58:56 -0800 (PST) X-Mailer: Apple Mail (2.3731.300.101.1.3) 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:253735 Archived-At: Felix writes: > If i follow the steps described in Yuan's tree-sitter starter guide: > > (add-to-list 'major-mode-remap-alist > '(c-mode . c-ts-mode) > '(c++-mode . c++-ts-mode)) > > c-ts-mode is enabled if i open .c files, but for .h files it's still > c-mode. > I checked this with the -Q command line option. > Thanks You need to also remap c-or-c++-mode to c-or-c++-ts-mode, which is used for headers (because C and C++ both can use .h for header files). Yuan