Commit 22fc2cb
authored
[clang-format] Fix AllowShortLambdasOnASingleLine interfering with lambda brace wrapping. (#81848)
Fix an issue where the lambda body left brace could sometimes fail to be
wrapped when AllowShortLambdasOnASingleLine is enabled.
Now, when BraceWrapping.BeforeLambdaBody is enabled, if the brace is not
wrapped, we prevent breaks in the lambda body.
Resolves #818451 parent 44b1767 commit 22fc2cb
File tree
3 files changed
+26
-5
lines changed- clang
- lib/Format
- unittests/Format
3 files changed
+26
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1803 | 1803 | | |
1804 | 1804 | | |
1805 | 1805 | | |
1806 | | - | |
| 1806 | + | |
1807 | 1807 | | |
1808 | 1808 | | |
1809 | 1809 | | |
| |||
1991 | 1991 | | |
1992 | 1992 | | |
1993 | 1993 | | |
1994 | | - | |
| 1994 | + | |
1995 | 1995 | | |
1996 | 1996 | | |
1997 | 1997 | | |
| |||
2003 | 2003 | | |
2004 | 2004 | | |
2005 | 2005 | | |
| 2006 | + | |
| 2007 | + | |
| 2008 | + | |
| 2009 | + | |
| 2010 | + | |
| 2011 | + | |
| 2012 | + | |
| 2013 | + | |
| 2014 | + | |
2006 | 2015 | | |
2007 | 2016 | | |
2008 | | - | |
2009 | | - | |
| 2017 | + | |
2010 | 2018 | | |
2011 | 2019 | | |
2012 | 2020 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
104 | 104 | | |
105 | 105 | | |
106 | 106 | | |
107 | | - | |
| 107 | + | |
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22893 | 22893 | | |
22894 | 22894 | | |
22895 | 22895 | | |
| 22896 | + | |
| 22897 | + | |
| 22898 | + | |
| 22899 | + | |
| 22900 | + | |
| 22901 | + | |
| 22902 | + | |
| 22903 | + | |
| 22904 | + | |
| 22905 | + | |
| 22906 | + | |
| 22907 | + | |
| 22908 | + | |
22896 | 22909 | | |
22897 | 22910 | | |
22898 | 22911 | | |
| |||
0 commit comments