unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: owner@emacsbugs.donarmstrong.com (Emacs bug Tracking System)
To: Alan Mackenzie <acm@muc.de>
Subject: bug#2141: marked as done (C mode indentation problem)
Date: Sat, 21 Feb 2009 16:30:03 +0000	[thread overview]
Message-ID: <handler.2141.D2141.123523339317172.ackdone@emacsbugs.donarmstrong.com> (raw)
In-Reply-To: alpine.DEB.2.00.0902011936050.14863@mord.config

[-- Attachment #1: Type: text/plain, Size: 850 bytes --]


Your message dated Sat, 21 Feb 2009 16:44:48 +0000
with message-id <20090221164448.GB3027@muc.de>
and subject line Re: bug#2141: C mode indentation problem
has caused the Emacs bug report #2141,
regarding C mode indentation problem
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@emacsbugs.donarmstrong.com
immediately.)


-- 
2141: http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=2141
Emacs Bug Tracking System
Contact owner@emacsbugs.donarmstrong.com with problems

[-- Attachment #2: Type: message/rfc822, Size: 3666 bytes --]

From: Reuben Thomas <rrt@sc3d.org>
To: bug-emacs@gnu.org
Subject: C mode indentation problem
Date: Sun, 1 Feb 2009 19:38:54 +0000 (GMT)
Message-ID: <alpine.DEB.2.00.0902011936050.14863@mord.config>

Running Emacs from CVS head as "./emacs -Q foo.c" to create a new buffer 
foo.c in C mode, if I enter the following text, indenting as I go:

----cut here----
int main (void)
{
   int foo;

   switch (foo)
     {
     case BLAH | 'a':
       bar = 0;
     break;
---cut here----

it is indented as above, which I believe is wrong, as the "break" should be 
indented to the same column as the previous line. If I change the case line 
to simply "case BLAH:" then this does indeed happen.

-- 
http://rrt.sc3d.org/ | That's about as useful as a paper wok




[-- Attachment #3: Type: message/rfc822, Size: 2175 bytes --]

From: Alan Mackenzie <acm@muc.de>
To: 2141-done@emacsbugs.donarmstrong.com
Subject: Re: bug#2141: C mode indentation problem
Date: Sat, 21 Feb 2009 16:44:48 +0000
Message-ID: <20090221164448.GB3027@muc.de>

On Sun, Feb 01, 2009 at 07:38:54PM +0000, Reuben Thomas wrote:
> Running Emacs from CVS head as "./emacs -Q foo.c" to create a new buffer 
> foo.c in C mode, if I enter the following text, indenting as I go:

> ----cut here----
> int main (void)
> {
>   int foo;

>   switch (foo)
>     {
>     case BLAH | 'a':
>       bar = 0;
>     break;
> ---cut here----

> it is indented as above, which I believe is wrong, as the "break" should be 
> indented to the same column as the previous line. If I change the case line 
> to simply "case BLAH:" then this does indeed happen.

Fixed by enhancing c-beginning-of-statement-1 to handle (compile-time)
expressions as case labels.

-- 
Alan Mackenzie (Nuremberg, Germany).


  parent reply	other threads:[~2009-02-21 16:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20090221164448.GB3027@muc.de>
2009-02-01 19:38 ` bug#2141: C mode indentation problem Reuben Thomas
2009-02-01 21:23   ` Alan Mackenzie
2009-02-21 16:30   ` Emacs bug Tracking System [this message]
2009-02-21 16:35   ` Alan Mackenzie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=handler.2141.D2141.123523339317172.ackdone@emacsbugs.donarmstrong.com \
    --to=owner@emacsbugs.donarmstrong.com \
    --cc=acm@muc.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).