Subject: bug#61398: closed (Re: bug#61398: 29.0.60; c-ts-mode: '}' indented wrong if '{' pair is in line with '=')

From: [email-masked] (GNU bug Tracking System)
Date: Mon, 13 Feb 2023 03:52:02 +0000

Your bug report

#61398: 29.0.60; c-ts-mode: '}' indented wrong if '{' pair is in line with '='

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
61398: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=61398
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#61398: 29.0.60; c-ts-mode: '}' indented wrong if '{' pair is in line with '='
From: Yuan Fu <[email-masked]>
To: Mohammed Sadiq <[email-masked]>
Cc: [email-masked]
Date: Sun, 12 Feb 2023 19:51:02 -0800
List-Id: <debbugs-submit.debbugs.gnu.org>

Yuan Fu <[email-masked]> writes:

> Mohammed Sadiq <[email-masked]> writes:
>
>> The closing '};' is indented wrong in the following array definition:
>>
>> const char *emoticons[][2] = {
>>   {":)", "🙂"},
>>   {";)", "😉"},
>>   {":(", "🙁"},
>>   };
>>
>> The expected indentation:
>>
>> const char *emoticons[][2] = {
>>   {":)", "🙂"},
>>   {";)", "😉"},
>>   {":(", "🙁"},
>> };
>
> I see, this problem is due to priorities between indentations rules.
> Should be easy to fix.
>
> Yuan

Ok, this should be fixed now.

Yuan

Subject: 29.0.60; c-ts-mode: '}' indented wrong if '{' pair is in line with '='
From: Mohammed Sadiq <[email-masked]>
To: [email-masked]
Date: Fri, 10 Feb 2023 11:53:42 +0530
List-Id: <debbugs-submit.debbugs.gnu.org>

The closing '};' is indented wrong in the following array definition:

const char *emoticons[][2] = {
   {":)", "🙂"},
   {";)", "😉"},
   {":(", "🙁"},
   };

The expected indentation:

const char *emoticons[][2] = {
   {":)", "🙂"},
   {";)", "😉"},
   {":(", "🙁"},
};

The issue is not limited to arrays, but also types like structs.

In GNU Emacs 29.0.60 (build 17, x86_64-pc-linux-gnu, GTK+ Version
  3.24.36, cairo version 1.16.0) of 2023-02-10 built on purism
Repository revision: 51901736965f9a6f07938fa4399d14c9283437c5
Repository branch: emacs-29
Windowing system distributor 'The X.Org Foundation', version 
11.0.12101006
System Description: Debian GNU/Linux bookworm/sid