1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-27 07:41:28 -08:00
emacs/doc/misc
Alan Mackenzie 94ad13b93c Allow C++ nested brace-list-entries to be better indented.
This fixes bug #24431.  The key change of this bug fix is correctly analyzing
nested brace lists when the opening element stands on the same line as both
its introductory brace and an enclosing parameter list parenthesis.

* list/progmodes/cc-align.el (c-lineup-under-anchor): New line-up function.

* list/progmodes/cc-engine.el (c-looking-at-or-maybe-in-bracelist): Accept the
presence of exactly an identifier between an open parenthesis and an open
brace as evidence of the brace starting a brace list.
(c-looking-at-statement-block): New function, extracted from
c-looking-at-inexpr-block.  Enhance it to analyze inner blocks recursively
when needed.
(c-looking-at-inexpr-block): Extract new function (see above) and call it.
(c-add-stmt-syntax): Enhance, with new &optional parameter, to supply the
prime syntactic symbol with a fixed anchor point.  When this is used, restrict
all added syntactic symbols to those having an anchor point on the same line.
Add, in addition to the current additional symbols, c-brace-list-entry when
needed; use c-looking-at-statement-block to determine the latter.
(c-guess-basic-syntax, CASE 9D): Use c-add-stmt-syntax rather than just
c-add-syntax, to assemble the syntactic context of a 'brace-list-entry, thus
getting, possibly, several accompanying syntactic entries.

* lisp/progmodes/cc-styles.el (c-style-alist, "gnu" style): New entry for
'brace-list-intro, namely c-lineup-arglist-intro-after-paren.

* lisp/progmodes/cc-vars.el (c-offsets-alist): Change the factory default
offset for 'brace-list-entry from 0 to c-lineup-under-anchor.

* doc/misc/cc-mode.texi (Syntactic Symbols): Amend the definition of
brace-list-intro.
(Brace List Symbols): Amend the example to show the new analysis of brace
lists when the first element comes on the same line as the opening brace.
(Misc Line-Up): Document the new line-up function c-lineup-under-anchor.
2017-02-01 20:20:09 +00:00
..
ada-mode.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
auth.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
autotype.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
bovine.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
calc.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
cc-mode.texi Allow C++ nested brace-list-entries to be better indented. 2017-02-01 20:20:09 +00:00
ChangeLog.1 Update copyright year to 2017 2016-12-31 19:42:26 -08:00
cl.texi Move cXXXr and cXXXXr to subr.el 2017-01-25 14:21:10 -05:00
dbus.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
dired-x.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
doclicense.texi Update licenses to latest version from FSF. 2012-12-06 00:33:32 -08:00
ebrowse.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
ede.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
ediff.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
edt.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
efaq-w32.texi Update copyright year to 2017 2016-12-31 19:42:26 -08:00
efaq.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
eieio.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
emacs-gnutls.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
emacs-mime.texi Document how to quote MML tags 2017-01-25 21:47:28 +01:00
epa.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
erc.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
ert.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
eshell.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
eudc.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
eww.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
flymake.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
forms.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
gnus-coding.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
gnus-faq.texi Update copyright year to 2017 2016-12-31 19:42:26 -08:00
gnus-news.el Fix copyright years by hand 2017-01-01 04:01:41 +00:00
gnus-news.texi Update copyright year to 2017 2016-12-31 19:42:26 -08:00
gnus-overrides.texi gnus-overrides.texi: Renamed from overrides.texi and all the relevant manuals use it now. 2011-02-06 00:25:41 +00:00
gnus.texi Add new command gnus-article-sort-by-marks 2017-01-27 00:30:54 +01:00
gpl.texi Update licenses to latest version from FSF. 2012-12-06 00:33:32 -08:00
htmlfontify.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
idlwave.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
ido.texi Update copyright year to 2017 2016-12-31 19:42:26 -08:00
info.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
mairix-el.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
Makefile.in Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
message.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
mh-e.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
newsticker.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
nxml-mode.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
octave-mode.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
org.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
pcl-cvs.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
pgg.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
rcirc.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
reftex.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
remember.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
sasl.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
sc.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
sem-user.texi Update copyright year to 2017 2016-12-31 19:42:26 -08:00
semantic.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
ses.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
sieve.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
smtpmail.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
speedbar.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
srecode.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
texinfo.tex Merge from gnulib 2017-01-10 07:49:55 -08:00
todo-mode.texi Update copyright year to 2017 2016-12-31 19:42:26 -08:00
tramp.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
trampver.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
url.texi Merge from origin/emacs-25 2017-01-01 01:10:47 -08:00
vhdl-mode.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
vip.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
viper.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
widget.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
wisent.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00
woman.texi Fix copyright years by hand 2017-01-01 04:01:41 +00:00