From unknown Tue Aug 19 07:26:41 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#70074 <70074@debbugs.gnu.org> To: bug#70074 <70074@debbugs.gnu.org> Subject: Status: 29.1; js-ts-mode doesn't define comment-line-break-function Reply-To: bug#70074 <70074@debbugs.gnu.org> Date: Tue, 19 Aug 2025 14:26:41 +0000 retitle 70074 29.1; js-ts-mode doesn't define comment-line-break-function reassign 70074 emacs submitter 70074 Evan Davis severity 70074 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Mar 29 12:02:08 2024 Received: (at submit) by debbugs.gnu.org; 29 Mar 2024 16:02:08 +0000 Received: from localhost ([127.0.0.1]:43233 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rqEgC-00015E-0A for submit@debbugs.gnu.org; Fri, 29 Mar 2024 12:02:08 -0400 Received: from lists.gnu.org ([2001:470:142::17]:49602) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rqDlV-0006Qg-0f for submit@debbugs.gnu.org; Fri, 29 Mar 2024 11:03:37 -0400 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 1rqDlN-0000bV-Oo for bug-gnu-emacs@gnu.org; Fri, 29 Mar 2024 11:03:25 -0400 Received: from mail-ed1-x530.google.com ([2a00:1450:4864:20::530]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rqDlL-0002pC-J6 for bug-gnu-emacs@gnu.org; Fri, 29 Mar 2024 11:03:25 -0400 Received: by mail-ed1-x530.google.com with SMTP id 4fb4d7f45d1cf-565c6cf4819so5205799a12.1 for ; Fri, 29 Mar 2024 08:03:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1711724601; x=1712329401; darn=gnu.org; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=9f2cMykI/wpn2BpIEAwU3b6oiDK+yPbp/3YNeNNxtns=; b=F67U/G6w5Dq7nGfZ5ef/kll6C4diX5J4vnpB8yzrYLnl1Hr4pARcnwUfNNW/PvTk1w SKNVCSDek1qsLDhMm5RoCKdnCHkm7K/DQibq/vByGmIZGUvujntyZ6aF9h9zgx0CURti mcv8HRaEOEvXddA+GRWXDmRyMnvnD49ZIAKAQRGiCWmUrYLGBzROKTUYjIhxPHwPF14Y 0qZ5mues4a9yJkUr2jdw7MeeOFVf/f3h5OitiU8e9+ZEY3jTvqykcVRGKLa1RPbvM4Ze mKzbPNtH3SpBTL6+LFXlyUtjolVtDjwYL3t0C5EA4+0XoYu0JOkUVK8Z9ZbYgOqYIz54 Mm+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711724601; x=1712329401; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=9f2cMykI/wpn2BpIEAwU3b6oiDK+yPbp/3YNeNNxtns=; b=Yma8weAHJCeuAXFhRuRzxW+rIdWiin8xeKvkyj/qlsQw/zVUmdqQQBearYV9ZgQ3+h lMwKboKfCHDV5rBjxHiA1Jg+TBkLz1qkbk3/FentWKGG7VF1ypf7DhJtNeki1ePVt4Vf /dfQSimFxL9Bc7w0ubGILKHqSHpWmE1WgZud835FI2vELNyqs7clRChaEbj8VDoUozp1 IStdWVcjjMq5K7ulNDg9QHJsnc0mNhvXtuvJfd3D9BUGqdhG2VePlEAEUm3gJnQR2YgI ya2j5xv/7QMfFGoUNHnB8Ym0NhjMIwKP0Ym2DotHypwSjmbabUx0WGAZANJcUwpX266h JYdw== X-Gm-Message-State: AOJu0YyyX0ZHCjJk1YUDF9hVzy7kmjXGx7tD4m+IIzLBqEXxfbs8QyPu 0vrBNLPls4gK7exSTdKYrmWGCbAatmqseJvlLjBwL3ve8fIXd4n1ww0Q0dy7VzlGc69FSTpLIqg KtICy9UAVrS34O9cvhL5TVzOlzOIR7k4d6b0= X-Google-Smtp-Source: AGHT+IGB+YF74HGQKiAdfO19cxVr2tGNf4+qa2Cl0NkyR1WWm6PGAfdwXfpIIVLbtxHTGZNRUkIQ7Nz0MC4lhrJpiEs= X-Received: by 2002:a50:bb49:0:b0:568:a5b5:8591 with SMTP id y67-20020a50bb49000000b00568a5b58591mr5630014ede.1.1711724601569; Fri, 29 Mar 2024 08:03:21 -0700 (PDT) MIME-Version: 1.0 From: Evan Davis Date: Fri, 29 Mar 2024 11:03:10 -0400 Message-ID: Subject: 29.1; js-ts-mode doesn't define comment-line-break-function To: bug-gnu-emacs@gnu.org Content-Type: multipart/alternative; boundary="000000000000d478c50614cdf0e5" Received-SPF: pass client-ip=2a00:1450:4864:20::530; envelope-from=davis.evan.m@gmail.com; helo=mail-ed1-x530.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, HTML_MESSAGE=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-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Fri, 29 Mar 2024 12:02:06 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) --000000000000d478c50614cdf0e5 Content-Type: text/plain; charset="UTF-8" js-ts-mode and js-mode behave differently when calling default-indent-new-line (M-j) within a multiline comment. Observed behavior: - in js-mode, M-j calls c-indent-new-comment-line, which correctly inserts a newline, indented to the correct column and prefixed with '*' - in js-ts-mode, M-j calls comment-indent-new-line, which inserts an indented newline without the prefix. Expected behavior: Block comments should be handled the same in both modes. Steps to reproduce: 1. emacs -Q 2. open a scratch buffer in js-ts-mode and enter text (without quotes) "/*" 3. press M-j 4. observe newline is created without star prefix Follow the same steps in js-mode to observe the desired behavior. In GNU Emacs 29.1 (build 1, aarch64-apple-darwin21.6.0, NS appkit-2113.60 Version 12.6.6 (Build 21G646)) of 2023-08-16 built on armbob.lan Windowing system distributor 'Apple', version 10.3.2299 System Description: macOS 13.6.3 Configured using: 'configure --with-ns '--enable-locallisppath=/Library/Application Support/Emacs/${version}/site-lisp:/Library/Application Support/Emacs/site-lisp' --with-modules 'CFLAGS=-DFD_SETSIZE=10000 -DDARWIN_UNLIMITED_SELECT' --with-x-toolkit=no' Configured features: ACL GLIB GMP GNUTLS JPEG JSON LIBXML2 MODULES NOTIFY KQUEUE NS PDUMPER PNG RSVG SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER ZLIB Important settings: value of $LC_ALL: en_US.UTF-8 value of $LANG: en_US locale-coding-system: utf-8-unix Major mode: JavaScript Minor modes in effect: tooltip-mode: t global-eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t line-number-mode: t indent-tabs-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message mailcap yank-media puny dired dired-loaddefs rfc822 mml mml-sec password-cache epa derived epg rfc6068 epg-config gnus-util text-property-search mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils pp cl-extra cl-print thingatpt help-fns radix-tree help-mode js c-ts-common treesit cl-seq json map byte-opt gv bytecomp byte-compile imenu cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align cc-engine cc-vars cc-defs time-date subr-x cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/ns-win ns-win ucs-normalize mule-util term/common-win tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads kqueue cocoa ns multi-tty make-network-process emacs) Memory information: ((conses 16 81595 8317) (symbols 48 8432 0) (strings 32 26906 1149) (string-bytes 1 926726) (vectors 16 16240) (vector-slots 8 222853 10872) (floats 8 35 38) (intervals 56 269 0) (buffers 984 11)) --000000000000d478c50614cdf0e5 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
js-ts-mode and js-mode behave differently when calling def= ault-indent-new-line (M-j) within a multiline comment.

Observed= behavior:=C2=A0
=C2=A0 - in js-mode, M-j calls c-indent-new-comm= ent-line, which correctly inserts a newline, indented to the correct column= and prefixed with '*'
=C2=A0 - in js-ts-mode, M-j calls = comment-indent-new-line, which inserts an indented newline without the pref= ix.

Expected behavior:
Block comments should be handled th= e same in both modes.

Steps to reproduce:
1. emacs -Q
2. open a scratch buffer in js-ts-mode and enter te= xt (without quotes) "/*"
3. press M-j
4. obse= rve newline is created without star prefix

Follow = the same steps in js-mode to observe the desired behavior.

In GNU Em= acs 29.1 (build 1, aarch64-apple-darwin21.6.0, NS
=C2=A0appkit-2113.60 V= ersion 12.6.6 (Build 21G646)) of 2023-08-16 built on
=C2=A0armbob.lanWindowing system distributor 'Apple', version 10.3.2299
System = Description: =C2=A0macOS 13.6.3

Configured using:
=C2=A0'conf= igure --with-ns '--enable-locallisppath=3D/Library/Application
=C2= =A0Support/Emacs/${version}/site-lisp:/Library/Application
=C2=A0Support= /Emacs/site-lisp' --with-modules 'CFLAGS=3D-DFD_SETSIZE=3D10000
= =C2=A0-DDARWIN_UNLIMITED_SELECT' --with-x-toolkit=3Dno'

Conf= igured features:
ACL GLIB GMP GNUTLS JPEG JSON LIBXML2 MODULES NOTIFY KQ= UEUE NS PDUMPER
PNG RSVG SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_S= ITTER ZLIB

Important settings:
=C2=A0 value of $LC_ALL: en_US.UTF= -8
=C2=A0 value of $LANG: en_US
=C2=A0 locale-coding-system: utf-8-un= ix

Major mode: JavaScript

Minor modes in effect:
=C2=A0 to= oltip-mode: t
=C2=A0 global-eldoc-mode: t
=C2=A0 show-paren-mode: t=C2=A0 electric-indent-mode: t
=C2=A0 mouse-wheel-mode: t
=C2=A0 to= ol-bar-mode: t
=C2=A0 menu-bar-mode: t
=C2=A0 file-name-shadow-mode: = t
=C2=A0 global-font-lock-mode: t
=C2=A0 font-lock-mode: t
=C2=A0 = blink-cursor-mode: t
=C2=A0 line-number-mode: t
=C2=A0 indent-tabs-mo= de: t
=C2=A0 transient-mark-mode: t
=C2=A0 auto-composition-mode: t=C2=A0 auto-encryption-mode: t
=C2=A0 auto-compression-mode: t

= Load-path shadows:
None found.

Features:
(shadow sort mail-ext= r emacsbug message mailcap yank-media puny dired
dired-loaddefs rfc822 m= ml mml-sec password-cache epa derived epg rfc6068
epg-config gnus-util t= ext-property-search mm-decode mm-bodies mm-encode
mail-parse rfc2231 mai= labbrev gmm-utils mailheader sendmail rfc2047
rfc2045 ietf-drums mm-util= mail-prsvr mail-utils pp cl-extra cl-print
thingatpt help-fns radix-tre= e help-mode js c-ts-common treesit cl-seq
json map byte-opt gv bytecomp = byte-compile imenu cc-mode cc-fonts
cc-guess cc-menus cc-cmds cc-styles = cc-align cc-engine cc-vars cc-defs
time-date subr-x cl-loaddefs cl-lib r= mc iso-transl tooltip cconv eldoc
paren electric uniquify ediff-hook vc-= hooks lisp-float-type elisp-mode
mwheel term/ns-win ns-win ucs-normalize= mule-util term/common-win
tool-bar dnd fontset image regexp-opt fringe = tabulated-list replace
newcomment text-mode lisp-mode prog-mode register= page tab-bar menu-bar
rfn-eshadow isearch easymenu timer select scroll-= bar mouse jit-lock
font-lock syntax font-core term/tty-colors frame mini= buffer nadvice seq
simple cl-generic indonesian philippine cham georgian= utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japane= se eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic= indian
cyrillic chinese composite emoji-zwj charscript charprop case-ta= ble
epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded but= ton
loaddefs theme-loaddefs faces cus-face macroexp files window
text= -properties overlay sha1 md5 base64 format env code-pages mule
custom wi= dget keymap hashtable-print-readable backquote threads kqueue
cocoa ns m= ulti-tty make-network-process emacs)

Memory information:
((conses= 16 81595 8317)
=C2=A0(symbols 48 8432 0)
=C2=A0(strings 32 26906 114= 9)
=C2=A0(string-bytes 1 926726)
=C2=A0(vectors 16 16240)
=C2=A0(v= ector-slots 8 222853 10872)
=C2=A0(floats 8 35 38)
=C2=A0(intervals 5= 6 269 0)
=C2=A0(buffers 984 11))
--000000000000d478c50614cdf0e5-- From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 04 08:33:02 2024 Received: (at 70074) by debbugs.gnu.org; 4 Apr 2024 12:33:02 +0000 Received: from localhost ([127.0.0.1]:60754 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rsMH7-0000Nn-MZ for submit@debbugs.gnu.org; Thu, 04 Apr 2024 08:33:01 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42178) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rsMH6-0000Mv-4c for 70074@debbugs.gnu.org; Thu, 04 Apr 2024 08:33:00 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rsMGv-0006Mh-L6; Thu, 04 Apr 2024 08:32:49 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=hLgPm1Fi+jNRXDkQeh8JJoSJXBkgG73MOSj/hq5N7kA=; b=dn1MA80VRdjP SShSwGkVxWVdJu/Tqe8f5Uh1cLV58Xyc3tydhMY3oIh9DZu9nFcS2e4qUgzzeMYDGW11mm4Da3hAi Wzy+5vB+pUH/x9IXjV7VkH/a/pakdus6ECjhAEJicjzj/0PC+StJFyegzF7tziTL05A3gQcwpJehY oFQvqdvjfNh9tguJPBFplUlQGuLJlNZhnPxIsLObDbs7zbEJnLIBeMW/9B8vtaAsLmOQ+Xjny3uRo fYVomGRXaMzaEgV3f6ZkvTJ54QBNz+uvyBIwoIUXYewQsEdpHGPClBroSreH9TrWrvr0PDON1zts6 3JI3JHzmSRByf3UzFh27mA==; Date: Thu, 04 Apr 2024 15:32:47 +0300 Message-Id: <86msq971g0.fsf@gnu.org> From: Eli Zaretskii To: Evan Davis , Dmitry Gutov , Yuan Fu In-Reply-To: (message from Evan Davis on Fri, 29 Mar 2024 11:03:10 -0400) Subject: Re: bug#70074: 29.1; js-ts-mode doesn't define comment-line-break-function References: X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 70074 Cc: 70074@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Evan Davis > Date: Fri, 29 Mar 2024 11:03:10 -0400 > > js-ts-mode and js-mode behave differently when calling default-indent-new-line (M-j) within a multiline > comment. > > Observed behavior: > - in js-mode, M-j calls c-indent-new-comment-line, which correctly inserts a newline, indented to the correct > column and prefixed with '*' > - in js-ts-mode, M-j calls comment-indent-new-line, which inserts an indented newline without the prefix. > > Expected behavior: > Block comments should be handled the same in both modes. > > Steps to reproduce: > 1. emacs -Q > 2. open a scratch buffer in js-ts-mode and enter text (without quotes) "/*" > 3. press M-j > 4. observe newline is created without star prefix > > Follow the same steps in js-mode to observe the desired behavior. Dmitry, Yuan: any comments or suggestions? From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 04 20:28:30 2024 Received: (at 70074) by debbugs.gnu.org; 5 Apr 2024 00:28:30 +0000 Received: from localhost ([127.0.0.1]:34965 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rsXRV-0001LK-Aj for submit@debbugs.gnu.org; Thu, 04 Apr 2024 20:28:30 -0400 Received: from wout4-smtp.messagingengine.com ([64.147.123.20]:58953) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rsXRS-0001KM-My for 70074@debbugs.gnu.org; Thu, 04 Apr 2024 20:28:27 -0400 Received: from compute7.internal (compute7.nyi.internal [10.202.2.48]) by mailout.west.internal (Postfix) with ESMTP id F1373320094F; Thu, 4 Apr 2024 20:28:14 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Thu, 04 Apr 2024 20:28:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gutov.dev; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm1; t=1712276894; x=1712363294; bh=gY/tz3dxodE18Fpl/3nDUrGSb245+1H8lU2+g+hxA3I=; b= wYXBrBmbqyoA3M0Y/8T/L00rcW5OoFtmOFR5wASdkhrgKh6XSC/OiyisQageCrXA YVXvZy5/tFQzsar0hO4WzqpxTVffVoOUVPnytm5gIYRMeCFqyNTHlRLib7a9szak xuyzRREEFOjj6S7r+IiJbRvx44ZPJj2hCRlxhhInm8nznaFeWVQTUWRt0QPVT4vd WAJE08yxYPAWmR/2UH19fRVSVHBaP14zAOinIJ6/MEDAelDmK3Y8MpxPwrVcmOAk caGQZ0bniXDLONwBtqnwdecDgbUKeq66knxWMcjzh1Hfd5p/m5+WE9McWnV+Yz/F VadBB0pR76/370Wuj97F6A== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1712276894; x= 1712363294; bh=gY/tz3dxodE18Fpl/3nDUrGSb245+1H8lU2+g+hxA3I=; b=M e/UqDkYR22ZyCgYlglDoITdwhWkT2Nx191Ou51OFRpgHzrrDu/WmVaBP7CieE7cb /ICmwgvuZMH+29LKH9NzpDNqAPwzeUS0VEItj75MO1RZtvH6EynHDA/t99bYx5HF IntXGVrPrwKNkAL9ysIqGKv89I8wd7PxB6wuK1NaJrmiDejGntbKCO/UCfjUjWcK xlPOffFJJ+F7RtERrrmytqI0PQ7W2E0qE0K7/fIpy7+OqMMt1ZVvlIbTEbCnGPYS 0LceV+ZXd7tpq1jelEVc/aKumM4CoO/6zWL3+Wt1HVSVKp0Mu1RuBEUlWe7eFUa+ n7QmDuW6QXb6J0RB0b9yA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrudefledgfeeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepkfffgggfuffvvehfhfgjtgfgsehtjeertddtvdejnecuhfhrohhmpeffmhhi thhrhicuifhuthhovhcuoegumhhithhrhiesghhuthhovhdruggvvheqnecuggftrfgrth htvghrnhepteduleejgeehtefgheegjeekueehvdevieekueeftddvtdevfefhvdevgedu jeehnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepug hmihhtrhihsehguhhtohhvrdguvghv X-ME-Proxy: Feedback-ID: i0e71465a:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 4 Apr 2024 20:28:12 -0400 (EDT) Message-ID: <4b3706a2-84d8-43c4-95bb-02d6f8c450b0@gutov.dev> Date: Fri, 5 Apr 2024 03:28:10 +0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#70074: 29.1; js-ts-mode doesn't define comment-line-break-function Content-Language: en-US To: Eli Zaretskii , Evan Davis , Yuan Fu References: <86msq971g0.fsf@gnu.org> From: Dmitry Gutov In-Reply-To: <86msq971g0.fsf@gnu.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 70074 Cc: 70074@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) On 04/04/2024 15:32, Eli Zaretskii wrote: >> From: Evan Davis >> Date: Fri, 29 Mar 2024 11:03:10 -0400 >> >> js-ts-mode and js-mode behave differently when calling default-indent-new-line (M-j) within a multiline >> comment. >> >> Observed behavior: >> - in js-mode, M-j calls c-indent-new-comment-line, which correctly inserts a newline, indented to the correct >> column and prefixed with '*' >> - in js-ts-mode, M-j calls comment-indent-new-line, which inserts an indented newline without the prefix. >> >> Expected behavior: >> Block comments should be handled the same in both modes. >> >> Steps to reproduce: >> 1. emacs -Q >> 2. open a scratch buffer in js-ts-mode and enter text (without quotes) "/*" >> 3. press M-j >> 4. observe newline is created without star prefix >> >> Follow the same steps in js-mode to observe the desired behavior. > Dmitry, Yuan: any comments or suggestions? I suppose following in js-mode's footsteps and reusing this part of CC Mode is the obvious solution. I haven't looked at the implementation closely enough to suggest something else, but it'd of course be nice to be able to provide a self-contained, shorter re-implementation instead. From debbugs-submit-bounces@debbugs.gnu.org Mon Apr 08 03:10:59 2024 Received: (at 70074) by debbugs.gnu.org; 8 Apr 2024 07:10:59 +0000 Received: from localhost ([127.0.0.1]:45187 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rtj9f-000636-5x for submit@debbugs.gnu.org; Mon, 08 Apr 2024 03:10:59 -0400 Received: from mail-pf1-x431.google.com ([2607:f8b0:4864:20::431]:53559) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rtj9d-00062r-KM for 70074@debbugs.gnu.org; Mon, 08 Apr 2024 03:10:58 -0400 Received: by mail-pf1-x431.google.com with SMTP id d2e1a72fcca58-6e703e0e5deso3675633b3a.3 for <70074@debbugs.gnu.org>; Mon, 08 Apr 2024 00:10:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1712560244; x=1713165044; darn=debbugs.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=OXz7/86gowURt1OsgoP4tuX9usjkVJR6rc2M4mOlx0Y=; b=WuEX01TrNYHe0Y3GF/etlsoyxIGq5tWZIaDRyQdXcRE5Z9aT5iwa8dclkwKmc+CLET A4fBFYAip1QhG92eIkkw00WrrADnn4pN8eq6P4p70W5otCjDjyCPGMrgrqeH4xpdiAlU POOQvVHtWpLPQaqh7sUgq06UBNQdiwgjiKYSidcxVPsAIxuWWU/MGcBLqlcMUYLpTphj qYv3RYGESGTAYke+1azDsfmg6WTiThitcaHZQQXV+x+n4vU+wkDW+BJd4daPXzq/fxoT 8zo5WNUPhy2tk/4nkw19EDc3RgtIEjl4m4rSbWHLA8JmYHqqTTPBcS50n/io5nshVJIb 42Nw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712560244; x=1713165044; 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=OXz7/86gowURt1OsgoP4tuX9usjkVJR6rc2M4mOlx0Y=; b=rPfUXds8VHPGLgVdbVTE8OEzO8nAv7diUtDbmCFOCHBHdHBUOnQyTSWDps4BPtfIdT mv+l0uYuj5cmqlF3IijRE0YefLCosbFfoEM6LwwcrzfEs5b8tvPM5FnYgwH46KkCA/by bLj5Ru1z+74yk1BGsDQAfsIp0bkcJALHPjJg1vZbJJtzn421HYHozt6UIZ5t3GG68EhW njjAN6LIK4JId3m//mJ4VZJPvnc9TRhSoPY0NKWCzk/v9iovdPpJaTDTRT+MA5txZqxP wu11HiAmpIYfkBa392eMXJFahR8taFFQBzK1S06UG1B2rHO7snwDmT3MOZAipTHT/W4a zBlQ== X-Forwarded-Encrypted: i=1; AJvYcCVzEETDpelKmLHh5ddFajLbuxcR4NfDM3RB9ga2dU1NLysxtziIEvr90RI2q6E762bM1+1m5jlEXHpdLEdHySFrnWcIFKg= X-Gm-Message-State: AOJu0YwE9kMOCD7MMALtTy/fGZyQl+Brt5tcroxO3dXCy5PbFg0Rjupw OZ53XfzJJw9DckocW1pKBDg1wYNx1frRUNsHAeLSEbClbELlH3Ni X-Google-Smtp-Source: AGHT+IFQAgtsD+YjnD7QzuoxXuf9+JHxx/uwaDwOMuwhRSqR4hFiddLFQUL1xF6mWeD81/iV35sSFQ== X-Received: by 2002:a05:6a20:7293:b0:1a3:65af:9baa with SMTP id o19-20020a056a20729300b001a365af9baamr7654728pzk.62.1712560244262; Mon, 08 Apr 2024 00:10:44 -0700 (PDT) Received: from smtpclient.apple ([2601:641:300:4910:6c00:57e9:a6fc:238b]) by smtp.gmail.com with ESMTPSA id 41-20020a17090a09ac00b002a528a1f907sm975688pjo.56.2024.04.08.00.10.43 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 08 Apr 2024 00:10:43 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.700.6\)) Subject: Re: bug#70074: 29.1; js-ts-mode doesn't define comment-line-break-function From: Yuan Fu In-Reply-To: <4b3706a2-84d8-43c4-95bb-02d6f8c450b0@gutov.dev> Date: Mon, 8 Apr 2024 00:10:32 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <8A759F5C-DA2B-43CC-BF19-3DEA98745986@gmail.com> References: <86msq971g0.fsf@gnu.org> <4b3706a2-84d8-43c4-95bb-02d6f8c450b0@gutov.dev> To: Dmitry Gutov X-Mailer: Apple Mail (2.3731.700.6) X-Spam-Score: 0.7 (/) X-Debbugs-Envelope-To: 70074 Cc: Eli Zaretskii , 70074@debbugs.gnu.org, Evan Davis X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.3 (/) > On Apr 4, 2024, at 5:28 PM, Dmitry Gutov wrote: >=20 > On 04/04/2024 15:32, Eli Zaretskii wrote: >>> From: Evan Davis >>> Date: Fri, 29 Mar 2024 11:03:10 -0400 >>>=20 >>> js-ts-mode and js-mode behave differently when calling = default-indent-new-line (M-j) within a multiline >>> comment. >>>=20 >>> Observed behavior: >>> - in js-mode, M-j calls c-indent-new-comment-line, which correctly = inserts a newline, indented to the correct >>> column and prefixed with '*' >>> - in js-ts-mode, M-j calls comment-indent-new-line, which inserts = an indented newline without the prefix. >>>=20 >>> Expected behavior: >>> Block comments should be handled the same in both modes. >>>=20 >>> Steps to reproduce: >>> 1. emacs -Q >>> 2. open a scratch buffer in js-ts-mode and enter text (without = quotes) "/*" >>> 3. press M-j >>> 4. observe newline is created without star prefix >>>=20 >>> Follow the same steps in js-mode to observe the desired behavior. >> Dmitry, Yuan: any comments or suggestions? >=20 > I suppose following in js-mode's footsteps and reusing this part of CC = Mode is the obvious solution. >=20 > I haven't looked at the implementation closely enough to suggest = something else, but it'd of course be nice to be able to provide a = self-contained, shorter re-implementation instead. Sounds good. I wasn=E2=80=99t aware of this command before. Let me add = it to c-ts-common.el. Yuan= From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 20 03:44:30 2024 Received: (at 70074) by debbugs.gnu.org; 20 Apr 2024 07:44:30 +0000 Received: from localhost ([127.0.0.1]:34863 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ry5Oe-0005dq-Rd for submit@debbugs.gnu.org; Sat, 20 Apr 2024 03:44:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35122) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ry5Ob-0005cY-Rm for 70074@debbugs.gnu.org; Sat, 20 Apr 2024 03:44:27 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ry5OH-0007e1-T0; Sat, 20 Apr 2024 03:44:05 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=Smfq4raoCWVOEPcE64WpgFMo2Fxn7ZnxgsZNUtP270A=; b=UiRfPSTu2K83qf4O5oam zfAaZfSZDoZmerdYUqT+VbXM36TZfHh69whTcdjsj7S4PNGihQzKpJ/p1W19L99r2VcK8rcbCZVdw aoeEqS9JQYxZK87wMpbvW6KQubB/pI9/wvJG7fZm1aVbgUTvguLoEiks3HUAUqjbxBylMjUH8QQc4 aD8TpF/jvdooll/nMY1N+qvyWukfBERQu7LCuVEbg+jgXcKdrJPy8G12yVZ8ZvxOmGUqcTeAZre/c 8BJlzy1wjPFjx8AAKm4roKpblOJunLQxRoVCo6eJBOHfqF0DDmFzdHCfUMFaHT9S2Bp0bJ+/o22lm OsNivrUQxL20TA==; Date: Sat, 20 Apr 2024 10:44:03 +0300 Message-Id: <86cyqka37g.fsf@gnu.org> From: Eli Zaretskii To: Yuan Fu In-Reply-To: <8A759F5C-DA2B-43CC-BF19-3DEA98745986@gmail.com> (message from Yuan Fu on Mon, 8 Apr 2024 00:10:32 -0700) Subject: Re: bug#70074: 29.1; js-ts-mode doesn't define comment-line-break-function References: <86msq971g0.fsf@gnu.org> <4b3706a2-84d8-43c4-95bb-02d6f8c450b0@gutov.dev> <8A759F5C-DA2B-43CC-BF19-3DEA98745986@gmail.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -1.6 (-) X-Debbugs-Envelope-To: 70074 Cc: dmitry@gutov.dev, 70074@debbugs.gnu.org, davis.evan.m@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.6 (--) Ping! Yuan, can we make some progress here? > From: Yuan Fu > Date: Mon, 8 Apr 2024 00:10:32 -0700 > Cc: Eli Zaretskii , > Evan Davis , > 70074@debbugs.gnu.org > > > > > On Apr 4, 2024, at 5:28 PM, Dmitry Gutov wrote: > > > > On 04/04/2024 15:32, Eli Zaretskii wrote: > >>> From: Evan Davis > >>> Date: Fri, 29 Mar 2024 11:03:10 -0400 > >>> > >>> js-ts-mode and js-mode behave differently when calling default-indent-new-line (M-j) within a multiline > >>> comment. > >>> > >>> Observed behavior: > >>> - in js-mode, M-j calls c-indent-new-comment-line, which correctly inserts a newline, indented to the correct > >>> column and prefixed with '*' > >>> - in js-ts-mode, M-j calls comment-indent-new-line, which inserts an indented newline without the prefix. > >>> > >>> Expected behavior: > >>> Block comments should be handled the same in both modes. > >>> > >>> Steps to reproduce: > >>> 1. emacs -Q > >>> 2. open a scratch buffer in js-ts-mode and enter text (without quotes) "/*" > >>> 3. press M-j > >>> 4. observe newline is created without star prefix > >>> > >>> Follow the same steps in js-mode to observe the desired behavior. > >> Dmitry, Yuan: any comments or suggestions? > > > > I suppose following in js-mode's footsteps and reusing this part of CC Mode is the obvious solution. > > > > I haven't looked at the implementation closely enough to suggest something else, but it'd of course be nice to be able to provide a self-contained, shorter re-implementation instead. > > Sounds good. I wasn’t aware of this command before. Let me add it to c-ts-common.el. > > Yuan From debbugs-submit-bounces@debbugs.gnu.org Mon Apr 22 00:36:05 2024 Received: (at 70074) by debbugs.gnu.org; 22 Apr 2024 04:36:06 +0000 Received: from localhost ([127.0.0.1]:45363 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rylPQ-00071u-26 for submit@debbugs.gnu.org; Mon, 22 Apr 2024 00:36:05 -0400 Received: from mail-pl1-x62f.google.com ([2607:f8b0:4864:20::62f]:43418) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rylPJ-000705-S9 for 70074@debbugs.gnu.org; Mon, 22 Apr 2024 00:36:02 -0400 Received: by mail-pl1-x62f.google.com with SMTP id d9443c01a7336-1e2c725e234so37437025ad.1 for <70074@debbugs.gnu.org>; Sun, 21 Apr 2024 21:35:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1713760536; x=1714365336; darn=debbugs.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=fJ0MGYxMSxcXbm1UwaqRkoEKs7TQs5LGCi8NcIpnkGE=; b=DjXmjyx9tnVvdRKQpcGisY5947+rELD3+a77waY6XbbhuXmFN3a+r8kNXJjmWpM80U huKxIhaWjsnzMGfrgYGAqgHfo/nmbRocrbENjXfN7XhHETrzYnqE9E+I/mHQiv1Pv+E1 AbNt/ej0tTmj1bDS3BQFoeatafGvADUKERyJCy1nfCT8uJ7K9njo3ryA1TF9VMxp5oGw VN3jnKcPObgzeNR59B7ExXBacm7lMkB9vX+Vi01F8eSlnzjLhyoGluIP9Tt7VHAJsjJB +6TMoW9Ko49+ImO1iqVEA1YmqL7NQecm4a5K35WRjVjBK5wPfvK01ABiqiVMS5s3Dh+7 7hjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713760536; x=1714365336; 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=fJ0MGYxMSxcXbm1UwaqRkoEKs7TQs5LGCi8NcIpnkGE=; b=CTHE+qTmPONmQrmWOZYGyjO0ixnzI/GOlNqIg5fvVI5GbzUppT+rpVBJNGJJCj0d18 F30nDSftb9TojvJeHv7b0nOsSJZc8P/CEu+M6vCv8DfJjzqAnd9Ki2n5I/YZG41+AzCf /c8cU0I2hW7hEVchfguQhR4V/35VAD1ArQqac5b72RktdExbgp2agXEkoY2OybRDxoEh 6c+dyNTCl25PnOeWapNmZ6PGMukEyetCZtyuDN34f5x+K1XvxTdSAA4jLucmUqD1nmAP GBlKgKBGVOb1jxYt9+OOddr3NyekCK1O6AuGYhj/y2O/FY7yb9dyVDAB4aMVCNd++l4U mZSQ== X-Forwarded-Encrypted: i=1; AJvYcCU1Hqn32MAqF1xHs2gFw0uwmtASPnF4swlk5L10nvA8ur+4iQ5xXhEE3qX+42L0dAZ4HeYJEjID/Y8EvcGDmyP0y+RE0ug= X-Gm-Message-State: AOJu0YzQWuLAcug6P++0Z162IFkWxtFgfFdBwbPU20JOKmbtLhE+vOcI al3LiIiKTeOTvUhqES9chCKgMLwHaFdCnaNuVr5IO6wxaIP7XDFz X-Google-Smtp-Source: AGHT+IGTHYAEq/MCQCBIdsR99+U3es7Ys9a5siO2toYsPV5rhhZlA3HKW58L+9hMV1FW/wbDdqjr0w== X-Received: by 2002:a17:902:a50c:b0:1e2:36d1:33fd with SMTP id s12-20020a170902a50c00b001e236d133fdmr13719584plq.27.1713760536116; Sun, 21 Apr 2024 21:35:36 -0700 (PDT) Received: from smtpclient.apple ([2601:641:300:4910:e4f6:f0b8:c91d:e40b]) by smtp.gmail.com with ESMTPSA id n6-20020a170903110600b001e668c1060bsm7067948plh.122.2024.04.21.21.35.35 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sun, 21 Apr 2024 21:35:35 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.700.6.1.1\)) Subject: Re: bug#70074: 29.1; js-ts-mode doesn't define comment-line-break-function From: Yuan Fu In-Reply-To: <86cyqka37g.fsf@gnu.org> Date: Sun, 21 Apr 2024 21:35:24 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <36DDEBAF-1288-4373-8879-05F833D12C65@gmail.com> References: <86msq971g0.fsf@gnu.org> <4b3706a2-84d8-43c4-95bb-02d6f8c450b0@gutov.dev> <8A759F5C-DA2B-43CC-BF19-3DEA98745986@gmail.com> <86cyqka37g.fsf@gnu.org> To: Eli Zaretskii X-Mailer: Apple Mail (2.3731.700.6.1.1) X-Spam-Score: 0.7 (/) X-Debbugs-Envelope-To: 70074 Cc: dmitry@gutov.dev, 70074@debbugs.gnu.org, davis.evan.m@gmail.com X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.3 (/) > On Apr 20, 2024, at 12:44 AM, Eli Zaretskii wrote: >=20 > Ping! Yuan, can we make some progress here? >=20 >> From: Yuan Fu >> Date: Mon, 8 Apr 2024 00:10:32 -0700 >> Cc: Eli Zaretskii , >> Evan Davis , >> 70074@debbugs.gnu.org >>=20 >>=20 >>=20 >>> On Apr 4, 2024, at 5:28 PM, Dmitry Gutov wrote: >>>=20 >>> On 04/04/2024 15:32, Eli Zaretskii wrote: >>>>> From:Evan Davis >>>>> Date: Fri, 29 Mar 2024 11:03:10 -0400 >>>>>=20 >>>>> js-ts-mode and js-mode behave differently when calling = default-indent-new-line (M-j) within a multiline >>>>> comment. >>>>>=20 >>>>> Observed behavior: >>>>> - in js-mode, M-j calls c-indent-new-comment-line, which = correctly inserts a newline, indented to the correct >>>>> column and prefixed with '*' >>>>> - in js-ts-mode, M-j calls comment-indent-new-line, which inserts = an indented newline without the prefix. >>>>>=20 >>>>> Expected behavior: >>>>> Block comments should be handled the same in both modes. >>>>>=20 >>>>> Steps to reproduce: >>>>> 1. emacs -Q >>>>> 2. open a scratch buffer in js-ts-mode and enter text (without = quotes) "/*" >>>>> 3. press M-j >>>>> 4. observe newline is created without star prefix >>>>>=20 >>>>> Follow the same steps in js-mode to observe the desired behavior. >>>> Dmitry, Yuan: any comments or suggestions? >>>=20 >>> I suppose following in js-mode's footsteps and reusing this part of = CC Mode is the obvious solution. >>>=20 >>> I haven't looked at the implementation closely enough to suggest = something else, but it'd of course be nice to be able to provide a = self-contained, shorter re-implementation instead. >>=20 >> Sounds good. I wasn=E2=80=99t aware of this command before. Let me = add it to c-ts-common.el. >>=20 >> Yuan I looked at the implementation of c-indent-new-comment-line, it=E2=80=99s = 178 lines of complicated control flow, handling all sorts of edge cases = that I don=E2=80=99t understand. Sadly it=E2=80=99s pretty keeping = coupled with the whole cc framework, so it=E2=80=99ll be pretty hard to = take it out and reuse for c-ts-common.el. So I added a new function c-ts-common-comment-indent-new-line. It=E2=80=99= s probably nothing compare to c-indent-new-comment-line=E2=80=99s = capabilities, but it can at least handle the usual cases that I can = think of: indenting after //, after /*, after * inside a block comment, = and after | inside a block comment. For more advanced use-cases, we can wait until someone asks for them. Evan, if you pull the latest master, M-j should now just work for = js-ts-mode. Yuan= From debbugs-submit-bounces@debbugs.gnu.org Tue Apr 23 00:28:00 2024 Received: (at 70074-done) by debbugs.gnu.org; 23 Apr 2024 04:28:00 +0000 Received: from localhost ([127.0.0.1]:49675 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rz7l8-0000fv-PR for submit@debbugs.gnu.org; Tue, 23 Apr 2024 00:27:59 -0400 Received: from mail-pl1-x634.google.com ([2607:f8b0:4864:20::634]:57438) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rz7l3-0000eT-RV for 70074-done@debbugs.gnu.org; Tue, 23 Apr 2024 00:27:57 -0400 Received: by mail-pl1-x634.google.com with SMTP id d9443c01a7336-1e3f17c6491so41279895ad.2 for <70074-done@debbugs.gnu.org>; Mon, 22 Apr 2024 21:27:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1713846452; x=1714451252; darn=debbugs.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=CvaLvpUiWe7jIQs+OaLjWHJ9BBzA47d4Kle70Y0ctFk=; b=VWLm5ZLez1cvzr3gigZAnaf0KO+0NyyrWTDQJDhtE6RC2QNGyFzpQ5/kpXKvNtgXE9 8HC3m7x9lRK4a6eNc4KBFgCORik1FHuYJPVLqmKmS/V0s5w3Wcsf8aqMMYD19RzCjxH/ SBLi3eu0qauM19r1AeNm690jZoN/mS6hgXXYuzkfCSXrOe+G2NacKAyuXD5rLpTE4U6W PBlSakMu2Fv/ix8JLZGczYL2d2GHQ0TssBEu2mi73sBVEOVHDA4uTZ1Kw3T46gkAmh3D vhXQfRce2abzUe+gPyQ4rOqna1I5cNAdifHUTLS1zDmLsmdrpsHSmmuyvX6pxVb9/JpV tGbg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713846452; x=1714451252; 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=CvaLvpUiWe7jIQs+OaLjWHJ9BBzA47d4Kle70Y0ctFk=; b=HNx3UTBAfNvauHeLGl30+LeEdfBsrL2PMiNBLTsGVLVqBkTHiLCCXthgR8iX7OWAFK 8bDyBDq83GmBSt6Q4kfDQHpZ+pae1PE4NbPa707jhWVKRL3/XmeTPDaOz5yVZyBgYG/A SMcQ9LJbAwn6+PYKE4LdEhbWaIV5/gx4Xgfl5DDEDHHWKP6jOzhZ1JQOAbyFH56NZpGj mwFB1V/m+d1sHcnYAztOzdo7rrXnIe4IO3y31ceKRwGum4W+HnDEBbX5HmewX316lfup ecdWz/AAukvKAePnRtmJBcd+jLUwDBgTdtH1FkjOooYGGG5gRlsi9IwtTjncrWuf7EEk QHfA== X-Gm-Message-State: AOJu0Yx3CFU5z8A1RXhpPA3vryzNyukMomh0JmVcxBQwlCtXAqu0oXUk 6CNgGGT65nWQPSvgvKlrlyQdX6zQyCJFZiG98D1U9gvWWHJI91SfnUNadw== X-Google-Smtp-Source: AGHT+IH0nKSQY9ZHSK2yyB7S3StyY6CuhlbFgLTEk37MscyLKEidXKVetmltwhr6PEB3yRl6f7uWkw== X-Received: by 2002:a17:903:18b:b0:1e2:a91c:9836 with SMTP id z11-20020a170903018b00b001e2a91c9836mr14632476plg.33.1713846451650; Mon, 22 Apr 2024 21:27:31 -0700 (PDT) Received: from smtpclient.apple ([2601:641:300:4910:e4f6:f0b8:c91d:e40b]) by smtp.gmail.com with ESMTPSA id d17-20020a170903209100b001e264b50964sm8956285plc.205.2024.04.22.21.27.30 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 22 Apr 2024 21:27:31 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.700.6.1.1\)) Subject: Re: bug#70074: 29.1; js-ts-mode doesn't define comment-line-break-function From: Yuan Fu In-Reply-To: Date: Mon, 22 Apr 2024 21:27:20 -0700 Content-Transfer-Encoding: 7bit Message-Id: References: <86msq971g0.fsf@gnu.org> <4b3706a2-84d8-43c4-95bb-02d6f8c450b0@gutov.dev> <8A759F5C-DA2B-43CC-BF19-3DEA98745986@gmail.com> <86cyqka37g.fsf@gnu.org> <36DDEBAF-1288-4373-8879-05F833D12C65@gmail.com> To: Evan Davis X-Mailer: Apple Mail (2.3731.700.6.1.1) X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 70074-done Cc: 70074-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) > On Apr 22, 2024, at 12:06 PM, Evan Davis wrote: > > Confirmed, works as expected. Thanks! Great! Closing this. Yuan From unknown Tue Aug 19 07:26:41 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Tue, 21 May 2024 11:24:13 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator