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.devel Subject: Re: emacs-30 3fcec09f754 2/4: Add debugging function for treesit.c Date: Sun, 8 Sep 2024 21:13:00 -0700 Message-ID: <380D055D-88C3-4C9E-8926-1E4C11C20430@gmail.com> References: <172585397252.25544.14799687468267584593@vcs2.savannah.gnu.org> <20240909035253.23A45C41F2E@vcs2.savannah.gnu.org> Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3776.700.51\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29071"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Po Lu Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Sep 09 06:29:08 2024 Return-path: Envelope-to: ged-emacs-devel@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 1snW1T-0007NC-59 for ged-emacs-devel@m.gmane-mx.org; Mon, 09 Sep 2024 06:29:07 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1snW0Y-0006lg-G7; Mon, 09 Sep 2024 00:28:10 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1snVqy-0005wz-1l for emacs-devel@gnu.org; Mon, 09 Sep 2024 00:20:51 -0400 Original-Received: from mail-oa1-x31.google.com ([2001:4860:4864:20::31]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1snVm6-0005L4-BN for emacs-devel@gnu.org; Mon, 09 Sep 2024 00:13:15 -0400 Original-Received: by mail-oa1-x31.google.com with SMTP id 586e51a60fabf-277c861d9f6so2352428fac.2 for ; Sun, 08 Sep 2024 21:13:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1725855192; x=1726459992; darn=gnu.org; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=YPZk3QPgYIUoZ4o54HT0yezg5Tcdz5YKzZqvD5c9iAo=; b=LgJAwA3A31u+rFYSZJjOURIXGxbhZUtg4wi9c/jmK+hFmqrtPUF3QftGRfIMi0gEtE Cl+TG1Hvm556EbGgqqV//lSGxv0FU1k1vLLHG1Ejl9z/InndTp+OsKJJUdsH1TizK8Cu YjAOgf7eUtxfq5S1xKhf2OsM7U6stWmQikaHjJmCO755sefRCpYGDHxzvF244soS9lOp R+1DD7eFDxoiH1BA+O7MwMlGiTpYnwDeRyDASn7uxdEduPophYWvtl3EK8ggCkrsXtph vTJIRl9Y6UeZPbefK/nqCEX3Gf6WSuOyy22JE8H/UKMXwu90cZPWbGDcxWUcSg6gm4c4 V7iA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725855192; x=1726459992; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=YPZk3QPgYIUoZ4o54HT0yezg5Tcdz5YKzZqvD5c9iAo=; b=Fb2+WqNQetyDHUNYptLdQZTgUWfjr2eaEUi63nzeo31VwvKNaPLTKWtmO/roNbEJJ0 jvt4qAL/vHpXFoO/GeHtA3p5VxGPb+0/H3CA2iKJjsgjFP+CeqjNWCHN3DS8ERjMuInt Yx86nOIOoVqvmG0uP6p4r0DTah2qGwZTt6sJuuFkt19sbwmeRgAPx4WdB3mf3BqCzio8 BCe8ke9VWfzAoRKxWsetgEZ5atOATd4Ynavizm5GP9kr7RDVM2x/zoonEMiZPp71aJCA gYxNsBwiqX91mGL4YUzqF4N7wCC35JHD9ESbtaHrrTu3JScLzgnoLJsFmlDlLRAinjTK sZ+g== X-Gm-Message-State: AOJu0YwUDn80PhCqLWAKBKa1SW1mwehU8RVWy6xcsevTBKL441CdHruM oeegapogsN9vfImsJrmXyHEXHwPKMYw64TNtQsBEYbQsFzmyk/Yt X-Google-Smtp-Source: AGHT+IGvu7e4JJO5zIxnlajCTM6whvsgfl8l24GEFiucIIm12w+xJdOiBmYrc4YMMtOQE5aSborL9g== X-Received: by 2002:a05:6870:d108:b0:270:1eca:e9fd with SMTP id 586e51a60fabf-27b82dd86e0mr12402376fac.3.1725855192365; Sun, 08 Sep 2024 21:13:12 -0700 (PDT) Original-Received: from smtpclient.apple ([2601:646:8f81:6120:9947:7537:5948:e5a0]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-718e59688a4sm2670998b3a.133.2024.09.08.21.13.11 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 08 Sep 2024 21:13:11 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.3776.700.51) Received-SPF: pass client-ip=2001:4860:4864:20::31; envelope-from=casouri@gmail.com; helo=mail-oa1-x31.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:323509 Archived-At: > On Sep 8, 2024, at 8:58=E2=80=AFPM, Po Lu wrote: >=20 > Yuan Fu writes: >=20 >> branch: emacs-30 >> commit 3fcec09f754af9822339eff3ea15d43eb7d19014 >> Author: Yuan Fu >> Commit: Yuan Fu >>=20 >> Add debugging function for treesit.c >>=20 >> * src/treesit.c (treesit_debug_print_parser_list): New function. >> --- >> src/treesit.c | 47 +++++++++++++++++++++++++++++++++++++++++++++++ >> 1 file changed, 47 insertions(+) >>=20 >> diff --git a/src/treesit.c b/src/treesit.c >> index 6e806039df0..351bd65819a 100644 >> --- a/src/treesit.c >> +++ b/src/treesit.c >> @@ -485,6 +485,53 @@ treesit_initialize (void) >> } >>=20 >>=20 >> +/*** Debugging */ >> + >> +void treesit_debug_print_parser_list (char *msg, Lisp_Object parser) >=20 > Please insert a newline between the return type and identifier name. > Is this appropriate for Emacs 30? Will do. This is for debugging a hang on emacs 30 (which I still = haven=E2=80=99t figure out yet) (bug#72863). If it=E2=80=99s not = appropriate for emacs-30, I can revert it and later put it on master. A = debugging function won=E2=80=99t be called by any function so it = shouldn=E2=80=99t disrupt anything. I=E2=80=99m only locally inserting = calls to this function in various places for debugging. Yuan=