GNU bug report logs - #69088
[PATCH] Eagerly indent first field in tables in lua-ts-mode

Previous Next

Package: emacs;

Reported by: john muhl <jm <at> pub.pink>

Date: Tue, 13 Feb 2024 02:29:02 UTC

Severity: normal

Tags: patch

Merged with 69089

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: john muhl <jm <at> pub.pink>
To: 69088 <at> debbugs.gnu.org
Subject: bug#69088: [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 = {
      |
  }




This bug report was last modified 1 year and 187 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.