* bug#14626: CC Mode 5.32.5 (C++/l); indentation problem involving override
@ 2013-06-15 16:06 Michael Welsh Duggan
2013-06-16 4:48 ` Michael Welsh Duggan
2016-08-22 4:13 ` Alex
0 siblings, 2 replies; 3+ messages in thread
From: Michael Welsh Duggan @ 2013-06-15 16:06 UTC (permalink / raw)
To: 14626
Date: Sat, 15 Jun 2013 12:03:45 -0400
Message-ID: <87a9mrqs2m.fsf@maru.md5i.com>
User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux)
In c++-mode, the following class gets indented correctly:
class Foo
{
Foo
foo()
const;
};
as does this:
class Foo
{
Foo *
foo()
const;
};
and this:
class Foo
{
Foo
foo()
const
override;
};
But the following does not:
class Foo
{
Foo *
foo()
const
override;
};
Emacs : GNU Emacs 24.3.50.1 (i686-pc-linux-gnu, X toolkit)
of 2013-06-11 on maru
Package: CC Mode 5.32.5 (C++/l)
Buffer Style: gnu
c-emacs-features: (pps-extended-state col-0-paren posix-char-classes gen-string-delim gen-comment-delim syntax-properties 1-bit)
current state:
==============
--
Michael Welsh Duggan
(md5i@md5i.com)
^ permalink raw reply [flat|nested] 3+ messages in thread
* bug#14626: CC Mode 5.32.5 (C++/l); indentation problem involving override
2013-06-15 16:06 bug#14626: CC Mode 5.32.5 (C++/l); indentation problem involving override Michael Welsh Duggan
@ 2013-06-16 4:48 ` Michael Welsh Duggan
2016-08-22 4:13 ` Alex
1 sibling, 0 replies; 3+ messages in thread
From: Michael Welsh Duggan @ 2013-06-16 4:48 UTC (permalink / raw)
To: Michael Welsh Duggan; +Cc: 14626
Michael Welsh Duggan <mwd@md5i.com> writes:
> Date: Sat, 15 Jun 2013 12:03:45 -0400
> Message-ID: <87a9mrqs2m.fsf@maru.md5i.com>
> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux)
>
> In c++-mode, the following class gets indented correctly:
>
> class Foo
> {
> Foo
> foo()
> const;
> };
>
> as does this:
>
> class Foo
> {
> Foo *
> foo()
> const;
> };
>
> and this:
>
> class Foo
> {
> Foo
> foo()
> const
> override;
> };
>
>
> But the following does not:
>
> class Foo
> {
> Foo *
> foo()
> const
> override;
> };
It looks to me that "noexcept", "override", and "final" may need to be
added to c-type-modifier-kwds. Or maybe more appropriately in
c-type-decl-suffix-key, since they can only appear at the end of a
declaration. A brief scan through cc-langs.el shows that there might
need to be a few other new c++11 symbols added as well, such as
"constexpr". "decltype" might be particularly troublesome, as it is a
type that includes an argument in parentheses.
Please note that "noexcept", like "throw", can have a parenthetical
expression after it.
--
Michael Welsh Duggan
(md5i@md5i.com)
^ permalink raw reply [flat|nested] 3+ messages in thread
* bug#14626: CC Mode 5.32.5 (C++/l); indentation problem involving override
2013-06-15 16:06 bug#14626: CC Mode 5.32.5 (C++/l); indentation problem involving override Michael Welsh Duggan
2013-06-16 4:48 ` Michael Welsh Duggan
@ 2016-08-22 4:13 ` Alex
1 sibling, 0 replies; 3+ messages in thread
From: Alex @ 2016-08-22 4:13 UTC (permalink / raw)
To: Michael Welsh Duggan; +Cc: 14626-done
Michael Welsh Duggan <mwd@md5i.com> writes:
> Date: Sat, 15 Jun 2013 12:03:45 -0400
> Message-ID: <87a9mrqs2m.fsf@maru.md5i.com>
> User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux)
>
> In c++-mode, the following class gets indented correctly:
>
> class Foo
> {
> Foo
> foo()
> const;
> };
>
> as does this:
>
> class Foo
> {
> Foo *
> foo()
> const;
> };
>
> and this:
>
> class Foo
> {
> Foo
> foo()
> const
> override;
> };
>
>
> But the following does not:
>
> class Foo
> {
> Foo *
> foo()
> const
> override;
> };
This indents correctly since 24.4.
> It looks to me that "noexcept", "override", and "final" may need to be
> added to c-type-modifier-kwds. Or maybe more appropriately in
> c-type-decl-suffix-key, since they can only appear at the end of a
> declaration. A brief scan through cc-langs.el shows that there might
> need to be a few other new c++11 symbols added as well, such as
> "constexpr". "decltype" might be particularly troublesome, as it is a
> type that includes an argument in parentheses.
> Please note that "noexcept", like "throw", can have a parenthetical
> expression after it.
It appears that these keywords (apart from decltype) were added in time
for 25.1. decltype appears to be in master.
I'm closing the bug due to the above. Please re-open if you disagree.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-08-22 4:13 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-15 16:06 bug#14626: CC Mode 5.32.5 (C++/l); indentation problem involving override Michael Welsh Duggan
2013-06-16 4:48 ` Michael Welsh Duggan
2016-08-22 4:13 ` Alex
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).