aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--doc/misc/cc-mode.texi12
-rw-r--r--lisp/progmodes/cc-vars.el2
2 files changed, 8 insertions, 6 deletions
diff --git a/doc/misc/cc-mode.texi b/doc/misc/cc-mode.texi
index df6709e38c2..ab1c8e6f520 100644
--- a/doc/misc/cc-mode.texi
+++ b/doc/misc/cc-mode.texi
@@ -7431,13 +7431,15 @@ could amend your C++ Mode hook like this:
7431@emph{How do I stop my C++ lambda expressions being indented way over 7431@emph{How do I stop my C++ lambda expressions being indented way over
7432to the right?} 7432to the right?}
7433 7433
7434Change the offset associated with @code{inlambda} from its default, 7434This is now the default, so you don't need to do anything. To restore
7435the function @code{c-lineup-inexpr-block}, to 0. For example, if you 7435the previous default, indenting lambda expressions to the right of the
7436are setting offsets in a hook function you might include the following 7436constructs which introduce them, change the offset associated with
7437line: 7437@code{inlambda} from 0 to @code{c-lineup-inexpr-block}. For example,
7438if you are setting offsets in a hook function you might include the
7439following line:
7438 7440
7439@example 7441@example
7440(c-set-offset 'inlambda 0) 7442(c-set-offset 'inlambda 'c-lineup-inexpr-block)
7441@end example 7443@end example
7442 7444
7443For details of the different ways you can make this setting, 7445For details of the different ways you can make this setting,
diff --git a/lisp/progmodes/cc-vars.el b/lisp/progmodes/cc-vars.el
index b818bced730..79bd6a92950 100644
--- a/lisp/progmodes/cc-vars.el
+++ b/lisp/progmodes/cc-vars.el
@@ -1210,7 +1210,7 @@ can always override the use of `c-default-style' by making calls to
1210 (template-args-cont . (c-lineup-template-args +)) 1210 (template-args-cont . (c-lineup-template-args +))
1211 ;; Anchor pos: Boi at the decl start. This might be changed; 1211 ;; Anchor pos: Boi at the decl start. This might be changed;
1212 ;; the logical position is clearly the opening '<'. 1212 ;; the logical position is clearly the opening '<'.
1213 (inlambda . c-lineup-inexpr-block) 1213 (inlambda . 0)
1214 ;; Anchor pos: None. 1214 ;; Anchor pos: None.
1215 (lambda-intro-cont . +) 1215 (lambda-intro-cont . +)
1216 ;; Anchor pos: Boi at the lambda start. 1216 ;; Anchor pos: Boi at the lambda start.