emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#69088: closed ([PATCH] Eagerly indent first field in tables in lua-t


From: GNU bug Tracking System
Subject: bug#69088: closed ([PATCH] Eagerly indent first field in tables in lua-ts-mode)
Date: Sat, 17 Feb 2024 08:59:01 +0000

Your message dated Sat, 17 Feb 2024 10:58:12 +0200
with message-id <865xynv55n.fsf@gnu.org>
and subject line Re: bug#69088: [PATCH] Eagerly indent first field in tables in 
lua-ts-mode
has caused the debbugs.gnu.org bug report #69088,
regarding [PATCH] Eagerly indent first field in tables in lua-ts-mode
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs@gnu.org.)


-- 
69088: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=69088
GNU Bug Tracking System
Contact help-debbugs@gnu.org with problems
--- Begin Message --- Subject: [PATCH] Eagerly indent first field in tables in lua-ts-mode Date: Mon, 12 Feb 2024 19:00:04 -0600
Tags: patch

lua-ts-mode supports aligning table fields to the first field so that
you can have code like:

  local t = { a = 1,
              b = 2, }

However if you prefer to put the first field on a newline like:

  local t = {
      a = 1,
      b = 2,
  }

the indentation doesn’t happen until you press RET after the first
comma. So you initially have something like (where | is point):

  local t = {
  |
  }

This patch fixes that so the initial indentation is correct from the beginning:

  local t = {
      |
  }



--- End Message ---
--- Begin Message --- Subject: Re: bug#69088: [PATCH] Eagerly indent first field in tables in lua-ts-mode Date: Sat, 17 Feb 2024 10:58:12 +0200
> Cc: 69088@debbugs.gnu.org
> Date: Mon, 12 Feb 2024 21:42:01 -0600
> From:  john muhl via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
> 
> Dmitry Gutov <dmitry@gutov.dev> writes:
> 
> > On 13/02/2024 04:49, john muhl via Bug reports for GNU Emacs, the
> > Swiss army knife of text editors wrote:
> >> +     ((and (lambda (node &rest _) (null node))
> >> +           (parent-is "table_constructor"))
> >
> > That's probably the same as (match null "table_constructor")
> 
> Yes it is. Thanks for the pointer.

Thanks, installed on master, and closing the bug.


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]